Closed gluons closed 6 years ago
(Probably) Fix #19.
I use cross-env to set NODE_ENV to production when you build.
cross-env
NODE_ENV
production
It will remove ton of eval from webpack's cheap-module-eval-source-map devtool (from below lines) when your computer sets NODE_ENV to development. 🤓
eval
cheap-module-eval-source-map
development
https://github.com/xxhomey19/github-file-icon/blob/c31db79dac4f550ecb0db5bcf5ad52950010b14f/webpack.config.js#L96-L98
However, it still has 1 eval in contentscript.bundle.js.
contentscript.bundle.js
g = g || Function("return this")() || (1,eval)("this");
We probably need webpack/webpack#5627 to be resolved, I guess. 🤔
Hi @gluons Thank you for the PR which helps a lot. I create another PR for the issue. Would you mind I close this PR and merge that one?
OK. Let's do it. 🙂
Thank you!
(Probably) Fix #19.
I use
cross-env
to setNODE_ENV
toproduction
when you build.It will remove ton of
eval
from webpack'scheap-module-eval-source-map
devtool (from below lines) when your computer setsNODE_ENV
todevelopment
. 🤓https://github.com/xxhomey19/github-file-icon/blob/c31db79dac4f550ecb0db5bcf5ad52950010b14f/webpack.config.js#L96-L98
However, it still has 1
eval
incontentscript.bundle.js
.We probably need webpack/webpack#5627 to be resolved, I guess. 🤔