1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58
|
=== tests/cases/conformance/node/allowJs/subfolder/index.js ===
// cjs format file
import {h} from "../index.js";
>h : Symbol(h, Decl(index.js, 1, 8))
import mod = require("../index.js");
>mod : Symbol(mod, Decl(index.js, 1, 30))
import {f as _f} from "./index.js";
>f : Symbol(f, Decl(index.js, 4, 36))
>_f : Symbol(_f, Decl(index.js, 3, 8))
import mod2 = require("./index.js");
>mod2 : Symbol(mod2, Decl(index.js, 3, 35))
export async function f() {
>f : Symbol(f, Decl(index.js, 4, 36))
const mod3 = await import ("../index.js");
>mod3 : Symbol(mod3, Decl(index.js, 6, 9))
>"../index.js" : Symbol(mod, Decl(index.js, 0, 0))
const mod4 = await import ("./index.js");
>mod4 : Symbol(mod4, Decl(index.js, 7, 9))
>"./index.js" : Symbol(mod2, Decl(index.js, 0, 0))
h();
>h : Symbol(h, Decl(index.js, 1, 8))
}
=== tests/cases/conformance/node/allowJs/index.js ===
// esm format file
import {h as _h} from "./index.js";
>h : Symbol(h, Decl(index.js, 4, 46))
>_h : Symbol(_h, Decl(index.js, 1, 8))
import mod = require("./index.js");
>mod : Symbol(mod, Decl(index.js, 1, 35))
import {f} from "./subfolder/index.js";
>f : Symbol(f, Decl(index.js, 3, 8))
import mod2 = require("./subfolder/index.js");
>mod2 : Symbol(mod2, Decl(index.js, 3, 39))
export async function h() {
>h : Symbol(h, Decl(index.js, 4, 46))
const mod3 = await import ("./index.js");
>mod3 : Symbol(mod3, Decl(index.js, 6, 9))
>"./index.js" : Symbol(mod, Decl(index.js, 0, 0))
const mod4 = await import ("./subfolder/index.js");
>mod4 : Symbol(mod4, Decl(index.js, 7, 9))
>"./subfolder/index.js" : Symbol(mod2, Decl(index.js, 0, 0))
f();
>f : Symbol(f, Decl(index.js, 3, 8))
}
|