Open nwmcsween opened 8 years ago
Could you provide more details on your current workflow?
Do you want a utility that takes in JSON and outputs CSS?
something like j2c es6-export-file-with-computed-properties.js -o somefile.css
On 2016-03-18 3:02 PM, Pierre-Yves Gérardy wrote:
Could you provide more details on your current workflow?
Do you want a utility that takes in JSON and outputs CSS?
— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub https://github.com/j2css/j2c/issues/23#issuecomment-198561242
Now that's tricky because ES6 module bindings are static, and they are obviously not supported natively, so there are more than one way to consume them... I'll have to think about it.
In the mean time, you could, programmatically, generate files with something like:
#! /usr/bin/env node
/*
j2cgen.js
usage:
j2cgen.js filename > destination
*/
console.log(`
import sheet from '${process.argv[2]}';
import j2c from 'j2c';
console.log(j2c.sheet(sheet));
`)
Or is it what you meant by "cping a runner"?
You could use a System.import shim. That example is what i meant by the "cping a runner" as i have to do that with every project.
On Fri, Mar 18, 2016, 3:49 PM Pierre-Yves Gérardy notifications@github.com wrote:
Now that's tricky because ES6 module bindings are static, and they are obviously not supported natively, so there are more than one way to consume them... I'll have to think about it.
In the mean time, you could, programmatically, generate files with something like:
! /usr/bin/env node/* j2cgen.jsusage: j2cgen.js filename > destination*/console.log(
import sheet from '${process.argv[2]}';import j2c from 'j2c';console.log(j2c.sheet(sheet));
)Or is it what you meant by "cping a runner"?
— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub https://github.com/j2css/j2c/issues/23#issuecomment-198570771
Ah, yes, SystemJS... good call. I've never used it, though...
I'll look into this later on, but my current priority is getting v1.0 out (mostly docs now).
It's not just SystemJS, it's in ES6, any shim for System.import will work.
On 2016-03-18 4:26 PM, Pierre-Yves Gérardy wrote:
Ah, yes, SystemJS... good call. I've never used it, though...
I'll look into this later on, but my current priority is getting v1.0 out (mostly docs now).
— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub https://github.com/j2css/j2c/issues/23#issuecomment-198582274
It's quite cumbersome cping a runner to convert js to css for every project.