PowerJSON v1.0.0-alpha release, improved by the data format JSON

PowerJSON

Powerjson is improved by the JSON data interchange format made, it will be JSON support some JavaScript syntax to make it more efficient and available, JSON and solves many problems left over from history.

It supports  single quoted stringmulti-line character stringthe commentoperatorsimport fileimport other file PJSON  like.

Simple Demo

{
    // 字符串
    helloText: 'hello world',
    MultiLineText: `
        Welcome
        to
        PowerJSON!
    `,

    // 文件和导入
    myFile: new File('./file.txt'),
    importPJSONFile: new PJSON('./index2.pjson'),
    getFile: new GET('http://www.powerjson.org'),

    // 运算符
    tenDaySeconds: 60 * 60 * 24 * 10

    // 这里是注释!
    /* 注释2 */
}

compatibility

PowerJSON supports all compatible  ES6  the  browser / js runtime .

Browser:

  • IE >= 11
  • Edge All
  • Firefox >= 6
  • Chrome >= 21
  • Safari >= 7.1
  • Opera> = 15

Node.js:

  • Nodejs >= 6

Guess you like

Origin www.oschina.net/news/110577/power-json-1-0-0-alpha-released