mirror of
https://github.com/ragestudio/linebridge.git
synced 2025-06-09 10:34:17 +00:00
added modules.d.ts
This commit is contained in:
parent
7e9ae5edc5
commit
eec835b6e8
10
src/index.js
10
src/index.js
@ -1,17 +1,13 @@
|
|||||||
const path = require('path')
|
const path = require('path')
|
||||||
|
|
||||||
//* set globals
|
//* set globals
|
||||||
global.runtime = runtime
|
global.runtime = process.runtime
|
||||||
global.IS_DEV = runtime.helpers.isDevMode()
|
global.IS_DEV = process.runtime.helpers.isDevMode()
|
||||||
global.RELIC_ORIGIN = require('./relicOrigin.json')
|
global.RELIC_ORIGIN = require('./relicOrigin.json')
|
||||||
global.SERVER_VERSION = runtime.helpers.getVersion()
|
global.SERVER_VERSION = process.runtime.helpers.getVersion()
|
||||||
global.SERVER_MANIFEST = "server.manifest"
|
global.SERVER_MANIFEST = "server.manifest"
|
||||||
global.SERVER_MANIFEST_PATH = path.resolve(process.cwd(), SERVER_MANIFEST)
|
global.SERVER_MANIFEST_PATH = path.resolve(process.cwd(), SERVER_MANIFEST)
|
||||||
|
|
||||||
runtime.registerModulesAliases({
|
|
||||||
"@classes": path.resolve(__dirname, 'classes'),
|
|
||||||
})
|
|
||||||
|
|
||||||
//* import libraries
|
//* import libraries
|
||||||
const Classes = require('./classes')
|
const Classes = require('./classes')
|
||||||
const Server = require("./server")
|
const Server = require("./server")
|
||||||
|
12
src/modules.d.ts
vendored
Normal file
12
src/modules.d.ts
vendored
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
declare module 'cloudlink' {
|
||||||
|
export namespace client {
|
||||||
|
export class Bridge {};
|
||||||
|
export function createInterface(address: string): Promise<object>;
|
||||||
|
}
|
||||||
|
export namespace server {
|
||||||
|
|
||||||
|
}
|
||||||
|
export namespace classes {
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user