Skip to content

Commit

Permalink
fix(postcss-colormin): fixed plugin running error (#856)
Browse files Browse the repository at this point in the history
  • Loading branch information
anikethsaha authored and evilebottnawi committed Dec 23, 2019
1 parent f6e767b commit eb37dd5
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
2 changes: 1 addition & 1 deletion packages/postcss-colormin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
],
"scripts": {
"prebuild": "del-cli dist",
"build": "cross-env BABEL_ENV=publish babel-node --config-file ../../babel.config.js ./src/generate.js && babel src --config-file ../../babel.config.js --out-dir dist --ignore \"**/__tests__/,src/generate.js\"",
"build": "cross-env BABEL_ENV=publish babel src --config-file ../../babel.config.js --out-dir dist --ignore \"**/__tests__/\" && babel-node script/generate",
"prepublish": "yarn build"
},
"keywords": [
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import path from 'path';
import writeFile from 'write-file';
import colorNames from 'css-color-names';
import toShorthand from './lib/toShorthand';
const path = require('path');
const writeFile = require('write-file');
const colorNames = require('css-color-names');
const toShorthand = require('../dist/lib/toShorthand');

const keywords = {};
const hexes = {};
Expand All @@ -27,7 +27,11 @@ function callback(err) {
}
}

writeFile(path.join(__dirname, 'keywords.json'), stringify(keywords), callback);
writeFile(
path.join(__dirname, '../src/keywords.json'),
stringify(keywords),
callback
);

writeFile(
path.join(__dirname, '../dist/keywords.json'),
Expand Down

0 comments on commit eb37dd5

Please sign in to comment.