JSPM, ES6 &
I make things on the internet
WHAT is JSPM?
It's a package manager!
"Installing a widget or library should be a one line operation and a single require" — Guy bedford
It does a little more
than a package manager
- Package manager for SystemJS (Universal dynamic module loader)
- Leverages NPM and Github
- Loads any module format (ES6, AMD and CommonJS)
- Transpiles your ES6 => ES5
- Builds a single "production ready" file for you
CONSIDER JSPM or something alike?
Create a new project
Install a package
And you're done
So what's the other side look like?
OWN With gulp
dependencies via bower
TRANSPILE YOUR ES6
the gulp task
Pro and cons
- You have a bit of a manual setup
- Makes structuring it how you like a little easier
- One file with no extra requests during development
- No "free" build script
- Dependencies are global and not scoped to a module
So JSPM OR diy?
BONUS! (shameless plug)
"ECMAScript 6, also known as ECMAScript 2015, is the latest version of the ECMAScript standard. ES6 is a significant update to the language, and the first update to the language since ES5 was standardized in 2009" — Luke Hoban
CAN I USE ES6 now?
<!--[if lt IE 9]> <script src="es5-shim.js"></script> <script src="es5-sham.js"></script> <![endif]-->
SHOULD I USE
TL;DR—modules make your life better
PROPerty value shorthand
ES6 in 350 bullets
THANKS FOR LISTENING!
JSPM, ES6 and simplifying your code
By Benjamin Reid