parcel-plugin-css-object
Advanced tools
Comparing version 1.0.0 to 1.0.1
@@ -11,4 +11,3 @@ const { Asset } = require("parcel-bundler"); | ||
parse(source) { | ||
console.log(source); | ||
var parsedStylesheet = css.parse(source).stylesheet; | ||
var parsedStylesheet = css.parse(source); | ||
this.code = | ||
@@ -20,3 +19,3 @@ parsedStylesheet && | ||
// Send to JS bundler | ||
return { js: `module.exports = \`${JSON.stringify(this.code)}\`` }; | ||
return { js: `module.exports = '${JSON.stringify(this.code)}'` }; | ||
} | ||
@@ -27,7 +26,2 @@ } | ||
// Parse the contents of the CSS file and get the resulting AST | ||
function getParsedStylesheet(source) { | ||
return css.parse(source).stylesheet; | ||
} | ||
// Return `true` for an AST node with { type: 'rule' } and valid selectors | ||
@@ -34,0 +28,0 @@ function isValidRule(rule) { |
{ | ||
"name": "parcel-plugin-css-object", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"main": "index.js", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
No README
QualityPackage does not have a README. This may indicate a failed publish or a low quality package.
Found 1 instance in 1 package
140869
5
1
79
59