This is the example project used for the Mike.Works Modern JavaScript course.
- Webpack 3
- React v16
- Babel 7.x, setup with the stage-2 plugins, compiling to ES5 JavaScript
- ESLint for linting, setup with a strict set of rules derived from Airbnb's ESLint Config
- sass-loader for traditional management of styles
- extract-text-webpack-plugin so compiled styles are external stylesheets instead of inline style blocks
- Jest as a testing platform
npm start <exercise-name>
This will be an un-minified version of an exercise, and will include some webpack-specific tooling, intended only for development use
npm run build:dev <exercise-name>
This will be an optimized version of the exercise
npm run build:dist <exercise-name>
Exercises are standalone mini-projects with the following folder structure.
index.html # HTML served for exercise
./src # Scripts (js and jsx)
β index.js - # Entry point for the mini-project
./styles # Styles
β app.scss # (optional) Entry point for styles
./tests # Tests
β myfile.test.js # Tests must have *.test.js
Global styles can be placed in public/styles/app.scss
. These are available across all examples
While the general license for this project is the BSD 3-clause, the exercises themselves are proprietary and are licensed on a per-individual basis, usually as a result of purchasing a ticket to a public workshop, or being a participant in a private training.
Here are some guidelines for things that are OK and NOT OK, based on our understanding of how these licenses work:
- Using everything in this project other than the exercises (or accompanying tests) to build a project used for your own free or commercial training material
- Copying code from build scripts, configuration files, tests and development harnesses that are not part of the exercises specifically, for your own projects
- As an owner of an individual license, using code from tests, exercises, or exercise solutions for your own non-training-related project.
- Using this project, or any subset of exercises contained within this project to run your own workshops
- Writing a book that uses the code for these exercises
- Recording a screencast that contains one or more of this project's exercises
Β© 2018 Mike.Works, All Rights Reserved