0.2.0 • Published 6 years ago

string2js v0.2.0

Weekly downloads
9
License
ISC
Repository
github
Last release
6 years ago

string2js

Create Javascript objects and primitives from their string representation

This module expose a function to convert string values to Javascript objects. It also offer a reviver() function to be used with JSON.parse().

RegExp

The module allow to reviver RegExp objects. To serialize them automatically as JSON, just add the next snippet to the begining of your code:

if(RegExp.prototype.toJSON === undefined)
   RegExp.prototype.toJSON = RegExp.prototype.toString
0.2.0

6 years ago

0.1.1

6 years ago

0.1.0

6 years ago

0.0.0

8 years ago

1.0.0

8 years ago