Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: jsonValue() type is generic #6865

Merged
merged 3 commits into from Feb 11, 2021
Merged

fix: jsonValue() type is generic #6865

merged 3 commits into from Feb 11, 2021

Commits on Feb 11, 2021

  1. fix: jsonValue() type is generic

    During the migration to TS we changed `jsonValue` so it returned
    `<Record<string, unknown>>`. This is only true if all the JSON values it
    returns are objects; but it could return an array, a string, a number,
    etc. Therefore we make the type generic, setting the default to
    `unknown`, so the user has control over the type.
    jackfranklin committed Feb 11, 2021
    Copy the full SHA
    3f31e40 View commit details
    Browse the repository at this point in the history
  2. Copy the full SHA
    524cdc0 View commit details
    Browse the repository at this point in the history
  3. Copy the full SHA
    1c0c00a View commit details
    Browse the repository at this point in the history