These are chat archives for systemjs/systemjs

30th
Mar 2016
Jarosław Cimoch
@jcimoch
Mar 30 2016 08:20
is there a simple way to bundle all modules to singiel file ? Currently i’m using polymer with vulcanize but i need separate gulp task to concat all system.js modules into one file so I can minimize count of xhr calls
by the way I’m using typescript so maybe it can help somehow
Jarosław Cimoch
@jcimoch
Mar 30 2016 09:11
ok I think I manage to do that using gulp and tsconfig with out property alongside system module
Jeff
@Jefftopia
Mar 30 2016 12:32
@jcimoch Typescript 1.8+ allows system modules to be output to single file. In your tsconfig, use the following:
"module": "system",
"outFile": "./path/to/outfile.js"
"moduleResolutuion": "node"
"moduleResolutuion": "node" is not required but it's nice.

@jcimoch Also, JSPM is a kind of sister (cousin?) project to System JS that has a couple of intelligent bundling features built in. You give the CLI an entry-point js file and an outdir and it will bundle your JS - including imported files - into a single, self-executing bundle.

jspm bundle main.js build.js
jspm bundle-sfx main.js build.js

I haven't used this much yet, so others here are a better resource. A stand-alone builder project is available as well.

Jarosław Cimoch
@jcimoch
Mar 30 2016 12:49
@Jefftopia thanks
Mario Hofer
@MarioHofer
Mar 30 2016 13:59