Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F7533959
import_dynamic_filename_capture_parent.mjs
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
576 B
Referenced Files
None
Subscribers
None
import_dynamic_filename_capture_parent.mjs
View Options
function assert(condition, message) {
if (!condition) throw new Error(message);
}
const topFilename = import.meta.filename;
async function loadChild() {
return await import('./import_dynamic_filename_capture_child.mjs');
}
const child = await loadChild();
assert(import.meta.filename === topFilename, 'parent import.meta.filename drifted');
assert(
child.childFilename.endsWith('/tests/import_dynamic_filename_capture_child.mjs'),
`dynamic import resolved from wrong base: ${child.childFilename}`
);
console.log(`import.dynamic.filename.capture:${topFilename}`);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Jun 17, 11:38 AM (1 d, 4 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
543174
Default Alt Text
import_dynamic_filename_capture_parent.mjs (576 B)
Attached To
Mode
rANT Ant
Attached
Detach File
Event Timeline
Log In to Comment