typescript-to-lua 1.8.0 → 1.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -39,6 +39,9 @@ function validateOptions(options) {
39
39
  if (options.jsx && options.jsx !== typescript_1.JsxEmit.React) {
40
40
  diagnostics.push(diagnosticFactories.unsupportedJsxEmit());
41
41
  }
42
+ if (options.paths && !options.baseUrl) {
43
+ diagnostics.push(diagnosticFactories.pathsWithoutBaseUrl());
44
+ }
42
45
  return diagnostics;
43
46
  }
44
47
  exports.validateOptions = validateOptions;
@@ -32,3 +32,6 @@ export declare const cannotBundleLibrary: (() => ts.Diagnostic) & {
32
32
  export declare const unsupportedJsxEmit: (() => ts.Diagnostic) & {
33
33
  code: number;
34
34
  };
35
+ export declare const pathsWithoutBaseUrl: (() => ts.Diagnostic) & {
36
+ code: number;
37
+ };
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.unsupportedJsxEmit = exports.cannotBundleLibrary = exports.usingLuaBundleWithInlineMightGenerateDuplicateCode = exports.luaBundleEntryIsRequired = exports.couldNotFindBundleEntryPoint = exports.transformerShouldBeATsTransformerFactory = exports.shouldHaveAExport = exports.couldNotResolveFrom = exports.toLoadItShouldBeTranspiled = exports.couldNotReadDependency = exports.couldNotResolveRequire = void 0;
3
+ exports.pathsWithoutBaseUrl = exports.unsupportedJsxEmit = exports.cannotBundleLibrary = exports.usingLuaBundleWithInlineMightGenerateDuplicateCode = exports.luaBundleEntryIsRequired = exports.couldNotFindBundleEntryPoint = exports.transformerShouldBeATsTransformerFactory = exports.shouldHaveAExport = exports.couldNotResolveFrom = exports.toLoadItShouldBeTranspiled = exports.couldNotReadDependency = exports.couldNotResolveRequire = void 0;
4
4
  const ts = require("typescript");
5
5
  const utils_1 = require("../utils");
6
6
  const createDiagnosticFactory = (getMessage, category = ts.DiagnosticCategory.Error) => (0, utils_1.createSerialDiagnosticFactory)((...args) => ({ messageText: getMessage(...args), category }));
@@ -19,4 +19,5 @@ exports.usingLuaBundleWithInlineMightGenerateDuplicateCode = (0, utils_1.createS
19
19
  }));
20
20
  exports.cannotBundleLibrary = createDiagnosticFactory(() => 'Cannot bundle probjects with"buildmode": "library". Projects including the library can still bundle (which will include external library files).');
21
21
  exports.unsupportedJsxEmit = createDiagnosticFactory(() => 'JSX is only supported with "react" jsx option.');
22
+ exports.pathsWithoutBaseUrl = createDiagnosticFactory(() => "When configuring 'paths' in tsconfig.json, the option 'baseUrl' must also be provided.");
22
23
  //# sourceMappingURL=diagnostics.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "typescript-to-lua",
3
- "version": "1.8.0",
3
+ "version": "1.8.1",
4
4
  "description": "A generic TypeScript to Lua transpiler. Write your code in TypeScript and publish Lua!",
5
5
  "repository": "https://github.com/TypeScriptToLua/TypeScriptToLua",
6
6
  "homepage": "https://typescripttolua.github.io/",