0.1.0 • Published 2 years ago

object-string-parser v0.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

object-string-parser

⚠️⚠️⚠️ actually the source code is only one sentence, and not secure, so don't use it.

Install

npm install object-string-parser

Usage

import { parse } from "object-string-parser";

// 1.
const obj = parse("{foo: 200}").foo; // 200 😄

// 2.
JSON.stringify(parse("{bar: 50}"), undefined, 2);
// convert `{bar: 50}` to `{"bar": 50}`