My default gulpfile.js
I am working on a new template for the apps I commonly craft these days, and right now it’s looking like this.
- Material Design Lite for the UI framework. Pros: no external JS dependencies (not even jQuery), fast, pretty, don’t have to worry about IE9 because it isn’t supported. Cons: IE9 isn’t supported.
- Leaflet for the mapping. Duh.
- Underscore for JSON handling and templates. Lodash is great, but I don’t use the extra features, it’s 7x the size, and I am too lazy to make a custom build to shrink it.
- Browserify for modular development and dependency management.
- Favor npm over bower for dependencies when possible. Makes Browserify and testing easier.
- A unit test framework. I haven’t put a finger on that yet. Maybe tape.
The first step is automating things with Gulp. I usually write my
gulpfile.js as a project goes along and by the time I’m done it’s a steaming mess. Here is my new default template.
var postcss = require("gulp-postcss"),
My plan is to build out the template, dogfood it with a new GeoPortal release, and then put all of it on Github. Stay tuned.