react-hyperscript
react-hyperscript copied to clipboard
add way to replace `React.createElement` function.
I wanted to use this package with https://github.com/calmm-js/karet (and also https://github.com/infernojs/inferno, but mostly karet
) and doesn't seem to be a way, unless I forked it just to replace the react
import with karet
. But I guess this solves all the problems while still keeping everything working as it is.
Now if I want to use karet
I can do
const h = require('react-hyperscript')
h.createElement = require('karet').createElement
and use it normally.