Skip to content

Commit

Permalink
Change which type is exported
Browse files Browse the repository at this point in the history
  • Loading branch information
IanVS committed Mar 19, 2024
1 parent ef1c1db commit a550aee
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions index.test.mts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import path from "node:path";
import postcss from "postcss";
import prettier from "prettier";
import { describe, it, expect } from "vitest";
import { plugin, type ConfigItem } from "./index.js";
import { plugin, type PluginOptions } from "./index.js";

// We don't care about formatting differences, so normalize with prettier
function format(css: string) {
Expand All @@ -13,7 +13,7 @@ function format(css: string) {
async function run(
input: string,
output: string,
opts?: ConfigItem[],
opts?: PluginOptions,
postcssOpts = {}
) {
const result = await postcss([plugin(opts)]).process(input, postcssOpts);
Expand Down
4 changes: 2 additions & 2 deletions index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ import type { PluginCreator } from "postcss";
const DEFAULT_INCLUDE = "**/*.module.css";
const DEFAULT_LAYERNAME = "components";

export type ConfigItem = {
type ConfigItem = {
include?: string;
layerName?: string;
};
type PluginOptions = ConfigItem[];
export type PluginOptions = ConfigItem[];

export const plugin: PluginCreator<PluginOptions> = (
configItems = [
Expand Down

0 comments on commit a550aee

Please sign in to comment.