
Security News
New CVE Forecasting Tool Predicts 47,000 Disclosures in 2025
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.
@syslogic/graph-serializer
Advanced tools
Typescript serializer for converting betweet JSON data and Object graphs
Graph serializer is a lightweight library for converting JSON data structures to typed objects usable in typescript. Benefits include better type checking in your IDE, better type safety, and standardized date conversion. Primary use case is for easy integration of RESTful services and typescript.
Add graph-serializer to your dependencies:
npm i --save @syslogic/graph-serializer
Graph-serializer provides an annotation which you can use in your typescrpt entities. You can use the @serializable
to specify which properties need to be (de)serialized.
The serialize
and deserialize
functions can then be used with the entity
import {serializable, deserialize, serialize} from "@syslogic/graph-serializer"
class Foo {
@serializable()
public thisWillBeSerialized: string = 'test';
}
let fooObj = deserialize(Foo, {thisWillBeSerialized: 'bar'}); // fooOjb instanceof Foo === true
let fooGraph = serialize(new Foo()); // fooGraph = {thisWillBeSerialized: 'bar'}
There are a few serializer parameters to seraialize all sorts of serializers. Check the test directory for more examples. Features include:
Date
deserializationFAQs
Typescript serializer for converting betweet JSON data and Object graphs
The npm package @syslogic/graph-serializer receives a total of 1,824 weekly downloads. As such, @syslogic/graph-serializer popularity was classified as popular.
We found that @syslogic/graph-serializer demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Research
Security News
Eight new malicious Firefox extensions impersonate games, steal OAuth tokens, hijack sessions, and exploit browser permissions to spy on users.