A Yeoman Generator for creating websites with TypeScript, Sass, ESLint and Webpack 5
First, install Yeoman and generator-webpack-ts using npm (we assume you have pre-installed node.js).
npm install -g yo
npm install -g generator-webpack-ts
Then generate your new project:
mkdir my-project
cd my-project
yo webpack-ts
The generator will prompt if you want to include the Workbox service worker helper.
See my-project/README.md
for information on working with your new project.
You can add new classes any time with the subgenerator. Add the --skip-styles
flag to skip generating the SCSS file when it is not desired.
Add the --element
flag to generate a Web Component. Element
will be appended to the class name you supply.
yo webpack-ts:classlib [optional/path/]another-greeter [--skip-styles] [--element]
Build your project:
npm run build
Test your project:
npm test
ISC © Gary Bortosky