@wyxin/baijiaxing
TypeScript icon, indicating that this package has built-in type declarations

0.0.4 • Public • Published

baijiaxing(Hundred Family Surnames)

Build & Deploy npm version Coverage Status

It's an array of Hundred of Chinese Family Surnames.

Install

This package is a pure ESM package. It cannot use require.

npm install @wyxin/baijiaxing

Usage

import { name, py, pinxie } from "@wyxin/baijiaxing";
console.log(name)      // => ['赵','钱','孙','李','吾'......]
console.log(name[4])   // => '吾'
console.log(py)        // => ['zhào','qián','sūn','lǐ']
console.log(pinxie)    // => ['zhao','qian','sun','li']
console.log(py[name.indexOf('孙')])  // => 'sūn'

You can also use it this way.

import name from "@wyxin/baijiaxing/name.json";
import name from "@wyxin/baijiaxing/py.json";
import name from "@wyxin/baijiaxing/pinxie.json";
console.log(name)      // => ['赵','钱','孙','李','吾'......]
console.log(name[4])   // => '吾'
console.log(py)        // => ['zhào','qián','sūn','lǐ']
console.log(pinxie)    // => ['zhao','qian','sun','li']

License

It is an open-source npm package licensed under the "MIT License".

Package Sidebar

Install

npm i @wyxin/baijiaxing

Weekly Downloads

3

Version

0.0.4

License

MIT

Unpacked Size

84.1 kB

Total Files

9

Last publish

Collaborators

  • techrookiewyx