blog
blog copied to clipboard
2016/05/04 Node.js 是怎么工作?
Browser
Virtual Machine
V8
V8 Templates
Function Template
Object Template
By now, we learned how to expose C++ methods\structures to JavaScript. We will now learn how to run JavaScript code in those modified contexts. It’s simple. Just compile and run principle.
V8 Compile && Run JavaScript
C++ -> V8 Templates -> Run JavaScript -> ?
Modularity
C++ Module Loader
JavaScript Module Loader
Let’s start with NativeModule first.
Another thing is Module loader implementation.