npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

jaco

v5.0.0

Published

Japanese Character Optimizer.

Readme

jaco

Japanese Character Optimizer. [English | 日本語]

NPM version

What is

This module optimize Japanese characters.

Convert to Katakana from Hiragana mutually, or sort list by natural phonetic order, or convert to halfwidth from fullwidth mutually.

functions

  • Convert Hiragana <-> Katakana
  • Convert halfwidth <-> fullwidth
  • Check Hiragana, Katakana, halfwidth, fullwidth, and so on.
  • Sort by natural phonetic order.
    • Supported voiced marks, prolonged sound marks, iteration marks.
  • Has compatible native string object API.

installation

for NodeJS

$ yarn add jaco

Usage

// Partial functions
import toKatakana from 'jaco/toKatakana';
import toHiragana from 'jaco/toHiragana';

toKatakana('ニホンゴのモジなど'); // => ニホンゴノモジナド
toHiragana('ニホンゴのモジなど'); // => にほんごのもじなど
// Import all functions
import { toKatakana, toHiragana } from 'jaco';

toKatakana('ニホンゴのモジなど'); // => ニホンゴノモジナド
toHiragana('ニホンゴのモジなど'); // => にほんごのもじなど

Functions

| Function | Args | Description | | ---------------------------- | ---------------------------------- | -------------------------------------------------------------- | | addSemivoicedMarks | str | 半濁点を追加する | | addVoicedMarks | str | 濁点を追加する | | byteSize | str | 文字列のバイトサイズを返す | | combineSoundMarks | str [, convertOnly] | 濁点・半濁点とひらがな・かたかなを結合させる | | convertIterationMarks | str | 繰り返し記号をかなに置き換える | | convertProlongedSoundMarks | str | 長音符をかなに置き換える | | hasSmallLetter | str | 小書き文字を含むかどうか | | hasSurrogatePair | str | サロゲートペア文字列を含んでいるかどうか | | hasUnpairedSurrogate | str | ペアになっていないサロゲートコードポイントを含んでいるかどうか | | isNumeric | str [, negative [, floatingPoint]] | 数字だけで構成されているかどうか | | isOnly | str, characters | 該当の文字だけで構成されているかどうか | | isOnlyHiragana | str | ひらがなだけで構成されているかどうか | | isOnlyKatakana | str | カタカナだけで構成されているかどうか | | naturalKanaOrder | a, b | 配列の五十音順ソートをするためのソート関数 | | naturalKanaSort | array | 配列の五十音順ソートをする | | remove | str, pattern | 文字列を取り除く | | removeUnpairedSurrogate | str | ペアになっていないサロゲートコードポイントの削除 | | removeVoicedMarks | str [, ignoreSingleMark] | 濁点・半濁点を取り除く | | replaceFromMap | str, convMap | キーがパターン・値が置換文字列のハッシュマップによって置換する | | toBasicLetter | str | 小書き文字を基底文字に変換する | | toHiragana | str [, isCombinate] | ひらがなに変換する | | toKatakana | str [, toWide] | カタカナに変換する | | toNarrow | str [, convertJapaneseChars] | 半角に変換 | | toNarrowAlphanumeric | str | 英数字を半角に変換 | | toNarrowJapanese | str | カタカナと日本語で使われる記号を半角に変換 | | toNarrowKatakana | str [, fromHiragana] | 半角カタカナに変換する | | toNarrowSign | str | 記号を半角に変換 | | toNarrowSymbolForJapanese | str | 日本語で使われる記号を半角に変換 | | toNumeric | str [, negative [, floatingPoint]] | 数字に変換する | | toPhoneticKana | str | よみの文字に変換する | | toWide | str | 全角に変換 | | toWideAlphanumeric | str | 英数字を全角に変換 | | toWideJapanese | str | カタカナと日本語で使われる記号を全角に変換 | | toWideKatakana | str | 全角カタカナに変換する | | toWideSign | str | 記号を全角に変換 | | toWideSymbolForJapanese | str | 日本語で使われる記号を全角に変換 |