mirror of
https://github.com/tribufu/sdk-js
synced 2025-06-16 18:44:18 +00:00
Compare commits
22 Commits
Author | SHA1 | Date | |
---|---|---|---|
4d657a4617 | |||
ea9d87f5ab | |||
f8d2153123 | |||
76cd15fc4c | |||
9c54143d2e | |||
10a0619f80 | |||
5081c11ad5 | |||
3bc568dcb4 | |||
864b46c4a2 | |||
1ab428cfd7 | |||
f02a66c09c | |||
1cf38a35de | |||
be08efe49f | |||
009dfc04ab | |||
962a3de36a | |||
55b4e64594 | |||
b0788d5f72 | |||
14572419cf | |||
db828be54a | |||
b48ee646e1 | |||
80ec992b89 | |||
a2fc56a98f |
@ -7,8 +7,10 @@ import { TribufuApi } from "../build/index.mjs";
|
|||||||
dotenv.config();
|
dotenv.config();
|
||||||
|
|
||||||
async function main() {
|
async function main() {
|
||||||
const api = TribufuApi.fromEnv("TRIBUFU");
|
const tribufu = TribufuApi.fromEnv();
|
||||||
console.log(await api.authGetUserInfo());
|
console.log(
|
||||||
|
await tribufu.getServerByAddressAndQueryPort("mine.tribufu.com", 25565),
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
main();
|
main();
|
||||||
|
14
package.json
14
package.json
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "tribufu",
|
"name": "tribufu",
|
||||||
"version": "0.1.20",
|
"version": "1.0.0",
|
||||||
"description": "Tribufu JS SDK",
|
"description": "Tribufu JS SDK",
|
||||||
"repository": "https://github.com/Tribufu/TribufuJs",
|
"repository": "https://github.com/Tribufu/TribufuJs",
|
||||||
"author": "Tribufu <contact@Tribufu.com>",
|
"author": "Tribufu <contact@Tribufu.com>",
|
||||||
@ -9,7 +9,15 @@
|
|||||||
"types": "./build/index.d.ts",
|
"types": "./build/index.d.ts",
|
||||||
"exports": {
|
"exports": {
|
||||||
"import": "./build/index.mjs",
|
"import": "./build/index.mjs",
|
||||||
"require": "./build/index.cjs"
|
"require": "./build/index.cjs",
|
||||||
|
"types": "./build/index.d.ts"
|
||||||
|
},
|
||||||
|
"typesVersions": {
|
||||||
|
"*": {
|
||||||
|
"*": [
|
||||||
|
"./build/*"
|
||||||
|
]
|
||||||
|
}
|
||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"clean": "rimraf build",
|
"clean": "rimraf build",
|
||||||
@ -19,8 +27,8 @@
|
|||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/node": "^20.10.6",
|
"@types/node": "^20.10.6",
|
||||||
"dotenv": "^16.3.1",
|
"dotenv": "^16.3.1",
|
||||||
"esbuild-node-externals": "^1.12.0",
|
|
||||||
"esbuild": "^0.19.10",
|
"esbuild": "^0.19.10",
|
||||||
|
"esbuild-node-externals": "^1.12.0",
|
||||||
"eslint": "9.11.1",
|
"eslint": "9.11.1",
|
||||||
"prettier": "3.3.3",
|
"prettier": "3.3.3",
|
||||||
"rimraf": "^5.0.5",
|
"rimraf": "^5.0.5",
|
||||||
|
1382
pnpm-lock.yaml
generated
1382
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
@ -22,12 +22,26 @@ const moduleConfig = {
|
|||||||
format: "esm",
|
format: "esm",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const moduleMinConfig = {
|
||||||
|
...moduleConfig,
|
||||||
|
outfile: "build/index.min.mjs",
|
||||||
|
minify: true,
|
||||||
|
sourcemap: true,
|
||||||
|
};
|
||||||
|
|
||||||
const legacyConfig = {
|
const legacyConfig = {
|
||||||
...baseConfig,
|
...baseConfig,
|
||||||
outfile: "build/index.cjs",
|
outfile: "build/index.cjs",
|
||||||
format: "cjs",
|
format: "cjs",
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const legacyMinConfig = {
|
||||||
|
...legacyConfig,
|
||||||
|
outfile: "build/index.min.cjs",
|
||||||
|
minify: true,
|
||||||
|
sourcemap: true,
|
||||||
|
};
|
||||||
|
|
||||||
async function addCopyrightHeader(filename) {
|
async function addCopyrightHeader(filename) {
|
||||||
const header = `// Copyright (c) Tribufu. All Rights Reserved.\n// SPDX-License-Identifier: MIT\n\n`;
|
const header = `// Copyright (c) Tribufu. All Rights Reserved.\n// SPDX-License-Identifier: MIT\n\n`;
|
||||||
const content = await fs.readFile(filename, 'utf-8');
|
const content = await fs.readFile(filename, 'utf-8');
|
||||||
@ -44,5 +58,8 @@ async function buildAndAddHeader(config) {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
await buildAndAddHeader(moduleConfig);
|
|
||||||
await buildAndAddHeader(legacyConfig);
|
await buildAndAddHeader(legacyConfig);
|
||||||
|
await buildAndAddHeader(moduleConfig);
|
||||||
|
|
||||||
|
//await buildAndAddHeader(legacyMinConfig);
|
||||||
|
//await buildAndAddHeader(moduleMinConfig);
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
#!/usr/bin/env sh
|
#!/usr/bin/env sh
|
||||||
|
|
||||||
nswag run ./src/api/api.nswag
|
nswag run ./src/api/api.nswag
|
||||||
|
nswag run ./src/translate/translate.nswag
|
||||||
|
@ -1 +0,0 @@
|
|||||||
import { TribufuApiBase } from "./api.base";
|
|
@ -4,7 +4,7 @@
|
|||||||
"documentGenerator": {
|
"documentGenerator": {
|
||||||
"fromDocument": {
|
"fromDocument": {
|
||||||
"json": "",
|
"json": "",
|
||||||
"url": "http://localhost:5000/v1/openapi.json",
|
"url": "http://localhost:5000/openapi.json",
|
||||||
"output": null,
|
"output": null,
|
||||||
"newLineBehavior": "Auto"
|
"newLineBehavior": "Auto"
|
||||||
}
|
}
|
||||||
@ -26,7 +26,7 @@
|
|||||||
"nullValue": "Null",
|
"nullValue": "Null",
|
||||||
"generateClientClasses": true,
|
"generateClientClasses": true,
|
||||||
"generateClientInterfaces": false,
|
"generateClientInterfaces": false,
|
||||||
"generateOptionalParameters": false,
|
"generateOptionalParameters": true,
|
||||||
"exportTypes": true,
|
"exportTypes": true,
|
||||||
"wrapDtoExceptions": false,
|
"wrapDtoExceptions": false,
|
||||||
"exceptionClass": "TribufuApiError",
|
"exceptionClass": "TribufuApiError",
|
||||||
@ -41,14 +41,14 @@
|
|||||||
"useTransformResultMethod": false,
|
"useTransformResultMethod": false,
|
||||||
"generateDtoTypes": true,
|
"generateDtoTypes": true,
|
||||||
"operationGenerationMode": "SingleClientFromOperationId",
|
"operationGenerationMode": "SingleClientFromOperationId",
|
||||||
"markOptionalProperties": true,
|
"markOptionalProperties": false,
|
||||||
"generateCloneMethod": false,
|
"generateCloneMethod": false,
|
||||||
"typeStyle": "Interface",
|
"typeStyle": "Interface",
|
||||||
"enumStyle": "Enum",
|
"enumStyle": "Enum",
|
||||||
"useLeafType": false,
|
"useLeafType": false,
|
||||||
"classTypes": [],
|
"classTypes": [],
|
||||||
"extendedClasses": [],
|
"extendedClasses": [],
|
||||||
"extensionCode": "api.include.ts",
|
"extensionCode": "../core/include.ts",
|
||||||
"generateDefaultValues": true,
|
"generateDefaultValues": true,
|
||||||
"excludedTypeNames": [],
|
"excludedTypeNames": [],
|
||||||
"excludedParameterNames": [],
|
"excludedParameterNames": [],
|
||||||
@ -67,7 +67,7 @@
|
|||||||
"templateDirectory": null,
|
"templateDirectory": null,
|
||||||
"serviceHost": null,
|
"serviceHost": null,
|
||||||
"serviceSchemes": null,
|
"serviceSchemes": null,
|
||||||
"output": "api.generated.ts",
|
"output": "generated.ts",
|
||||||
"newLineBehavior": "LF"
|
"newLineBehavior": "LF"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -2,8 +2,8 @@
|
|||||||
// SPDX-License-Identifier: MIT
|
// SPDX-License-Identifier: MIT
|
||||||
|
|
||||||
import { TRIBUFU_API_URL } from "..";
|
import { TRIBUFU_API_URL } from "..";
|
||||||
import { TribufuApiBase } from "./api.base";
|
import { TribufuApiBase } from "../core/base";
|
||||||
import { TribufuApiGenerated } from "./api.generated";
|
import { TribufuApiGenerated } from "./generated";
|
||||||
import { TribufuApiOptions } from "../options";
|
import { TribufuApiOptions } from "../options";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -44,22 +44,20 @@ export class TribufuApi extends TribufuApiGenerated {
|
|||||||
*
|
*
|
||||||
* - This will only work if the environment variables are set.
|
* - This will only work if the environment variables are set.
|
||||||
*
|
*
|
||||||
* @param prefix A prefix for the environment variables.
|
* @param prefix A prefix for the environment variables. Default is `TRIBUFU`.
|
||||||
* @returns TribufuApi | null
|
* @returns TribufuApi | null
|
||||||
* @example
|
* @example
|
||||||
* ```ts
|
* ```ts
|
||||||
* // process.env.TRIBUFU_API_KEY
|
* // process.env.TRIBUFU_API_KEY
|
||||||
* const api = TribufuApi.fromEnv("TRIBUFU");
|
* const api = TribufuApi.fromEnv();
|
||||||
* ```
|
* ```
|
||||||
*/
|
*/
|
||||||
public static fromEnv(prefix?: string | null): TribufuApi | null {
|
public static fromEnv(prefix?: string | null): TribufuApi | null {
|
||||||
const envPrefix = prefix ? `${prefix}_` : "";
|
if (typeof process === "undefined") {
|
||||||
|
|
||||||
if (!process) {
|
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
const apiKey = process.env[`${envPrefix}API_KEY`];
|
const apiKey = process.env[`${prefix || "TRIBUFU"}_API_KEY`];
|
||||||
|
|
||||||
if (apiKey) {
|
if (apiKey) {
|
||||||
return TribufuApi.withApiKey(apiKey);
|
return TribufuApi.withApiKey(apiKey);
|
||||||
@ -73,12 +71,12 @@ export class TribufuApi extends TribufuApiGenerated {
|
|||||||
*
|
*
|
||||||
* - This will fallback to the default api if the environment variables are not set.
|
* - This will fallback to the default api if the environment variables are not set.
|
||||||
*
|
*
|
||||||
* @param prefix A prefix for the environment variables.
|
* @param prefix A prefix for the environment variables. Default is `TRIBUFU`.
|
||||||
* @returns TribufuApi | null
|
* @returns TribufuApi | null
|
||||||
* @example
|
* @example
|
||||||
* ```ts
|
* ```ts
|
||||||
* // process.env.TRIBUFU_API_KEY = null
|
* // process.env.TRIBUFU_API_KEY = null
|
||||||
* const api = TribufuApi.fromEnvOrDefault("TRIBUFU_");
|
* const api = TribufuApi.fromEnvOrDefault();
|
||||||
* ```
|
* ```
|
||||||
*/
|
*/
|
||||||
public static fromEnvOrDefault(prefix: string = ""): TribufuApi {
|
public static fromEnvOrDefault(prefix: string = ""): TribufuApi {
|
||||||
@ -95,7 +93,7 @@ export class TribufuApi extends TribufuApiGenerated {
|
|||||||
* @returns string
|
* @returns string
|
||||||
*/
|
*/
|
||||||
protected static getBaseUrl(): string {
|
protected static getBaseUrl(): string {
|
||||||
if (!process) {
|
if (typeof process === "undefined") {
|
||||||
return TRIBUFU_API_URL;
|
return TRIBUFU_API_URL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
23
src/api/singletion.ts
Normal file
23
src/api/singletion.ts
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
// Copyright (c) Tribufu. All Rights Reserved.
|
||||||
|
// SPDX-License-Identifier: MIT
|
||||||
|
|
||||||
|
import { TribufuApi } from "./index";
|
||||||
|
|
||||||
|
/**
|
||||||
|
* **Tribufu API**
|
||||||
|
*
|
||||||
|
* Helper class to get a singleton instance of the Tribufu API.
|
||||||
|
*/
|
||||||
|
export class TribufuApiSingleton {
|
||||||
|
private static INSTANCE: TribufuApi | null = null;
|
||||||
|
|
||||||
|
private constructor() {}
|
||||||
|
|
||||||
|
public static getInstance(): TribufuApi {
|
||||||
|
if (!TribufuApiSingleton.INSTANCE) {
|
||||||
|
TribufuApiSingleton.INSTANCE = TribufuApi.fromEnvOrDefault();
|
||||||
|
}
|
||||||
|
|
||||||
|
return TribufuApiSingleton.INSTANCE;
|
||||||
|
}
|
||||||
|
}
|
@ -18,11 +18,11 @@ export abstract class TribufuApiBase {
|
|||||||
* @returns boolean
|
* @returns boolean
|
||||||
*/
|
*/
|
||||||
public static debugEnabled(): boolean {
|
public static debugEnabled(): boolean {
|
||||||
if (!process) {
|
if (typeof process !== "undefined") {
|
||||||
return false;
|
return process.env.NODE_ENV === "development";
|
||||||
}
|
}
|
||||||
|
|
||||||
return process.env.NODE_ENV === "development";
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -66,7 +66,7 @@ export abstract class TribufuApiBase {
|
|||||||
*/
|
*/
|
||||||
protected static defaultHeaders(): HttpHeaders {
|
protected static defaultHeaders(): HttpHeaders {
|
||||||
const headers = {};
|
const headers = {};
|
||||||
headers["X-Tribufu-Language"] = "javascript";
|
headers["X-Tribufu-Library"] = "javascript";
|
||||||
headers["X-Tribufu-Version"] = TRIBUFU_VERSION;
|
headers["X-Tribufu-Version"] = TRIBUFU_VERSION;
|
||||||
return headers;
|
return headers;
|
||||||
}
|
}
|
1
src/core/include.ts
Normal file
1
src/core/include.ts
Normal file
@ -0,0 +1 @@
|
|||||||
|
import { TribufuApiBase } from "../core/base";
|
21
src/index.ts
21
src/index.ts
@ -8,9 +8,24 @@ import {
|
|||||||
TRIBUFU_WEB_URL,
|
TRIBUFU_WEB_URL,
|
||||||
} from "./constants";
|
} from "./constants";
|
||||||
|
|
||||||
export { TRIBUFU_API_URL, TRIBUFU_CDN_URL, TRIBUFU_VERSION, TRIBUFU_WEB_URL };
|
|
||||||
|
|
||||||
import { TribufuApi } from "./api";
|
import { TribufuApi } from "./api";
|
||||||
import { TribufuApiOptions } from "./options";
|
import { TribufuApiOptions } from "./options";
|
||||||
|
import { TribufuApiSingleton } from "./api/singletion";
|
||||||
|
|
||||||
export { TribufuApi, TribufuApiOptions };
|
export {
|
||||||
|
TRIBUFU_API_URL,
|
||||||
|
TRIBUFU_CDN_URL,
|
||||||
|
TRIBUFU_VERSION,
|
||||||
|
TRIBUFU_WEB_URL,
|
||||||
|
TribufuApi,
|
||||||
|
TribufuApiOptions,
|
||||||
|
TribufuApiSingleton,
|
||||||
|
};
|
||||||
|
|
||||||
|
export * from "./api/api.base";
|
||||||
|
export * from "./api/api.generated";
|
||||||
|
export * from "./api/api.include";
|
||||||
|
export * from "./api/index";
|
||||||
|
export * from "./api/singletion";
|
||||||
|
export * from "./http/headers";
|
||||||
|
export * from "./node";
|
||||||
|
84
src/translate/generated.ts
Normal file
84
src/translate/generated.ts
Normal file
@ -0,0 +1,84 @@
|
|||||||
|
//----------------------
|
||||||
|
// <auto-generated>
|
||||||
|
// Generated using the NSwag toolchain v14.1.0.0 (NJsonSchema v11.0.2.0 (Newtonsoft.Json v13.0.0.0)) (http://NSwag.org)
|
||||||
|
// </auto-generated>
|
||||||
|
//----------------------
|
||||||
|
|
||||||
|
/* tslint:disable */
|
||||||
|
/* eslint-disable */
|
||||||
|
// ReSharper disable InconsistentNaming
|
||||||
|
|
||||||
|
import { TribufuApiBase } from "../core/base";
|
||||||
|
|
||||||
|
export class TribufuTranslateGenerated extends TribufuApiBase {
|
||||||
|
private http: { fetch(url: RequestInfo, init?: RequestInit): Promise<Response> };
|
||||||
|
private baseUrl: string;
|
||||||
|
protected jsonParseReviver: ((key: string, value: any) => any) | undefined = undefined;
|
||||||
|
|
||||||
|
constructor(baseUrl?: string, http?: { fetch(url: RequestInfo, init?: RequestInit): Promise<Response> }) {
|
||||||
|
super();
|
||||||
|
this.http = http ? http : window as any;
|
||||||
|
this.baseUrl = baseUrl ?? "";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Translate a given text.
|
||||||
|
*/
|
||||||
|
translate(): Promise<void> {
|
||||||
|
let url_ = this.baseUrl + "/translate";
|
||||||
|
url_ = url_.replace(/[?&]$/, "");
|
||||||
|
|
||||||
|
let options_: RequestInit = {
|
||||||
|
method: "POST",
|
||||||
|
headers: {
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
return this.transformOptions(options_).then(transformedOptions_ => {
|
||||||
|
return this.http.fetch(url_, transformedOptions_);
|
||||||
|
}).then((_response: Response) => {
|
||||||
|
return this.processTranslate(_response);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
protected processTranslate(response: Response): Promise<void> {
|
||||||
|
const status = response.status;
|
||||||
|
let _headers: any = {}; if (response.headers && response.headers.forEach) { response.headers.forEach((v: any, k: any) => _headers[k] = v); };
|
||||||
|
{
|
||||||
|
return response.text().then((_responseText) => {
|
||||||
|
return;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export class TribufuTranslateError extends Error {
|
||||||
|
override message: string;
|
||||||
|
status: number;
|
||||||
|
response: string;
|
||||||
|
headers: { [key: string]: any; };
|
||||||
|
result: any;
|
||||||
|
|
||||||
|
constructor(message: string, status: number, response: string, headers: { [key: string]: any; }, result: any) {
|
||||||
|
super();
|
||||||
|
|
||||||
|
this.message = message;
|
||||||
|
this.status = status;
|
||||||
|
this.response = response;
|
||||||
|
this.headers = headers;
|
||||||
|
this.result = result;
|
||||||
|
}
|
||||||
|
|
||||||
|
protected isTribufuTranslateError = true;
|
||||||
|
|
||||||
|
static isTribufuTranslateError(obj: any): obj is TribufuTranslateError {
|
||||||
|
return obj.isTribufuTranslateError === true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function throwException(message: string, status: number, response: string, headers: { [key: string]: any; }, result?: any): any {
|
||||||
|
if (result !== null && result !== undefined)
|
||||||
|
throw result;
|
||||||
|
else
|
||||||
|
throw new TribufuTranslateError(message, status, response, headers, null);
|
||||||
|
}
|
74
src/translate/translate.nswag
Normal file
74
src/translate/translate.nswag
Normal file
@ -0,0 +1,74 @@
|
|||||||
|
{
|
||||||
|
"runtime": "Default",
|
||||||
|
"defaultVariables": null,
|
||||||
|
"documentGenerator": {
|
||||||
|
"fromDocument": {
|
||||||
|
"json": "",
|
||||||
|
"url": "http://localhost:5578/openapi.json",
|
||||||
|
"output": null,
|
||||||
|
"newLineBehavior": "Auto"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"codeGenerators": {
|
||||||
|
"openApiToTypeScriptClient": {
|
||||||
|
"className": "TribufuTranslateGenerated",
|
||||||
|
"moduleName": "",
|
||||||
|
"namespace": "",
|
||||||
|
"typeScriptVersion": 4.3,
|
||||||
|
"template": "Fetch",
|
||||||
|
"promiseType": "Promise",
|
||||||
|
"httpClass": "HttpClient",
|
||||||
|
"withCredentials": false,
|
||||||
|
"useSingletonProvider": false,
|
||||||
|
"injectionTokenType": "OpaqueToken",
|
||||||
|
"rxJsVersion": 6,
|
||||||
|
"dateTimeType": "String",
|
||||||
|
"nullValue": "Null",
|
||||||
|
"generateClientClasses": true,
|
||||||
|
"generateClientInterfaces": false,
|
||||||
|
"generateOptionalParameters": true,
|
||||||
|
"exportTypes": true,
|
||||||
|
"wrapDtoExceptions": false,
|
||||||
|
"exceptionClass": "TribufuTranslateError",
|
||||||
|
"clientBaseClass": "TribufuApiBase",
|
||||||
|
"wrapResponses": false,
|
||||||
|
"wrapResponseMethods": [],
|
||||||
|
"generateResponseClasses": true,
|
||||||
|
"responseClass": "SwaggerResponse",
|
||||||
|
"protectedMethods": [],
|
||||||
|
"configurationClass": null,
|
||||||
|
"useTransformOptionsMethod": true,
|
||||||
|
"useTransformResultMethod": false,
|
||||||
|
"generateDtoTypes": true,
|
||||||
|
"operationGenerationMode": "SingleClientFromOperationId",
|
||||||
|
"markOptionalProperties": false,
|
||||||
|
"generateCloneMethod": false,
|
||||||
|
"typeStyle": "Interface",
|
||||||
|
"enumStyle": "Enum",
|
||||||
|
"useLeafType": false,
|
||||||
|
"classTypes": [],
|
||||||
|
"extendedClasses": [],
|
||||||
|
"extensionCode": "../core/include.ts",
|
||||||
|
"generateDefaultValues": true,
|
||||||
|
"excludedTypeNames": [],
|
||||||
|
"excludedParameterNames": [],
|
||||||
|
"handleReferences": false,
|
||||||
|
"generateTypeCheckFunctions": false,
|
||||||
|
"generateConstructorInterface": true,
|
||||||
|
"convertConstructorInterfaceData": false,
|
||||||
|
"importRequiredTypes": true,
|
||||||
|
"useGetBaseUrlMethod": false,
|
||||||
|
"baseUrlTokenName": "API_BASE_URL",
|
||||||
|
"queryNullValue": "",
|
||||||
|
"useAbortSignal": false,
|
||||||
|
"inlineNamedDictionaries": false,
|
||||||
|
"inlineNamedAny": false,
|
||||||
|
"includeHttpContext": false,
|
||||||
|
"templateDirectory": null,
|
||||||
|
"serviceHost": null,
|
||||||
|
"serviceSchemes": null,
|
||||||
|
"output": "generated.ts",
|
||||||
|
"newLineBehavior": "LF"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -1,12 +1,13 @@
|
|||||||
{
|
{
|
||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
"strict": true,
|
"strict": true,
|
||||||
"target": "ESNext",
|
"target": "esnext",
|
||||||
"declaration": true,
|
"declaration": true,
|
||||||
"emitDeclarationOnly": true,
|
"emitDeclarationOnly": true,
|
||||||
"noImplicitAny": false,
|
"noImplicitAny": false,
|
||||||
"moduleResolution": "Node",
|
"moduleResolution": "Node",
|
||||||
"esModuleInterop": true,
|
"esModuleInterop": true,
|
||||||
|
"module": "esnext",
|
||||||
"allowImportingTsExtensions": true,
|
"allowImportingTsExtensions": true,
|
||||||
"resolveJsonModule": true,
|
"resolveJsonModule": true,
|
||||||
"rootDir": "src",
|
"rootDir": "src",
|
||||||
|
Reference in New Issue
Block a user