RyanMarcus / dirty-json

A parser for invalid JSON
GNU Affero General Public License v3.0
294 stars 30 forks source link

Praser breakes on javascript types #28

Closed MrBartusek closed 4 years ago

MrBartusek commented 4 years ago

Passing this intro dirty-json:

{
        type: String,
        value: 'something'
}

results in:

Error: Found } that I can't handle at line 0:45
    at reduce (C:\Users\MrBartusek\Documents\Development\docs\node_modules\dirty-json\parser.js:517:15)
    at Object.parse (C:\Users\MrBartusek\Documents\Development\docs\node_modules\dirty-json\parser.js:99:16)
    at Object.parse (C:\Users\MrBartusek\Documents\Development\docs\node_modules\dirty-json\dirty-json.js:39:23)
    at praseFileContent (C:\Users\MrBartusek\Documents\Development\docs\scripts\updateConfig.js:32:19)
    at Object.<anonymous> (C:\Users\MrBartusek\Documents\Development\docs\scripts\updateConfig.js:15:21)
RyanMarcus commented 4 years ago

This should now be fixed! Thanks for reporting the issue. :)