Learn about our RFC process, Open RFC meetings & more.Join in the discussion! »

format-name

0.0.4 • Public • Published

format-name

Greenkeeper badge Build Status npm package Dependency Status devDependency Status

Make correct first/last name combination among different languages including preference.

Installation

yarn add format-name

The Gist

import formatName, { FIRST_LAST, LAST_FIRST } from 'format-name';
 
// different depending on a config
formatName('Ross', 'Khanas', FIRST_LAST); // Ross Khanas
formatName('Ross', 'Khanas', LAST_FIRST); // Khanas Ross
 
// last name is always first
formatName('台綸', '', FIRST_LAST); // 曾台綸
formatName('台綸', '', LAST_FIRST); // 曾台綸

License

MIT

Install

npm i format-name

DownloadsWeekly Downloads

86

Version

0.0.4

License

MIT

Unpacked Size

5.65 kB

Total Files

4

Last publish

Collaborators

  • avatar