i just print an outside module
**test_fib.js**
import * as os from "qjs:os";
const isWin = os.platform === 'win32';
// const { fib } = await import(`./fib.${isWin ? 'dll' : 'so'}`);
import(`./fib.${isWin ? 'dll' : 'so'}`).then(
(res)=> {
console.log('quickjs env', res)
}
)
but show an exception tag
PS D:\Quickjs\build> ./qjs.exe test_fib.js
quickjs env <exception
then i test in node env
**es_li.mjs**
export function hello() {
}
**test_fib.js**
import("./es_li.mjs").then(
(res) => {
console.log('node env', res)
}
)
it is ok
PS D:\Quickjs\build> node test_fib.js
node env [Module: null prototype] { hello: [Function: hello] }