Setup
- Ensure everything is up to date by running
sudo npm update
aftercd
ing into the directory this file lives in - Configure your
gulpfile.js
as needed (and see what tasks are available) - Run
gulp
to dev: (pre-)compiling, file watching, browser-relaoding, etc. - Run
sudo ulimit -n 8192
if you get a 'memory limit exceeded' error - Run
gulp -s
(orgulp --silent
) to prevent launching a new live-reloading browser window - Run
gulp -g
(orgulp --ghost
) to sync all browser page changes, scrolling, and clicks between clients
Structure
src/assets/scripts/
should contain your source code, whereasbuild/assets/js/
should contain only dynamically generated javascriptsrc/assets/styles/
, likewise, should contain your source code, whereasbuild/assets/css/
should contain only dynamically generated csssrc/assets/images/
is for all site-specific static images; any user-uploaded content should be kept elsewheresrc/assets/icons/
is for all SVG icons; they will be minified/optimized intobuild/assets/icon/
src/views/
is for partials to be rendered as full view templates (e.g. public vs. authenticated, header1 vs. header2)src/views/page/
is for partials that will be included in other views (e.g. subviews)src/templates/
is for general-purpose partials (i.e. angular directive templates, re-used UI elements, or repeated content sections)