Implementing a simple browser environment using vm2 in Node.js.
npm install vm2
in the project's current directory.- Input the JavaScript code you want to debug to path
user/test/input.js
- Run
main.js
from the root directory of the project. - The output.js file in the
user/test
directory is the final generated JavaScript file. - Execute
output.js
and use the logs to make targeted changes to the environment
Since a browser is essentially a operating system, it is not really possible to fully implement a browser environment using Node.js. Therefore, I can only do my best to improve this project as much as possible. My ability is limited as an individual, but everyone can also participate in this project and work together to constantly improve it.