MCPcopy Index your code
hub / github.com/TypeScriptToLua/TypeScriptToLua / checkNodeVersion

Function checkNodeVersion

src/tstl.ts:222–229  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

220}
221
222function checkNodeVersion(): void {
223 const [major, minor] = process.version.slice(1).split(".").map(Number);
224 const isValid = major > 12 || (major === 12 && minor >= 13);
225 if (!isValid) {
226 console.error(`TypeScriptToLua requires Node.js >=12.13.0, the current version is ${process.version}`);
227 process.exit(1);
228 }
229}
230
231checkNodeVersion();
232

Callers 1

tstl.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected