π Official documentation π
@localizer simplifies localization, formatting, and translation with a type-safe approach. It ensures consistency, reduces runtime errors, and supports multiple languages, dynamic translations, and locale-specific formatting.
- Type-safe Localization: Compile-time safety for translations, reducing runtime errors.
- Flexible Formatting: Supports locale-specific date, number, and custom formatting.
- Dynamic Translations: Enables runtime language switching and dynamic content.
- Multi-language Support: Simplifies managing multiple languages.
- Lightweight and Performant: Optimized for performance with minimal overhead.
- Extensible: Easily customizable for specific localization needs.
@localizer is modular, offering flexibility for various localization needs:
@localizer/core
: Essential utilities for localization.@localizer/transform
: Locale-dependent transformations.
@localizer/format
: Built-in formatting for dates, numbers, and more.@localizer/format-datetime
: Date and time formatting.@localizer/format-displayname
: Formatting for languages, countries, and currencies.@localizer/format-list
: List formatting.@localizer/format-lookup
: Lookup table-based formatting.@localizer/format-number
: Number, measurement, and currency formatting.@localizer/format-relativetime
: Relative time formatting.
@localizer/translate
: TypeScript-native translation library.
Use modules independently or combine them as needed.
@localizer/all
: A meta-package bundling all the modules.
@localizer uses Semantic Versioning, structured as MAJOR.MINOR.PATCH
:
- MAJOR: For breaking changes.
- MINOR: For new features.
- PATCH: For bug fixes.
- Development: Changes are made in feature branches and merged into
main
after review. - Testing: Each release is tested for stability and compatibility.
- Version Tagging: Releases are tagged with the appropriate version.
- Publishing: Releases are published to npm.
We aim to keep backward compatibility within a major version. Breaking changes are documented in the change logs of corresponding packages.
Contributions are welcome! Fix bugs, add features, or improve documentation by following these steps:
- Fork and Clone: Fork the repository and clone it locally:
git clone https://github.com/<your-username>/localizer.git
cd localizer
- Install Dependencies: Install the required dependencies:
npm install
- Create a Branch:
git checkout -b feature/your-feature-name
-
Make Changes: Update the codebase as needed.
-
Run Tests: Verify your changes:
npx nx test <module>
- Commit Changes: Use a clear commit message:
git commit -m "feat: Add new feature"
Refer to the contribution guide for more details.
For questions or assistance, open an issue or contact the maintainers.
Thank you for supporting @localizer!