Reference and credits: https://articles.wesionary.team/react-component-library-with-vite-and-deploy-in-npm-579c2880d6ff
- Fork the repo
- Replace
productive-vite-react-library
everywhere by the name of your library.
npm ci
npx husky install
npm run :d
npm run build
npm version x.y.z
npm publish
Do not forget library and packaging best practices! (CHANGELOG, semver, etc.)