A template to use [email protected] to build ES6 code into ES5. This template includes Bootstrap 4.3.1 and jQuery 3.4.1
- Use VS Code to edit the project
- Use the integrated terminal inside of VS Code to run commands (accessed by clicking the Terminal tab and then New Terminal)
- If you open the project folder in VS Code (the top level folder with the package.json file), the integrated terminal will start in the project folder so you don't need to
cd
- If you open the project folder in VS Code (the top level folder with the package.json file), the integrated terminal will start in the project folder so you don't need to
- Install NodeJS if you do not already have it (LTS version recommended)
- Clone or download the repo
- Open a terminal and
cd
to this folder- For MacOS, open Terminal
- For Windows, open Powershell or Command Prompt
- Alternatively, use the integrated terminal in VS Code
- Run the command
npm install
- If you have windows, you may need to have Python2.X installed to run this command
- Build the project
- Run the command
npm run build
to compile the project one time - Run the command
npm run watch
to automatically recompile the project every time you save
- Run the command
- Open
./dist/index.html
in your web browser
You can use css classes from Bootstrap 4.3.1 anywhere in the project
You can use functions from jQuery 3.4.1 anywhere in the JavaScript code
ESLint is a library that helps to maintain a standard code formatting and is used in many corporate settings. I have provided an example lint file that enforces certain whitespace and syntax rules on the code.
- To see how your code compares to the lint rules, run the command
npm run lint -s
- To automatically fix some types of lint errors, run
npm run lint -s -- --fix
- There is also an ESLint VS Code Extension that will show lint errors in the code editor