Olical / react-faux-dom

DOM like structure that renders to React (unmaintained, archived)
http://oli.me.uk/2015/09/09/d3-within-react-the-right-way/
The Unlicense
1.21k stars 87 forks source link

minify react-faux-dom #147

Closed hamfatfat closed 5 years ago

hamfatfat commented 5 years ago

i used yarn build to export build the build is failed and the bellow error is displayed in the console

Failed to compile.
Failed to minify the code from this file:
./node_modules/react-faux-dom/lib/_element.js:266

after troubleshooting please read the following documentation in react docs, i upgrade react-script still i have the same issue. https://facebook.github.io/create-react-app/docs/troubleshooting#npm-run-build-fails-to-minify in package.json i used the following versions:

 "devDependencies": {
      "react-scripts": "^2.1.8",
   },
"dependencies": {
    "react": "16.6.0",
    "react-dom": "16.6.0",
    "react-faux-dom":"4.4.0"
 }
Olical commented 5 years ago

Ah okay, looks like it's caused by these two let keywords: https://github.com/Olical/react-faux-dom/blob/cdd0394ecd1218468b8fc704c832e7f30878a3bd/lib/_element.js#L266-L272

I'll replace them with var when I can, if anyone wants to replace them in a PR that's fine too.

Olical commented 5 years ago

This should be fixed in v4.4.1.