Skip to content

MegPunyu/string-nan

Repository files navigation

StringNaN

A tiny tool to convert between string and NaN[].

Features

Converts a string and a NaN Array to each other.

Installation

npm install string-nan

Usage

import StringNaN from "string-nan";

const str = "meg";

const nans = StringNaN.toNaNs(str);

console.log(nans);  // [ NaN, NaN, NaN ]

console.log(StringNaN.toString(nans));     // meg
console.log(StringNaN.toString(nans[0]));  // m

nans.reverse();

console.log(StringNaN.toString(nans));  // gem

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published