Skip to content
Node.js implementation of a serializer for major Hypermedia Formats, in the context of Representor Pattern.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
representors
test
.gitignore
.jshintrc
.npmignore
.travis.yml
Dockerfile
LICENSE
README.md
circle.yml
docker-compose.yml
package.json
representor.js

README.md

Representor (Serializer)

MIT License CI Tests Status Build Status NPM Version  

Node.js implementation of a serializer for major Hypermedia Formats, in the context of Representor Pattern.

Installation

> npm install representor-serializer --save

Usage

var repserializer = require('representor-serializer');

var uber = repserializer(internal_representation, 'application/vnd.uber+json');

Included tests showcase examples of internal representation: https://github.com/apiacademy/representor/tree/master/test/fixtures

Currently Implemented Hypermedia Formats

  • HAL: application/hal+json (and application/vnd.hal+json for backwards-compatibility).
  • SIREN: application/vnd.siren+json
  • Collection+JSON: application/vnd.collection+json
  • UBER: application/vnd.uber+json

How to add a new serializer

@TODO

You can’t perform that action at this time.