Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,10 @@ export default (options = {}) => {
name: "import-css",

/* convert the css file to a module and save the code for a file output */
transform(code, id) {
async transform(code, id) {
if (!filter(id)) return;

const transformedCode = (options.minify) ? minifyCSS(options.transform(code)) : options.transform(code);
const transformedCode = (options.minify) ? minifyCSS(await options.transform(code)) : await options.transform(code);

/* cache the result */
if (!styles[id] || styles[id] != transformedCode) {
Expand Down