Introducing Socket Firewall: Free, Proactive Protection for Your Software Supply Chain.Learn More
Socket
Book a DemoInstallSign in
Socket

drator

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

drator

Simple Hydration API for sending data between the server and the client

latest
Source
npmnpm
Version
0.1.8
Version published
Maintainers
1
Created
Source

Drator

Simple API for sending data from the server to the client mainly so I can get used to publishing to npm.

Usage

// server.js
import {dehydrate} from 'drator';

const data = {
  simple: 'object'
}

const markup = dehydrate('App', data);

// 'window.App={"simple":"object"}'
// client.js
import {hydrate} from 'drator';

const data = hydrate('App');

data.simple; // 'object'

Keywords

drator

FAQs

Package last updated on 13 Sep 2015

Did you know?

Socket

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.

Install

Related posts