mirror of
https://github.com/curioustorvald/tsvm.git
synced 2026-03-14 06:56:05 +09:00
script modules and 'require()'
This commit is contained in:
10
assets/disk0/tvdos/include/example.js
Normal file
10
assets/disk0/tvdos/include/example.js
Normal file
@@ -0,0 +1,10 @@
|
||||
exports.greet = function() { println("Hello, module!") }
|
||||
|
||||
/*
|
||||
|
||||
Try in your user program:
|
||||
|
||||
let m = require("A:/tvdos/include/example.js")
|
||||
m.greet()
|
||||
|
||||
*/
|
||||
Reference in New Issue
Block a user