New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

react-render

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-render

React rendering wrapper

latest
Source
npmnpm
Version
4.0.0
Version published
Weekly downloads
203
-4.25%
Maintainers
1
Weekly downloads
 
Created
Source

react-render

Build Status

Handles the simple use case of importing a component and rendering it to markup.

Installation

npm install react-render

Usage

const reactRender = require('react-render');

reactRender({

  // An absolute path to a module exporting your component
  path: '/abs/path/to/component.js',

  // Optional
  // --------

  // A string containing a JSON-serialized object which will be used
  // during rendering
  serialisedProps: '...',

  // An object which will be used during rendering
  props: {},

  // A flag indicating if you wish to render the component to static
  // markup. Defaults to false.
  toStaticMarkup: true,

  // A flag indicating if you wish to disable caching for components. This is
  // especially useful in development. Defaults to false.
  noCache: false

}, function(err, markup) {
  if (err) throw err;

  console.log(markup);
});

FAQs

Package last updated on 13 Aug 2019

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