opentelemetry-js
opentelemetry-js copied to clipboard
use of eval is strongly discouraged
trafficstars
Bundling with rollupjs generated the following error because of protobufjs usage.
(!) Use of eval is strongly discouraged
https://rollupjs.org/troubleshooting/#avoiding-eval
../node_modules/@protobufjs/inquire/index.js
10: function inquire(moduleName) {
11: try {
12: var mod = eval("quire".replace(/^/,"re"))(moduleName); // eslint-disable-line no-eval
^
13: if (mod && (mod.length || Object.keys(mod).length))
14: return mod;
This is included via the following tree:
└─┬ @opentelemetry/[email protected]
└─┬ @opentelemetry/[email protected]
└── [email protected]
I don't understand why this is necessary, but it could potentially cause issues for code bundled via rollup.
https://rollupjs.org/troubleshooting/#avoiding-eval
Also see https://github.com/protobufjs/protobuf.js/issues/1754