0.0.8-development โ€ข Published 1 day ago

@mxmalykhin/template-package v0.0.8-development

Weekly downloads
-
License
MIT
Repository
github
Last release
1 day ago

๐Ÿ’ฆ Template Package

Easy-to-use template for TypeScript libraries for UI or Node.js. It's made for personal use but open for everyone to contribute or suggest improvements.

๐Ÿš€ Why Use This Template?

Skip the setup and dive right into coding. This toolkit is perfect for any TypeScript package, packed with best practices.

โœจ Motivation

This template is my own solution, born out of a desire to have a setup that fits just right for me. I was aware of create-typescript-app, yet I chose to make my own. Through this process, I am continuously gaining valuable insights and skills, and I intend to keep refining this template as I learn more.

๐ŸŒŸ Getting Started

To kick off with this template, choose any of these methods. Don't forget to run pnpm run init to customize it for your project (not needed for the NPX script):

  • Use Template on GitHub: Just click 'Use this template'.
    • โค๏ธ This method helps promote this repository to new interested developers.
  • Git Clone: git clone https://github.com/mxmalykhin/template-package.git your-library-name.
  • Download ZIP: Just download and unzip.
  • NPX Script: (Coming Soon) npx template-package init will do all the setup for you.

๐Ÿ‘ Tip: 'Use this template' on GitHub is quick and shares the love. NPX script will make it even easier soon.

๐Ÿฃ Next Steps: Once the template is installed, pnpm run init gets your template tailored to your needs.

๐Ÿ›  Development Tools

I use esbuild for speedy development builds (pnpm run dev) and rollup-plugin-typescript2 for more thorough type checking in production builds (pnpm run build). This ensures fast iteration and reliable code.

๐Ÿงช Test Your Work

Before sharing your library, test it in real projects to ensure it works as expected:

  • npm link: Great for local testing.
  • yarn link/pnpm link: Alternative options that work similarly to pnpm link.

๐Ÿ”ง Environment Support

Supports ESM/CJS/UMD/IIFE for broad compatibility. This template is designed to work in Node.js, the browser, and other environments.

๐Ÿ” ESM-Centric Approach

Striving for a "first-class solution" in ESM, this template is an endeavor to stay at the forefront of JavaScript development practices, ensuring efficiency and modern standards are met.

๐Ÿ’ก Contributing

Want to contribute? Great! Feel free to fork, make changes, and submit pull requests. Whether it's fixing bugs, adding features, or improving documentation, all contributions are welcome.

โœจ Features

  • Node.js & Web Compatibility: Ready for ESM/CJS/UMD/IIFE modules, making it versatile for various environments.
  • Init package: pnpm run init makes it easy to customize your template for your project.
  • Extended Integration: Future updates to include more integrations for a wider range of use cases.
  • Tech stack: improve README.md for better understanding of the tech stack used in this template.

๐Ÿ“ Note

This template is a starting point. Feel free to customize it to fit your project's needs.