Skip to content

Commit 2075e83

Browse files
committed
fix: test error
1 parent de0ca98 commit 2075e83

File tree

7 files changed

+19
-12
lines changed

7 files changed

+19
-12
lines changed

dist/main.d.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
/**
2+
* tailwindcss-palette-generator v0.4.0
3+
* Copyright 2023 @ibodev1 <github.com/ibodev1>
4+
*/
5+
16
interface Palette {
27
name: string;
38
color: string;

dist/main.esm.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* tailwindcss-palette-generator v0.3.0
2+
* tailwindcss-palette-generator v0.4.0
33
* Copyright 2023 @ibodev1 <github.com/ibodev1>
44
*/
55

dist/main.umd.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* tailwindcss-palette-generator v0.3.0
2+
* tailwindcss-palette-generator v0.4.0
33
* Copyright 2023 @ibodev1 <github.com/ibodev1>
44
*/
55

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@
1818
"access": "public"
1919
},
2020
"scripts": {
21-
"build": "cross-env NODE_ENV=production rollup -c --bundleConfigAsCjs",
22-
"dev": "rollup -c -w --bundleConfigAsCjs",
21+
"build": "cross-env NODE_ENV=production rollup -c rollup.config.ts --configPlugin typescript",
22+
"dev": "rollup -c rollup.config.ts --configPlugin typescript -w",
2323
"test": "jest",
2424
"prepublish": "pnpm test && pnpm build",
2525
"postversion": "pnpm publish --access public"

rollup.config.js renamed to rollup.config.ts

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/** @type {import('rollup').RollupOptions} */
12
import commonjs from "@rollup/plugin-commonjs";
23
import json from "@rollup/plugin-json";
34
import resolve from "@rollup/plugin-node-resolve";
@@ -15,6 +16,11 @@ const settings = {
1516
}
1617
};
1718

19+
const banner = `
20+
${packageJson.name} v${packageJson.version}
21+
Copyright <%=moment().format('YYYY')%> ${packageJson.author}
22+
`
23+
1824
export default [
1925
{
2026
input: "./src/main.ts",
@@ -55,17 +61,12 @@ export default [
5561
ignoreGlobal: false,
5662
sourceMap: false
5763
}),
58-
license({
59-
banner: `
60-
${packageJson.name} v${packageJson.version}
61-
Copyright <%=moment().format('YYYY')%> ${packageJson.author}
62-
`
63-
})
64+
license({ banner })
6465
]
6566
},
6667
{
6768
input: "src/main.ts",
68-
plugins: [dts.default()],
69+
plugins: [dts(), license({ banner })],
6970
output: {
7071
file: `dist/main.d.ts`,
7172
format: "es"

test/lib.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import getPalette from "../src/main.ts";
1+
import getPalette from "../src/main";
22

33
const stringPalette = getPalette("#FFBD00");
44

tsconfig.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
"noImplicitAny": true,
99
"noImplicitThis": true,
1010
"noUnusedLocals": true,
11+
"esModuleInterop": true,
1112
"noUnusedParameters": true,
1213
"removeComments": true,
1314
"preserveConstEnums": true,

0 commit comments

Comments
 (0)