Code Monkey home page Code Monkey logo

gulp_project_template_v2's Introduction

Gulp 4 project template

Very simple and basic ready-to-start project template. Based on Gulp v.4 task-runner with Webpack as a bundling tool. Can (and probably should) be upgraded with tools like ESLint and source-maps.

Includes:

  • scss/sass -> css compilation
  • styles minification
  • renaming (adds .min suffix)
  • autoprefixers
  • scripts minification and bundling with Webpack (with [hash].js injecting to index.html)
  • images minification (albeit using web tools like (tinypng.com) is highly recommended and works much better)
  • local server and automated live-reload with browserSync

In src/scss you'll find _reset.scss - it is .scss file created by Eric A. Meyer (meyerweb.com) and resets all default browser problematic styles like padding, margin, box-sizing.

In dist/images you'll find .jpg file used during configuration to check if images minification works. Source/author: Photo by Michael Dam on Unsplash

To start project, node.js & npm are required. You can download these from node website. Follow instructions.

npm init -y Initiates npm management over your project. Creates package.json. -y sets all properties to default values.

npm install / npm i This commands (either) should install all required dependencies listed in package.json file. Therefore node_modules directory is created.

gulp is default CLI command which starts local server, opens your index.html and keeps looking for changes in project files. Enter command and work for hours :)

./src Directory for all source subdirectories (scss and js)

./src/scss Source style files

./src/js Source script files

./dist Steady production directory for styles, images, html and scripts

PS. be aware of package.json file and data (author, project name, etc). Feel free to change it and use in your projects.

gulp_project_template_v2's People

Contributors

bartekszajna avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.