MCPcopy Create free account
hub / github.com/thinkjs/thinkjs / constructor

Method constructor

lib/application.js:19–32  ·  view source on GitHub ↗

* constructor

(options = {})

Source from the content-addressed store, hash-verified

17 * constructor
18 */
19 constructor(options = {}) {
20 assert(options.ROOT_PATH, 'options.ROOT_PATH must be set');
21 if (!options.APP_PATH) {
22 let appPath = path.join(options.ROOT_PATH, 'app');
23 if (!options.transpiler && !helper.isDirectory(appPath)) {
24 appPath = path.join(options.ROOT_PATH, 'src');
25 }
26 options.APP_PATH = appPath;
27 }
28 if (!options.RUNTIME_PATH) {
29 options.RUNTIME_PATH = path.join(options.ROOT_PATH, 'runtime');
30 }
31 this.options = options;
32 }
33 /**
34 * notify error
35 */

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected