@intl-schematic/plugin-defaults
TypeScript icon, indicating that this package has built-in type declarations

1.0.0-rc.7 • Public • Published

@intl-schematic/plugin-defaults

This is a collection of plugins that should be of use to most applications in need of being localized.

npm i -s @intl-schematic/plugin-defaults

Included plugins

This package also exports everything from the included plugins.

Usage

import { createTranslator } from 'intl-schematic';
import { defaultPlugins } from '@intl-schematic/plugin-defaults';

const getLocale = () => new Intl.Locale(navigator.language);

// Notice the plugins array parameter
const t = createTranslator(getDocument, defaultPlugins(getLocale));

Then use according to the instructions of included plugins.

Package Sidebar

Install

npm i @intl-schematic/plugin-defaults

Weekly Downloads

38

Version

1.0.0-rc.7

License

MIT

Unpacked Size

11.4 kB

Total Files

9

Last publish

Collaborators

  • raiondesu