Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/huruji/v8-load-js-file
v8 嵌入C++ 应用中并实现模块化加载 js 文件的例子(commonjs)
https://github.com/huruji/v8-load-js-file
Last synced: 19 days ago
JSON representation
v8 嵌入C++ 应用中并实现模块化加载 js 文件的例子(commonjs)
- Host: GitHub
- URL: https://github.com/huruji/v8-load-js-file
- Owner: huruji
- Created: 2021-10-03T16:37:10.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2021-10-03T17:28:39.000Z (about 3 years ago)
- Last Synced: 2024-11-11T07:38:48.459Z (about 1 month ago)
- Language: C++
- Homepage:
- Size: 17.9 MB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-github-star - v8-load-js-file
README
# v8-load-js-file
v8 嵌入 C++ 应用中并实现模块化加载 js 文件的例子(commonjs)
> app.js
```js
const test = require('test/test.js')log(test.a)
log(test.add(2,3))
```> test.js
```js
function add (a, b) {
return a + b;
}
module.exports = {
a: test,
add,
}
```运行
```bash
./demo test/app.js
```