Socket
Socket
Sign inDemoInstall

@metamask/utils

Package Overview
Dependencies
Maintainers
9
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@metamask/utils - npm Package Versions

123

3.0.2

Diff

Changelog

Source

[3.0.2]

Fixed

  • Bump superstruct to ^0.16.5 (#26)
    • superstructs 0.16.1 through 0.16.4 were not compatible with Node 14; this restores that compatibility.
gudahtt
published 3.0.1 •

Changelog

Source

[3.0.1]

Fixed

  • Promote @types/debug from development dependencies to production dependencies (#23)
gudahtt
published 3.0.0 •

Changelog

Source

[3.0.0]

Added

  • Add logging functions (#20)
  • Add frozen collections (implemented in #5 but exported in #19)

Changed

  • BREAKING: Improve types and type validation (#19)
    • Various type changes have been made that might be breaking:
      • The JsonRpcRequest and JsonRpcNotification types now include a generic constraint requiring that the Params type extends the JsonRpcParams type.
      • The JsonRpcSuccess and JsonRpcResponse types now include a generic contraint for the Result type, requiring that it extends the Json type.
      • Various validation functions now accept unknown parameters rather than specific types. This should not be breaking except that it may affect type inference for the parameters passed in.
    • New JSON-related functions have been added:
      • assertIsJsonRpcResponse
      • isJsonRpcResponse
      • InferWithParams
      • JsonRpcParams
    • New JSON Struct types have been added:
      • JsonRpcErrorStruct
      • JsonRpcFailureStruct
      • JsonRpcIdStruct
      • JsonRpcParamsStruct
      • JsonRpcRequestStruct
      • JsonRpcResponseStruct
      • JsonRpcSuccessStruct
      • JsonRpcVersionStruct
      • JsonStruct
gudahtt
published 2.1.0 •

Changelog

Source

[2.1.0]

Added

  • Add JSON storage validation and limit utilities (#14)
    • Adds a new function validateJsonAndGetSize.
rekmarks
published 2.0.0 •

Changelog

Source

[2.0.0]

Added

  • Add more JSON utils (#8)

Changed

  • BREAKING: Refactor and expand time utils (#9)
    • Adds a new function, inMilliseconds, and moves the time constants into a TypeScript enum.
rekmarks
published 1.0.0 •

Changelog

Source

[1.0.0]

Added

  • Initial release
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc