npm.io
1.2.0 • Published 2 weeks ago

@intlify/utils

Licence
MIT
Version
1.2.0
Deps
0
Size
227 kB
Vulns
0
Weekly
0
Stars
17

@intilfy/utils

npm version npm downloads CI

Collection of i18n utilities

Features

️  Modern: ES Modules first and respect Web Standard and ECMAScript Internationalization APIs

️  Compatible: support CommonJS and various JS environments

️️  Minimal: Small and fully tree-shakable

️️  Type Strong: Written in TypeScript, with full JSdoc

Installation

Node.js
# Using npm
npm install @intlify/utils

# Using yarn
yarn add @intlify/utils

# Using pnpm
pnpm add @intlify/utils
Deno

Note: Deno is no longer supported, and @intlify/utils is not published to JSR after 1.1.0. On Deno, you can still import the npm package with npm:@intlify/utils, but it is not tested.

Bun
bun add @intlify/utils
Browser

in your HTML:

<script type="module">
  /**
   * you can install via other CDN URL such as skypack,
   * or, you can also use import maps
   */
  import { isLocale } from 'https://esm.sh/@intlify/utils'

  // something todo
  // ...
</script>

Playground

You can play the below examples:

API

See the API docs

Contributing guidelines

If you are interested in contributing to @intlify/utils, I highly recommend checking out the contributing guidelines here. You'll find all the relevant information such as how to make a PR, how to setup development) etc., there.

Sponsors

The development of @intlify/utils is supported by my OSS sponsors!

sponsor

License

MIT

Keywords