Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
update for config webpack and install
Need to put an alias entrypoint for inferno on webpack to this file resource.alias["react$"]=directoryPath(`./src/packinferno/inferno-compat`); resource.alias["react-dom"]=directoryPath(`./src/packinferno/inferno-compat`); resource.alias["inferno$"]=directoryPath(`./src/packinferno/xferno.js`);
- Loading branch information
37a216f
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in this commit inferno-core is a folder who contain the original inferno source code
in webpack this file xferno,jsx has to be an alias to inferno
then
inferno-compat package alias react and also react-dom (well if you are not beginner you know that you need it for react)
inferno-compat use inferno in the code so it will take the new version with useeffects because the aliases
You need to export reference from inferno in inferno-compat if you want to have the new function accessible for your code like:
in inferno-compat/index.js
then You can use React.useRef ..etc
to clarify xferno.jsx extends inferno library and you use inferno-compat to plug all to react