Template using vitejs and typescript (and more) for create easily and quickly nice JS library !
- 🦾 TypeScript, of course
- 🎨 Lint your commit with commitlint using conventional commits
- 🎨 Lint your code with typescript-eslint
- 🎨 Format your code with prettier
- 💄 Perform scss using sass
- ⚓ Manage your commit hook width husky
- ⚙️ Unit Testing with Vitest
- 🧪 E2E Testing with Playwright
- 📝 Generate change log based on commit using commit-and-tag-version
- 📄 Generate static site using vitepress
- 🗒 Generate markdown doc from ts using typedoc and typedoc-plugin-markdown
- 🏷️ Generate declaration files with vite-plugin-dts
- Trigger custom event with tiny plugin MicroEvent
- Create plugin(s) with tiny plugin MicroPlugin
When you use this template, try follow the checklist to update your info properly
- Change the class name file
- Change the class name file in
srcthen the class name inindex.html/vite.config.ts/src/MyClass.tsAND in scriptbuild:docsintopackage.json - Change url for repo in
.versionrc.json - Add your style to
src/scss/style.scss(optionnal) - Add the favicon in
public(optional) - Clean up the README (optional)
- Update you website name and more in
docsfolder or remove it and updatedocs:apiscript
Just run and visit http://localhost:5173/
yarn devTo build the lib, run
yarn buildAnd you will see the generated file in dist that ready to be served.
Run dev mode website
yarn docs:devfor more you can see
docs/package.jsonscripts
Generate api doc from typedoc
yarn build:apiyarn release -- --first-releaseSee all availables options here
yarn releaseyou can precise version using major, minor or patch
yarn release -- --release-as minoror you can pass specific version
yarn release -- --release-as 1.1.0