These are chat archives for assetgraph/assetgraph

11th
Jul 2016
Andreas Lind
@papandreou
Jul 11 2016 08:48
Miss you guys here at the office. It's like going from 180 km/h to 0 :)
@Munawwar A bunch of stuff happened last week. For one thing, Guy wrote a better less plugin: https://github.com/systemjs/plugin-less
Munawwar
@Munawwar
Jul 11 2016 08:50
Yup, I saw that. I sent a tiny PR as well.
Guy was reluctant to write a less plugin if I remember correctly. He did it anyway I guess :smile:
Andreas Lind
@papandreou
Jul 11 2016 08:51
@Munawwar Also, https://github.com/Munter/express-systemjs-translate was refined quite a bit and now does incremental bundling in development mode as well. I know that's not exactly what you were cheering for, but maybe that work can be ported to fusile at a later point.
@Munawwar Ah, nice that you discovered it yourself :). When running in node.js (via express-systemjs-translate), the less plugin supports source maps so you don't need sourceURL and get a mapping back to the correct line. For some reason the in-browser version of the less compiler does not support that.
I agree that it's worthwhile to add sourceURL for that reason, of course.
Munawwar
@Munawwar
Jul 11 2016 08:55
Meanwhile I've hit a roadblock with fusile and express. For me none of the file request going through express completes. Don't know why. It doesn't happen if I use file:// url to request the file. I guess I have to dive deep into fuse bindings node module (C lang code)
Andreas Lind
@papandreou
Jul 11 2016 08:56
@Munawwar If you're a fan of GETSTATICURL, the bad news is that the non-trivial cases of it were torn out from assetgraph. The good news is that there's now a system.js plugin that allows you to accomplish the same thing via import or require: https://github.com/assetgraph/systemjs-asset-plugin
Munawwar
@Munawwar
Jul 11 2016 08:57
I guess Web Editor was more a fan of GETSTATICURL.
Andreas Lind
@papandreou
Jul 11 2016 08:58
Yeah, still is. I have to come up with something :)
Example usage:
import urlGlobber from 'foo/*.html!asset';

var iframe = document.createElement('iframe');
iframe.src = urlGlobber(Math.random() > .5 ? 'quux' : 'bar');
document.body.appendChild(iframe);
Munawwar
@Munawwar
Jul 11 2016 09:09
BTW, you all using node 6?
Andreas Lind
@papandreou
Jul 11 2016 09:10
@Munawwar Getting there. I'm pretty sure all these tools support older versions all the way down node.js 0.10, though.
@Munawwar I just started playing with the V8 inspector feature that landed in 6.3.0. I think I'll be in a hurry to update everything to 6.3.0 -- that's totally killer.
nodejs/node#6792
Munawwar
@Munawwar
Jul 11 2016 09:18
Assetgraph's readme
Is getting outdated
Munawwar
@Munawwar
Jul 11 2016 10:51
Ah..system.js's on node, isn't able to deal with UMD pattern very well.
Munawwar
@Munawwar
Jul 11 2016 12:08
I wrote a node.js SystemJS emulator to fix my tests - https://github.com/Munawwar/lithium-ui/blob/master/test/systemjs-emulator.js
Next I'll try to support systemjs plugin API as well. (And then maybe use https://www.npmjs.com/package/xhr2 as well to emulate requests)
@guybedford ^ Call it stupid if it is.
Peter Müller
@Munter
Jul 11 2016 17:58
After refactoring express-systemjs-translate, adding tests and updating the README I feel it's ready to go public
Probably still best to write a blog post. Trying to get my hands on some power users first to get initial feedback first though
Andreas Lind
@papandreou
Jul 11 2016 18:14
Go @Munter :)