json5 breaking changes

npm

14 curated breaking changes across major versions of json5. Use this as a migration checklist before bumping dependencies.

14
changes
Breaking changes by transition
  • 0.1.0 \u2192 0.2.0breaking

    **Breaking:** Negative hexadecimal numbers (e.g. `-0xC8`) are rejected now.

  • 0.1.0 \u2192 0.2.0breaking

    New: Trailing decimal points in decimal numbers are allowed again.

  • 0.1.0 \u2192 0.2.0breaking

    New: `Infinity` and `-Infinity` are now allowed number literals.

  • 0.1.0 \u2192 0.2.0breaking

    New: Plus signs (`+`) in front of numbers are now allowed, since it can

  • 0.1.0 \u2192 0.2.0breaking

    Fix: unescaped newlines in strings are rejected now.

  • 0.0.1 \u2192 0.1.0breaking

    New: Support hexadecimal numbers. (Thanks [@MaxNanasy].)

  • 0.0.1 \u2192 0.1.0breaking

    Fix: Reject octal numbers properly now. Previously, they were accepted but

  • 0.0.1 \u2192 0.1.0breaking

    **Breaking:** Reject "noctal" numbers now (base-10 numbers that begin with a

  • 0.0.1 \u2192 0.1.0breaking

    New: Support leading decimal points in decimal numbers.

  • 0.0.1 \u2192 0.1.0breaking

    **Breaking:** Reject trailing decimal points in decimal numbers now. These

  • 0.0.1 \u2192 0.1.0breaking

    **Breaking:** Reject omitted elements in arrays now. These are disallowed by

  • 0.0.1 \u2192 0.1.0breaking

    Fix: Throw proper `SyntaxError` instances on errors now.

  • 0.0.1 \u2192 0.1.0breaking

    New: Add Node.js `require()` hook. Register via `json5/lib/require`.

  • 0.0.1 \u2192 0.1.0breaking

    New: Add Node.js `json5` executable to compile JSON5 files to JSON.

API access

Get this data programmatically \u2014 free, no authentication.

curl https://depscope.dev/api/breaking/npm/json5
json5 breaking changes — npm migration guide | DepScope