react-tele
TypeScript icon, indicating that this package has built-in type declarations

0.1.2 • Public • Published

Build Status

react-tele

React (JS) telepresence - rendering outside of own DOM subtree.

Quick example

var React = require('react');
var Tele = require('react-tele');
 
React.render(
  <section>
    <h1>
      <Tele.target id="header"/>
    </h1>
    <div>
      <Tele.port id="header">
        Mr. Spock
      </Tele.port>
      USS Enterprise (NCC-1701) science officer.
    </div>
  </section>,
 
  document.getElementById('content')
);

Renders:


Mr. Spock

USS Enterprise (NCC-1701) USS science officer.


Development

Commands

  • Build commonJS version: $ npm start
  • Watch commonJS folder: $ npm run watch
  • Build UMD version: $ npm run build
  • Start dev server for examples (http://localhost:1701/webpack-dev-server/examples/): $ npm run examples
  • Build examples: $ npm run build-examples
  • Run tests once (Firefox): $ npm test
  • Watch tests (Chrome): $ npm wtest

Readme

Keywords

Package Sidebar

Install

npm i react-tele

Weekly Downloads

4

Version

0.1.2

License

MIT

Last publish

Collaborators

  • alexdrel