mirror of
https://gitcode.com/github-mirrors/react-native-update-cli.git
synced 2025-09-17 18:06:10 +08:00
Compare commits
22 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
31ec3edc5a | ||
![]() |
4b772194d1 | ||
![]() |
792418c964 | ||
![]() |
d5f468aa44 | ||
![]() |
04f75cd51b | ||
![]() |
5a05679e2b | ||
![]() |
69f4372b63 | ||
![]() |
dbfdce6412 | ||
![]() |
1372a30ea3 | ||
![]() |
d51ef37a62 | ||
![]() |
90a59cfe7b | ||
![]() |
ffcc6c9c96 | ||
![]() |
b00b3144a3 | ||
![]() |
d3ee908227 | ||
![]() |
5302c8968f | ||
![]() |
5740a3315c | ||
![]() |
4a11a4118f | ||
![]() |
feb1128748 | ||
![]() |
8fd74d76b1 | ||
![]() |
209a989a48 | ||
![]() |
aab9ea6b98 | ||
![]() |
5f45a66aad |
15
.swcrc
Normal file
15
.swcrc
Normal file
@@ -0,0 +1,15 @@
|
||||
{
|
||||
"jsc": {
|
||||
"loose": true,
|
||||
"target": "es2018",
|
||||
"parser": {
|
||||
"syntax": "typescript",
|
||||
"tsx": false,
|
||||
"decorators": false,
|
||||
"dynamicImport": false
|
||||
}
|
||||
},
|
||||
"module": {
|
||||
"type": "commonjs"
|
||||
}
|
||||
}
|
10
cli.json
10
cli.json
@@ -81,9 +81,17 @@
|
||||
"packageId": {
|
||||
"hasValue": true
|
||||
},
|
||||
|
||||
"packageVersion": {
|
||||
"hasValue": true
|
||||
},
|
||||
"minPackageVersion": {
|
||||
"hasValue": true
|
||||
},
|
||||
"maxPackageVersion": {
|
||||
"hasValue": true
|
||||
},
|
||||
"rollout": {
|
||||
"hasValue": true
|
||||
}
|
||||
}
|
||||
},
|
||||
|
39
package.json
39
package.json
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "react-native-update-cli",
|
||||
"version": "1.23.0",
|
||||
"version": "1.31.2",
|
||||
"description": "Command tools for javaScript updater with `pushy` service for react native apps.",
|
||||
"main": "index.js",
|
||||
"bin": {
|
||||
@@ -12,7 +12,8 @@
|
||||
"cli.json"
|
||||
],
|
||||
"scripts": {
|
||||
"prepublish": "babel src --out-dir lib"
|
||||
"build": "swc src -d lib --strip-leading-paths",
|
||||
"prepare": "npm run build && chmod +x lib/index.js"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
@@ -31,35 +32,37 @@
|
||||
},
|
||||
"homepage": "https://github.com/reactnativecn/react-native-pushy/tree/master/react-native-pushy-cli",
|
||||
"dependencies": {
|
||||
"bplist-parser": "^0.2.0",
|
||||
"bplist-parser": "^0.3.2",
|
||||
"bytebuffer": "^5.0.1",
|
||||
"cgbi-to-png": "^1.0.7",
|
||||
"cli-arguments": "^0.2.1",
|
||||
"commander": "^7.2.0",
|
||||
"filesize-parser": "^1.5.0",
|
||||
"commander": "^12.1.0",
|
||||
"compare-versions": "^6.1.1",
|
||||
"filesize-parser": "^1.5.1",
|
||||
"fs-extra": "8",
|
||||
"gradle-to-js": "^2.0.1",
|
||||
"isomorphic-unzip": "^1.1.5",
|
||||
"node-fetch": "^2.6.1",
|
||||
"plist": "^3.0.1",
|
||||
"plist": "^3.1.0",
|
||||
"progress": "^2.0.3",
|
||||
"properties": "^1.2.1",
|
||||
"read": "^1.0.7",
|
||||
"request": "^2.88.2",
|
||||
"read": "^4.0.0",
|
||||
"semver": "^7.6.3",
|
||||
"tcp-ping": "^0.1.1",
|
||||
"tty-table": "4.2",
|
||||
"update-notifier": "^5.1.0",
|
||||
"yauzl": "^2.10.0",
|
||||
"yazl": "2.5.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"babel-cli": "^6.26.0",
|
||||
"babel-plugin-syntax-object-rest-spread": "^6.13.0",
|
||||
"babel-plugin-transform-es2015-modules-commonjs": "^6.26.2",
|
||||
"babel-plugin-transform-es2015-spread": "^6.22.0",
|
||||
"babel-plugin-transform-object-rest-spread": "^6.26.0"
|
||||
"yauzl": "^3.2.0",
|
||||
"yazl": "3.3.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">= 10"
|
||||
}
|
||||
},
|
||||
"devDependencies": {
|
||||
"@swc/cli": "^0.5.0",
|
||||
"@swc/core": "^1.9.2",
|
||||
"@types/node": "^22.9.0",
|
||||
"oxlint": "^0.11.1",
|
||||
"typescript": "^5.6.3"
|
||||
},
|
||||
"packageManager": "yarn@1.22.21+sha1.1959a18351b811cdeedbd484a8f86c3cc3bbaf72"
|
||||
}
|
||||
|
3260
pnpm-lock.yaml
generated
3260
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
19
src/api.js
19
src/api.js
@@ -66,13 +66,20 @@ async function query(url, options) {
|
||||
try {
|
||||
json = JSON.parse(text);
|
||||
} catch (e) {
|
||||
throw new Error(`Server error: ${text}`);
|
||||
if (resp.statusText.includes('Unauthorized')) {
|
||||
throw new Error('登录信息已过期,请使用 pushy login 命令重新登录');
|
||||
} else {
|
||||
throw new Error(`Server error: ${resp.statusText}`);
|
||||
}
|
||||
}
|
||||
|
||||
if (resp.status !== 200) {
|
||||
throw Object.assign(new Error(json.message || json.error), {
|
||||
status: resp.status,
|
||||
});
|
||||
throw Object.assign(
|
||||
new Error(json.message || json.error || resp.statusText),
|
||||
{
|
||||
status: resp.status,
|
||||
},
|
||||
);
|
||||
}
|
||||
return json;
|
||||
}
|
||||
@@ -166,7 +173,9 @@ export async function uploadFile(fn, key) {
|
||||
}
|
||||
if (resp.statusCode > 299) {
|
||||
return reject(
|
||||
Object.assign(new Error(body), { status: resp.statusCode }),
|
||||
Object.assign(new Error(body), {
|
||||
status: resp.statusCode,
|
||||
}),
|
||||
);
|
||||
}
|
||||
resolve({ hash: formData.key });
|
||||
|
@@ -33,7 +33,7 @@ async function runReactNativeBundleCommand(
|
||||
gradleConfig = await checkGradleConfig();
|
||||
if (gradleConfig.crunchPngs !== false) {
|
||||
console.warn(
|
||||
'android的crunchPngs选项似乎尚未禁用(如已禁用则请忽略此提示),这可能导致热更包体积异常增大,具体请参考 https://pushy.reactnative.cn/docs/getting-started.html#%E7%A6%81%E7%94%A8-android-%E7%9A%84-crunch-%E4%BC%98%E5%8C%96 \n',
|
||||
'android 的 crunchPngs 选项似乎尚未禁用(如已禁用则请忽略此提示),这可能导致热更包体积异常增大,具体请参考 https://pushy.reactnative.cn/docs/getting-started.html#%E7%A6%81%E7%94%A8-android-%E7%9A%84-crunch-%E4%BC%98%E5%8C%96 \n',
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -51,9 +51,21 @@ async function runReactNativeBundleCommand(
|
||||
|
||||
fs.emptyDirSync(outputFolder);
|
||||
|
||||
let cliPath = require.resolve('react-native/local-cli/cli.js', {
|
||||
paths: [process.cwd()],
|
||||
});
|
||||
let cliPath;
|
||||
|
||||
try {
|
||||
// rn >= 0.75
|
||||
cliPath = require.resolve('@react-native-community/cli/build/bin.js', {
|
||||
paths: [process.cwd()],
|
||||
});
|
||||
} catch (e) {
|
||||
// rn < 0.75
|
||||
cliPath = require.resolve('react-native/local-cli/cli.js', {
|
||||
paths: [process.cwd()],
|
||||
});
|
||||
}
|
||||
|
||||
let usingExpo = false;
|
||||
try {
|
||||
require.resolve('expo-router', {
|
||||
paths: [process.cwd()],
|
||||
@@ -64,10 +76,9 @@ async function runReactNativeBundleCommand(
|
||||
cliPath = require.resolve('@expo/cli', {
|
||||
paths: [process.cwd()],
|
||||
});
|
||||
usingExpo = true;
|
||||
} catch (e) {}
|
||||
const bundleCommand = cliPath.includes('@expo/cli')
|
||||
? 'export:embed'
|
||||
: 'bundle';
|
||||
const bundleCommand = usingExpo ? 'export:embed' : 'bundle';
|
||||
|
||||
Array.prototype.push.apply(reactNativeBundleArgs, [
|
||||
cliPath,
|
||||
@@ -166,17 +177,19 @@ async function checkGradleConfig() {
|
||||
let crunchPngs;
|
||||
try {
|
||||
const gradleConfig = await g2js.parseFile('android/app/build.gradle');
|
||||
crunchPngs = gradleConfig.android.buildTypes.release.crunchPngs;
|
||||
const projectConfig = gradleConfig['project.ext.react'];
|
||||
for (const packagerConfig of projectConfig) {
|
||||
if (
|
||||
packagerConfig.includes('enableHermes') &&
|
||||
packagerConfig.includes('true')
|
||||
) {
|
||||
enableHermes = true;
|
||||
break;
|
||||
if (projectConfig) {
|
||||
for (const packagerConfig of projectConfig) {
|
||||
if (
|
||||
packagerConfig.includes('enableHermes') &&
|
||||
packagerConfig.includes('true')
|
||||
) {
|
||||
enableHermes = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
crunchPngs = gradleConfig.android.buildTypes.release.crunchPngs;
|
||||
} catch (e) {}
|
||||
return {
|
||||
enableHermes,
|
||||
@@ -204,7 +217,7 @@ async function compileHermesByteCode(
|
||||
}
|
||||
|
||||
const hermesCommand = `${hermesPath}/hermesc`;
|
||||
|
||||
|
||||
const args = [
|
||||
'-emit-binary',
|
||||
'-out',
|
||||
@@ -598,7 +611,6 @@ export const commands = {
|
||||
const { version, major, minor } = getRNVersion();
|
||||
|
||||
console.log('Bundling with react-native: ', version);
|
||||
printVersionCommand();
|
||||
|
||||
await runReactNativeBundleCommand(
|
||||
bundleName,
|
||||
|
@@ -28,8 +28,8 @@ const commands = {
|
||||
};
|
||||
|
||||
function run() {
|
||||
printVersionCommand();
|
||||
if (process.argv.indexOf('-v') >= 0 || process.argv[2] === 'version') {
|
||||
printVersionCommand();
|
||||
process.exit();
|
||||
}
|
||||
|
||||
|
@@ -3,6 +3,7 @@ import os from 'os';
|
||||
import path from 'path';
|
||||
import pkg from '../../package.json';
|
||||
import AppInfoParser from './app-info-parser';
|
||||
import semverSatisfies from 'semver/functions/satisfies';
|
||||
|
||||
import read from 'read';
|
||||
|
||||
@@ -83,7 +84,7 @@ export async function getApkInfo(fn) {
|
||||
}
|
||||
if (buildTime == 0) {
|
||||
throw new Error(
|
||||
'无法获取此包的编译时间戳。请更新react-native-update到最新版本后重新打包上传。',
|
||||
'无法获取此包的编译时间戳。请更新 react-native-update 到最新版本后重新打包上传。',
|
||||
);
|
||||
}
|
||||
return { versionName, buildTime, ...appCredential };
|
||||
@@ -119,7 +120,7 @@ export async function getIpaInfo(fn) {
|
||||
}
|
||||
if (!buildTimeTxtBuffer) {
|
||||
throw new Error(
|
||||
'无法获取此包的编译时间戳。请更新react-native-update到最新版本后重新打包上传。',
|
||||
'无法获取此包的编译时间戳。请更新 react-native-update 到最新版本后重新打包上传。',
|
||||
);
|
||||
}
|
||||
const buildTime = buildTimeTxtBuffer.toString().replace('\n', '');
|
||||
@@ -137,6 +138,7 @@ export function saveToLocal(originPath, destName) {
|
||||
|
||||
export function printVersionCommand() {
|
||||
console.log('react-native-update-cli: ' + pkg.version);
|
||||
let pushyVersion = '';
|
||||
try {
|
||||
const PACKAGE_JSON_PATH = require.resolve(
|
||||
'react-native-update/package.json',
|
||||
@@ -144,10 +146,24 @@ export function printVersionCommand() {
|
||||
paths: [process.cwd()],
|
||||
},
|
||||
);
|
||||
console.log('react-native-update: ' + require(PACKAGE_JSON_PATH).version);
|
||||
pushyVersion = require(PACKAGE_JSON_PATH).version;
|
||||
console.log('react-native-update: ' + pushyVersion);
|
||||
} catch (e) {
|
||||
console.log('react-native-update: 无法获取版本号,请在项目目录中运行命令');
|
||||
}
|
||||
if (pushyVersion) {
|
||||
if (semverSatisfies(pushyVersion, '<8.5.1')) {
|
||||
console.warn(
|
||||
`当前版本已不再支持,请至少升级到 v8 的最新小版本后重新打包(代码无需改动): npm i react-native-update@8 .
|
||||
如有使用安装 apk 的功能,请注意添加所需权限 https://pushy.reactnative.cn/docs/api#async-function-downloadandinstallapkurl`,
|
||||
);
|
||||
} else if (semverSatisfies(pushyVersion, '9.0.0 - 9.2.0')) {
|
||||
console.warn(
|
||||
`当前版本已不再支持,请至少升级到 v9 的最新小版本后重新打包(代码无需改动): npm i react-native-update@9 .
|
||||
如有使用安装 apk 的功能,请注意添加所需权限 https://pushy.reactnative.cn/docs/api#async-function-downloadandinstallapkurl`,
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
export const pricingPageUrl = 'https://pushy.reactnative.cn/pricing.html';
|
||||
|
110
src/versions.js
110
src/versions.js
@@ -3,6 +3,7 @@ import { question, saveToLocal } from './utils';
|
||||
|
||||
import { checkPlatform, getSelectedApp } from './app';
|
||||
import { choosePackage } from './package';
|
||||
import { compare } from 'compare-versions';
|
||||
|
||||
async function showVersion(appId, offset) {
|
||||
const { data, count } = await get(`/app/${appId}/version/list`);
|
||||
@@ -123,13 +124,96 @@ export const commands = {
|
||||
options.platform || (await question('平台(ios/android):')),
|
||||
);
|
||||
const { appId } = await getSelectedApp(platform);
|
||||
const versionId = options.versionId || (await chooseVersion(appId)).id;
|
||||
let versionId = options.versionId || (await chooseVersion(appId)).id;
|
||||
if (versionId === 'null') {
|
||||
versionId = null;
|
||||
}
|
||||
|
||||
let pkgId;
|
||||
let pkgVersion = options.packageVersion;
|
||||
let minPkgVersion = options.minPackageVersion;
|
||||
let maxPkgVersion = options.maxPackageVersion;
|
||||
let rollout = options.rollout;
|
||||
if (rollout === undefined) {
|
||||
rollout = null;
|
||||
} else {
|
||||
try {
|
||||
rollout = parseInt(rollout);
|
||||
} catch (e) {
|
||||
throw new Error('rollout 必须是 1-100 的整数');
|
||||
}
|
||||
if (rollout < 1 || rollout > 100) {
|
||||
throw new Error('rollout 必须是 1-100 的整数');
|
||||
}
|
||||
}
|
||||
if (minPkgVersion) {
|
||||
minPkgVersion = String(minPkgVersion).trim();
|
||||
const { data } = await get(`/app/${appId}/package/list?limit=1000`);
|
||||
const pkgs = data.filter((d) => compare(d.name, minPkgVersion, '>='));
|
||||
if (pkgs.length === 0) {
|
||||
throw new Error(`未查询到 >= ${minPkgVersion} 的原生版本`);
|
||||
}
|
||||
if (rollout) {
|
||||
const rolloutConfig = {};
|
||||
for (const pkg of pkgs) {
|
||||
rolloutConfig[pkg.name] = rollout;
|
||||
}
|
||||
await put(`/app/${appId}/version/${versionId}`, {
|
||||
config: {
|
||||
rollout: rolloutConfig,
|
||||
},
|
||||
});
|
||||
console.log(
|
||||
`已在原生版本 ${pkgs
|
||||
.map((p) => p.name)
|
||||
.join(', ')} 上设置灰度发布 ${rollout}% 热更版本 ${versionId}`,
|
||||
);
|
||||
}
|
||||
for (const pkg of pkgs) {
|
||||
await put(`/app/${appId}/package/${pkg.id}`, {
|
||||
versionId,
|
||||
});
|
||||
console.log(`已将热更版本 ${versionId} 绑定到原生版本 ${pkg.name} (id: ${pkg.id})`);
|
||||
}
|
||||
console.log(`操作完成,共已绑定 ${pkgs.length} 个原生版本`);
|
||||
return;
|
||||
}
|
||||
if (maxPkgVersion) {
|
||||
maxPkgVersion = String(maxPkgVersion).trim();
|
||||
const { data } = await get(`/app/${appId}/package/list?limit=1000`);
|
||||
const pkgs = data.filter((d) => compare(d.name, maxPkgVersion, '<='));
|
||||
if (pkgs.length === 0) {
|
||||
throw new Error(`未查询到 <= ${maxPkgVersion} 的原生版本`);
|
||||
}
|
||||
if (rollout) {
|
||||
const rolloutConfig = {};
|
||||
for (const pkg of pkgs) {
|
||||
rolloutConfig[pkg.name] = rollout;
|
||||
}
|
||||
await put(`/app/${appId}/version/${versionId}`, {
|
||||
config: {
|
||||
rollout: rolloutConfig,
|
||||
},
|
||||
});
|
||||
console.log(
|
||||
`已在原生版本 ${pkgs
|
||||
.map((p) => p.name)
|
||||
.join(', ')} 上设置灰度发布 ${rollout}% 热更版本 ${versionId}`,
|
||||
);
|
||||
}
|
||||
for (const pkg of pkgs) {
|
||||
await put(`/app/${appId}/package/${pkg.id}`, {
|
||||
versionId,
|
||||
});
|
||||
console.log(`已将热更版本 ${versionId} 绑定到原生版本 ${pkg.name} (id: ${pkg.id})`);
|
||||
}
|
||||
console.log(`操作完成,共已绑定 ${pkgs.length} 个原生版本`);
|
||||
return;
|
||||
}
|
||||
|
||||
const { data } = await get(`/app/${appId}/package/list?limit=1000`);
|
||||
if (pkgVersion) {
|
||||
pkgVersion = pkgVersion.trim();
|
||||
const { data } = await get(`/app/${appId}/package/list?limit=1000`);
|
||||
const pkg = data.find((d) => d.name === pkgVersion);
|
||||
if (pkg) {
|
||||
pkgId = pkg.id;
|
||||
@@ -144,10 +228,30 @@ export const commands = {
|
||||
if (!pkgId) {
|
||||
throw new Error('请提供 packageId 或 packageVersion 参数');
|
||||
}
|
||||
|
||||
if (!pkgVersion) {
|
||||
const pkg = data.find((d) => d.id === pkgId);
|
||||
if (pkg) {
|
||||
pkgVersion = pkg.name;
|
||||
}
|
||||
}
|
||||
|
||||
if (rollout) {
|
||||
await put(`/app/${appId}/version/${versionId}`, {
|
||||
config: {
|
||||
rollout: {
|
||||
[pkgVersion]: rollout,
|
||||
},
|
||||
},
|
||||
});
|
||||
console.log(
|
||||
`已将在原生版本 ${pkgVersion} (id: ${pkgId}) 上设置灰度发布 ${rollout}% 热更版本 ${versionId} `,
|
||||
);
|
||||
}
|
||||
await put(`/app/${appId}/package/${pkgId}`, {
|
||||
versionId,
|
||||
});
|
||||
console.log('操作成功');
|
||||
console.log(`已将热更版本 ${versionId} 绑定到原生版本 ${pkgVersion} (id: ${pkgId})`);
|
||||
},
|
||||
updateVersionInfo: async function ({ args, options }) {
|
||||
const platform = checkPlatform(
|
||||
|
75
tsconfig.json
Normal file
75
tsconfig.json
Normal file
@@ -0,0 +1,75 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
/* Basic Options */
|
||||
"target": "ESNext" /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017','ES2018' or 'ESNEXT'. */,
|
||||
"module": "commonjs" /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', or 'ESNext'. */,
|
||||
"lib": [
|
||||
"ESNext"
|
||||
] /* Specify library files to be included in the compilation. */,
|
||||
"allowJs": true /* Allow javascript files to be compiled. */,
|
||||
// "checkJs": true /* Report errors in .js files. */,
|
||||
"jsx": "react" /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */,
|
||||
// "declaration": true, /* Generates corresponding '.d.ts' file. */
|
||||
// "declarationMap": true, /* Generates a sourcemap for each corresponding '.d.ts' file. */
|
||||
// "sourceMap": true, /* Generates corresponding '.map' file. */
|
||||
// "outFile": "./", /* Concatenate and emit output to single file. */
|
||||
// "outDir": "lib" /* Redirect output structure to the directory. */,
|
||||
// "rootDir": "src" /* Specify the root directory of input files. Use to control the output directory structure with --outDir. */,
|
||||
// "composite": true, /* Enable project compilation */
|
||||
// "removeComments": true, /* Do not emit comments to output. */
|
||||
"noEmit": true /* Do not emit outputs. */,
|
||||
// "importHelpers": true, /* Import emit helpers from 'tslib'. */
|
||||
// "downlevelIteration": true, /* Provide full support for iterables in 'for-of', spread, and destructuring when targeting 'ES5' or 'ES3'. */
|
||||
"isolatedModules": true /* Transpile each file as a separate module (similar to 'ts.transpileModule'). */,
|
||||
|
||||
/* Strict Type-Checking Options */
|
||||
"strict": true /* Enable all strict type-checking options. */,
|
||||
"noImplicitAny": true /* Raise error on expressions and declarations with an implied 'any' type. */,
|
||||
"strictNullChecks": true /* Enable strict null checks. */,
|
||||
// "strictFunctionTypes": true, /* Enable strict checking of function types. */
|
||||
// "strictPropertyInitialization": true, /* Enable strict checking of property initialization in classes. */
|
||||
"noImplicitThis": true /* Raise error on 'this' expressions with an implied 'any' type. */,
|
||||
// "alwaysStrict": true, /* Parse in strict mode and emit "use strict" for each source file. */
|
||||
|
||||
/* Additional Checks */
|
||||
// "noUnusedLocals": true /* Report errors on unused locals. */,
|
||||
// "noUnusedParameters": true /* Report errors on unused parameters. */,
|
||||
"noImplicitReturns": false /* Report error when not all code paths in function return a value. */,
|
||||
// "noFallthroughCasesInSwitch": true, /* Report errors for fallthrough cases in switch statement. */
|
||||
|
||||
/* Module Resolution Options */
|
||||
// "moduleResolution": "node", /* Specify module resolution strategy: 'node' (Node.js) or 'classic' (TypeScript pre-1.6). */
|
||||
"baseUrl": "./src" /* Base directory to resolve non-absolute module names. */,
|
||||
// "paths": {}, /* A series of entries which re-map imports to lookup locations relative to the 'baseUrl'. */
|
||||
// "rootDirs": [
|
||||
// "src",
|
||||
// "db",
|
||||
// "config",
|
||||
// "models"
|
||||
// ] /* List of root folders whose combined content represents the structure of the project at runtime. */,
|
||||
"typeRoots": [
|
||||
"src/types"
|
||||
] /* List of folders to include type definitions from. */,
|
||||
// "types": [], /* Type declaration files to be included in compilation. */
|
||||
"allowSyntheticDefaultImports": true /* Allow default imports from modules with no default export. This does not affect code emit, just typechecking. */,
|
||||
// "paths": {
|
||||
// "@/*": ["src/*"]
|
||||
// },
|
||||
"resolveJsonModule": true,
|
||||
"esModuleInterop": true /* Enables emit interoperability between CommonJS and ES Modules via creation of namespace objects for all imports. Implies 'allowSyntheticDefaultImports'. */,
|
||||
// "preserveSymlinks": true, /* Do not resolve the real path of symlinks. */
|
||||
|
||||
/* Source Map Options */
|
||||
// "sourceRoot": "", /* Specify the location where debugger should locate TypeScript files instead of source locations. */
|
||||
// "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */
|
||||
// "inlineSourceMap": true, /* Emit a single file with source maps instead of having a separate file. */
|
||||
// "inlineSources": true, /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */
|
||||
|
||||
/* Experimental Options */
|
||||
// "experimentalDecorators": true, /* Enables experimental support for ES7 decorators. */
|
||||
// "emitDecoratorMetadata": true, /* Enables experimental support for emitting type metadata for decorators. */
|
||||
"skipLibCheck": true,
|
||||
"incremental": true
|
||||
},
|
||||
"exclude": ["node_modules", "lib"]
|
||||
}
|
Reference in New Issue
Block a user