un icon indicating copy to clipboard operation
un copied to clipboard

Write a React wrapper

Open dmitriz opened this issue 8 years ago • 0 comments

Enable to wrap uncomponents as React components to make them available in any React app.

As described here: https://github.com/funkia/turbine/issues/34

The main idea is to configure the mount wrapper, when no element el is passed, to return a React component written as

({ model, view }) => class extends React.Component {
    constructor () {
         super()

         // tell React to update in reactions on stream events
         stateStream.map(this.forceUpdate)
    }
    render = () => view(state)
}

dmitriz avatar May 16 '17 05:05 dmitriz