smellai / angularjs-webpack4

AngularJS + webpack 4 example project, using ES2015+ with Babel, webpack 4, ESLint, SASS (scss) and UI Router

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

angularjs-webpack4

AngularJS + webpack 4 example project

An AngularJS + webpack seed project, supporting ES2015+ syntax through Babel compiler; ESLint and stylelint will assist you writing beautiful code.

Updated version inspired by top-solution/angularjs-webpack-seed

It comes with preconfigured

Supported browsers (in browserlist format) are:

last 2 versions
ie >= 10

Pre-requisites

Required:

  • Node.js with npm, the current LTS version is an ideal starting point

Usage

Fork or download the project then install dependencies

$ npm install

Development

$ npm run dev

The project will be available at http://localhost:8000/.

Building

$ npm run build

Environment variables

If you need to inject different environment variables, for example to use a different API url in a certain environment, just add them to the proper env file (for example if 'NODE_ENV=dev' the env file is env/dev.sh).

Through every file inside src the placeholders will be replaced with actual values during the build.

For example if you add APP_NAME=Angularjs seed to the env/dev.sh every instance of %APP_NAME% will be replaced with Angularjs seed

Note that for every change in the env files you'll have to restart the webpack server if it's running.

Known issues

  • Internet Explorer 10 is not supported in development mode

Versioning

About

AngularJS + webpack 4 example project, using ES2015+ with Babel, webpack 4, ESLint, SASS (scss) and UI Router

License:MIT License


Languages

Language:JavaScript 71.5%Language:CSS 16.2%Language:HTML 12.3%