JSPM

@remirror/i18n

1.0.0-next.52
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 14272
  • Score
    100M100P100Q145729F
  • License MIT

Supported internationalization and locales for the remirror editor.

Package Exports

  • @remirror/i18n
  • @remirror/i18n/dist/i18n.browser.cjs.js
  • @remirror/i18n/dist/i18n.browser.esm.js
  • @remirror/i18n/dist/i18n.cjs.js
  • @remirror/i18n/dist/i18n.esm.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@remirror/i18n) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

@remirror/i18n

Supported internationalization and locales for the remirror editor.

Version Weekly Downloads Bundled size Typed Codebase MIT License

Installation

# yarn
yarn add @remirror/i18n@next

# pnpm
pnpm add @remirror/i18n@next

# npm
npm install @remirror/i18n@next

Usage

The following code creates adds an en translation to your social editor.

import { en as enPlurals } from 'make-plural/plurals';
import React from 'react';
import { SocialEditor } from 'remirror/react/social';

import { i18n } from '@remirror/i18n';
import en from '@remirror/i18n/en/messages';

i18n.loadLocaleData('en', { plurals: anPlurals });

i18n.load({
  en: en.messages,
});

const Editor = () => {
  <SocialEditor i18n={i18n} locale='en' />;
};