@adra-network/i18n-module
v0.0.8
Published
ADRA i18n module
Downloads
17
Readme
@adra-network/i18n-module
ADRA i18n module for internationalization support in Nuxt 3 applications.
Quick Setup
- Add
@adra-network/i18n-module
dependency to your Nuxt 3 project
# Using npm
npm install @adra-network/i18n-module
Add @adra-network/i18n-module to the modules section of nuxt.config.ts
export default defineNuxtConfig({
modules: ["@adra-network/i18n-module"],
});
Configure the module in nuxt.config.ts (if needed)
// nuxt.config.ts
export default defineNuxtConfig({
adraI18n: {
enabled: true, // Enable or disable the i18n features
langDir: "lang", // Directory of language JSON files
apiKey: "<API_KEY>", // Your API key for the translation service
},
});
That's it! The module is now ready to provide i18n support for your application ✨
The module will automatically handle the loading of language files and switch languages based on the user's preference.
Development
npm install
# Serve with hot reload at localhost:3000
npm run dev
# Build for production and launch server
npm run build
npm run start
# Generate static project
npm run generate
# Run ESLint
npm run lint
# Run tests with Vitest
npm run test
npm run test:watch
# Release new version
npm run release