Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

typeson

Package Overview
Dependencies
Maintainers
1
Versions
58
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

typeson - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

2

package.json
{
"name": "typeson",
"version": "1.0.1",
"version": "1.0.2",
"description": "JSON with types",

@@ -5,0 +5,0 @@ "main": "typeson.js",

@@ -5,5 +5,3 @@ # Typeson

# Why?
JSON can only contain simple types. Many times you'd want to serialize Dates and Errors but there's no standard JSON-ish way to do that. Typically, you'd need it when you:
1. want to send complex types over the wire
2. want to persist complex types
JSON can only contain simple types: strings, numbers, booleans, Arrays and Objects. In case you want to serialize a Date or an Error object for example, you will need fix that manually. Typeson is just JSON that complements non-trivial properties with type info. The metadata is a $types property in the result that maps each non-trivial property to a type name. You can configure the registry of type names and defines how to encapsulate and revive custom types.

@@ -10,0 +8,0 @@ # Features

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