Skip to content

Instantly share code, notes, and snippets.

@jnv
Last active August 29, 2015 14:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jnv/38247f091ffba4951336 to your computer and use it in GitHub Desktop.
Save jnv/38247f091ffba4951336 to your computer and use it in GitHub Desktop.
Failing example for atomify with rework-inherit
node_modules/
dist/

Example for atomify-css#43 with rework-inherit

Usage:

  1. git clone git@gist.github.com:/38247f091ffba4951336.git atomify-css-fail
  2. cd atomify-css-fail
  3. npm install
  4. node build.js

Fails with:

[Error: Failed to extend from %default.]
var css = require('atomify-css')
var opts = {
entry: './index.css',
plugins: [
['rework-inherit']
]
}
css(opts, function (err, src) {
console.error(err);
console.log(src);
})
%default {
color: #fff;
}
@import './default.css';
@import './span.css';
// Nothing here
{
"name": "atomify-css-testcase",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"build": "node build.js"
},
"author": "",
"license": "",
"dependencies": {
"atomify-css": "^3.3.1",
"rework-inherit": "^0.2.3"
},
"atomify": {
"js": {
"entry": "index.js"
},
"css": {
"entry": "index.css",
"plugins": [
[
"rework-inherit"
]
]
}
}
}
span {
background: #fff;
inherit: %default;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment