Comparing version 5.0.0 to 5.0.1
10
index.js
@@ -41,4 +41,10 @@ const cssPrefix = require('postcss-prefix') | ||
if (options.global !== true) p = p.use(cssPrefix('.' + prefix)) | ||
css = p.process(css).toString() | ||
return done(null, css, prefix) | ||
try { | ||
css = p.process(css).toString() | ||
return done(null, css, prefix) | ||
} catch (e) { | ||
return done(e) | ||
} | ||
}) | ||
@@ -45,0 +51,0 @@ |
{ | ||
"name": "sheetify", | ||
"version": "5.0.0", | ||
"version": "5.0.1", | ||
"description": "Modular CSS bundler", | ||
@@ -5,0 +5,0 @@ "repository": "sheetify/sheetify", |
@@ -88,2 +88,21 @@ # sheetify | ||
By using `:host` we are able to provide styles for the parent element: | ||
```css | ||
._60ed23ec9f { | ||
background-color: blue; | ||
} | ||
._60ed23ec9f > h1 { | ||
text-decoration: underline; | ||
} | ||
``` | ||
```html | ||
<section class="_60ed23ec9f"> | ||
<h1>My beautiful, centered title</h1> | ||
</style> | ||
``` | ||
## External files | ||
@@ -90,0 +109,0 @@ To include an external CSS file you can pass a path to sheetify as |
@@ -54,7 +54,13 @@ const cssResolve = require('style-resolve').sync | ||
const nodes = [] | ||
const src = Buffer.concat(bufs).toString('utf8') | ||
var mname = null | ||
const src = Buffer.concat(bufs).toString('utf8') | ||
const tmpAst = falafel(src, { ecmaVersion: 6 }, identifyModuleName) | ||
const ast = falafel(tmpAst.toString(), { ecmaVersion: 6 }, extractNodes) | ||
var ast | ||
try { | ||
const tmpAst = falafel(src, { ecmaVersion: 6 }, identifyModuleName) | ||
ast = falafel(tmpAst.toString(), { ecmaVersion: 6 }, extractNodes) | ||
} catch (err) { | ||
return self.emit('error', err) | ||
} | ||
// transform all detected nodes and | ||
@@ -61,0 +67,0 @@ // close stream when done |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
23533
429
264
0