Electron+vite使用抛出错误✓ 259 modules transformed. [commonjs--resolver] node_modules/node-easy-cert/node_modules/node-forge/js/forge.js (55:11): 'delete' cannot be called on an identifier in strict mode file: E:/gitlab/Cesium-Examples/roibest-preview-tools/node_modules/anyproxy/lib/webInterface.js:55:11 53: deps = (typeof ids === 'string') ? factory.slice(2) : ids.slice(2); 54: if(nodeJS) { 55: delete define; ^ 56: return tmpDefine.apply(null, Array.prototype.slice.call
- Dominant language
- JavaScript
- Stars
- 7.9k
- Forks
- 1.2k
- PR merge metrics
- No merged PRs in 30d
Description
Plese fill the template when you reporting a new issue, thanks!
#### Which platform are you running AnyProxy
windows
#### The version of the AnyProxy
4.1.3
#### Your expected behavior of AnyProxy
Electron+vite可以正常使用
#### The actual behavior of AnyProxy
报错✓ 259 modules transformed.
[commonjs--resolver] node_modules/node-easy-cert/node_modules/node-forge/js/forge.js (55:11): 'delete' cannot
be called on an identifier in strict mode
file: E:/gitlab/Cesium-Examples/roibest-preview-tools/node_modules/anyproxy/lib/webInterface.js:55:11
53: deps = (typeof ids === 'string') ? factory.slice(2) : ids.slice(2);
54: if(nodeJS) {
55: delete define;
^
56: return tmpDefine.apply(null, Array.prototype.slice.call(arguments, 0));
57: }
#### The log of the error
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by inspecting node_modules/anyproxy/lib/webInterface.js around line 55 and the node-forge error reported during the Electron+Vite transformation. Reproduce the build on Windows and trace how AnyProxy is loaded; done means Electron+Vite can use AnyProxy without the strict-mode build error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- electron, javascript, node.js, vite
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100