Skip to content

theleapofcode/js-starter-kit

Repository files navigation

Build Status

js-starter-kit

Starter kit for JS project

Editor

VSCode is my choice because of the following features,

  1. Best JS code hinting features using intellisense.
  2. Supports rich set of plugins for almost anything.
  3. Built in terminal
  4. Built in Git UI
  5. Debugger

EditorConfig

To maintain consistency of Editor configurations, use EditorConfig. Install EditorConfig extension for VSCode. Add .editorconfig file at the project root.

Package Manager

NPM is the preferred manager for JS. It's not only for Node packages but also for front end packages.

Node Security Platform

NSP can be used to check for security vulnerabilities in npm packages.

Development Server

Express is a good choice for a dev server since it is highly configurable and easy to use.

Sharing Development Server

LocalTunnel can be used to share a development server over internet.

Build Automation

NPM Scripts is the easiest option for automating build tasks. No need of Grunt or Gulp.

Transpiling

Babel is the best ES transpiler. Add .babelrc to configue babel transpiling options.

Bundling

Webpack is the most versatile and configurable bundler.

Linting

ESLint is the most versatile and configurable linter.

HTTP Client

Fetch is the new standard for HTTP/AJAX calls. Use a polyfill to support all browsers.

Mocking HTTP Server

To mock HTTP server for testing, use JSON-server and JSON-schema-faker.

Production Build

JS Minification

Webpack Uglify plugin to minify JS.

HTML Bundling and Minification

Webpack HTML plugin to minify and bundle HTML.

Bundle Splitting

Webpack CommonsChunkPlugin used to split vendor and application JS bundles so that they can be cached separately.

Cache Busting

Webpack MD5Hash plugin used to add hash to filenames to bust cache.

CSS Bundling and Minification

Webpack ExtractTextPlugin to bundle and minify CSS.

Continuous Integration

Travis CI

Integrate with Travis CI.

About

Starter kit for front end JS project

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •