This repo contains a basic template for working with Web Components in Typescript.
Web Components allow you to create custom HTML elements that can be used in your web pages. This starter template contains basic classes to work with them. The template is:
- ⚛️ Modular:
- write HTML, CSS, and TypeScript in separate files
- Models and ViewModels, keep the state separate from the DOM
- 🪶 Minimal:
- no external dependencies, only Vite and vanilla TypeScript
- 💪 Powerful:
- pubSub pattern for event handling and communication
-> see 📖 Documentation
- use the template to create your own repo
- clone your repo
- run
npm install
- run
npm run dev
- make changes to the code
- run
npm run build
- run
npm run preview
and open the preview in a browser