fedorjia / gulp-multi-page-boilerplate

multi page webapp with gulp

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Use gulp to build multi-page webapp.

This project has been deprecated. Please use SSR(React or Vue) instead.

Usage

##install

npm install

gulp build

node index.js

then visit http://localhost:3000 view document source code, you will find it.

image

configure

edit build/conf.js file, and configure your tasks. image

development

when you are developing your app

  1. edit settings.js, change debug = true
  2. run the following command
nodemon index.js

gulp dev

it will do the following things

  • concat each page styles and scripts
  • inject them into html

production

when you are preparing to publish your app

  1. edit settings.js, change debug = false
  2. run the following command
gulp build

it will do the following things

  • concat each page styles and scripts
  • compress style and script and rename each file with hash suffix.
  • inject them into html.

you can also build single page with the page task, for example:

index page for development

gulp index-dev

index page for production

gulp index-build

About

multi page webapp with gulp


Languages

Language:CSS 59.6%Language:JavaScript 29.8%Language:HTML 10.5%