Skip to content

Commit

Permalink
feat: set type in package.json to module
Browse files Browse the repository at this point in the history
  • Loading branch information
web-padawan committed Jul 2, 2022
1 parent de8ceeb commit ce84b22
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"license": "MIT",
"main": "hex-color-picker.js",
"module": "hex-color-picker.js",
"type": "module",
"types": "hex-color-picker.d.ts",
"repository": {
"type": "git",
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion scripts/build-styles.js → scripts/build-styles.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const readFile = util.promisify(fs.readFile);
const delimiter = /<%\s*content\s*%>/;

async function minifyCss(cssFile) {
const data = await readFile(cssFile);
const data = await readFile(cssFile, 'utf8');
const result = csso.minify(data);
return result.css;
}
Expand Down
6 changes: 3 additions & 3 deletions web-test-runner.config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
const { esbuildPlugin } = require('@web/dev-server-esbuild');
const { visualRegressionPlugin } = require('@web/test-runner-visual-regression/plugin');
import { esbuildPlugin } from '@web/dev-server-esbuild';
import { visualRegressionPlugin } from '@web/test-runner-visual-regression/plugin';

module.exports = {
export default {
nodeResolve: true,
plugins: [
esbuildPlugin({ ts: true }),
Expand Down

0 comments on commit ce84b22

Please sign in to comment.