提交 48aa6baa 编写于 作者: fxy060608's avatar fxy060608

build(deps): bump typescript from 4.3.5 to 4.4.3

上级 6a9b5c21
因为 它太大了无法显示 source diff 。你可以改为 查看blob
......@@ -78,7 +78,7 @@ function createSocketTask(args: UniApp.ConnectSocketOption) {
: args.protocols,
header: args.header,
})
} catch (error) {
} catch (error: any) {
errMsg = error
}
return { socket, socketId, errMsg }
......
......@@ -215,7 +215,7 @@ export const getCheckBoxState = defineAsyncApi<API_TYPE_GET_CHECK_BOX_STATE>(
const state = service.getCheckBoxState()
successCallback({ state })
})
} catch (error) {
} catch (error: any) {
errorCallback(error)
}
}
......
......@@ -94,7 +94,7 @@ export const setStorage = <API_TYPE_SET_STORAGE>defineAsyncApi(
storage.removeItemAsync(key + STORAGE_DATA_TYPE)
}
storage.setItemAsync(key, value, resolve, warpPlusErrorCallback(reject))
} catch (error) {
} catch (error: any) {
reject(error.message)
}
},
......
......@@ -7,7 +7,7 @@ const fs_extra_1 = __importDefault(require("fs-extra"));
const path_1 = __importDefault(require("path"));
const uni_cli_shared_1 = require("@dcloudio/uni-cli-shared");
exports.default = [
uni_cli_shared_1.defineUniMainJsPlugin((opts) => {
(0, uni_cli_shared_1.defineUniMainJsPlugin)((opts) => {
return {
name: 'vite:uni-automator',
enforce: 'pre',
......
......@@ -611,7 +611,7 @@ async function resolvePostcssConfig(
typeof inlineOptions === 'string' ? inlineOptions : config.root
// @ts-ignore
result = await postcssrc({}, searchPath)
} catch (e) {
} catch (e: any) {
if (!/No PostCSS Config found/.test(e.message)) {
throw e
}
......@@ -851,7 +851,7 @@ const scss: SassStylePreprocessor = async (
errors: [],
deps,
}
} catch (e) {
} catch (e: any) {
// normalize SASS error
e.id = e.file
e.frame = e.formatted
......@@ -1044,7 +1044,7 @@ const styl: StylePreprocessor = async (source, root, options) => {
const deps = [...ref.deps(), ...importsDeps]
return { code: result, errors: [], deps }
} catch (e) {
} catch (e: any) {
return { code: '', errors: [e], deps: [] }
}
}
......
......@@ -50,7 +50,7 @@ const UniCloudPlugin = {
}
},
};
const initUniCloudWarningOnce = uni_shared_1.once(() => {
const initUniCloudWarningOnce = (0, uni_shared_1.once)(() => {
uniCloudSpaces.length &&
console.warn('当前项目使用了uniCloud,为避免云函数调用跨域问题,建议在HBuilderX内置浏览器里调试,如使用外部浏览器需处理跨域,详见:https://uniapp.dcloud.io/uniCloud/quickstart?id=useinh5');
});
......@@ -87,9 +87,9 @@ function initUniCloudEnv() {
}
exports.default = [
UniCloudPlugin,
uni_cli_shared_1.uniViteInjectPlugin({
(0, uni_cli_shared_1.uniViteInjectPlugin)({
exclude: [...uni_cli_shared_1.COMMON_EXCLUDE],
uniCloud: ['@dcloudio/uni-cloud', 'default'],
}),
validateFunction_1.uniValidateFunctionPlugin(),
(0, validateFunction_1.uniValidateFunctionPlugin)(),
];
......@@ -200,7 +200,7 @@ function addFont(family, source, desc) {
if (fonts) {
const fontFace = new FontFace(family, source, desc);
return fontFace.load().then(() => {
fonts.add(fontFace);
fonts.add && fonts.add(fontFace);
});
}
return new Promise((resolve) => {
......
/// <reference types="css-font-loading-module" />
import { ComponentInternalInstance } from 'vue';
import { ComponentOptionsBase } from 'vue';
import { ComponentPublicInstance } from 'vue';
......
......@@ -196,7 +196,7 @@ function addFont(family, source, desc) {
if (fonts) {
const fontFace = new FontFace(family, source, desc);
return fontFace.load().then(() => {
fonts.add(fontFace);
fonts.add && fonts.add(fontFace);
});
}
return new Promise((resolve) => {
......
......@@ -32,7 +32,7 @@ export function addFont(
if (fonts) {
const fontFace = new FontFace(family, source, desc)
return fontFace.load().then(() => {
fonts.add(fontFace)
;(fonts as any).add && (fonts as any).add(fontFace)
})
}
return new Promise((resolve) => {
......
......@@ -44,7 +44,7 @@ export function initHooks(
try {
invokeHook(publicThis, ON_LOAD, instance.attrs.__pageQuery)
invokeHook(publicThis, ON_SHOW)
} catch (e) {
} catch (e: any) {
console.error(e.message + '\n' + e.stack)
}
}
......
......@@ -30,7 +30,7 @@ function getCurrentUserInfo(): UniIdUserInfo {
let userInfo
try {
userInfo = JSON.parse(b64DecodeUnicode(tokenArr[1]))
} catch (error) {
} catch (error: any) {
throw new Error('获取当前用户信息出错,详细错误信息为:' + error.message)
}
userInfo.tokenExpired = userInfo.exp * 1000
......
......@@ -45,7 +45,7 @@ export async function runDev(options: CliOptions & ServerOptions) {
}
})
}
} catch (e) {
} catch (e: any) {
if (options.platform === 'h5') {
console.error(`error when starting dev server:\n${e.stack || e}`)
} else {
......@@ -62,7 +62,7 @@ export async function runBuild(options: CliOptions & BuildOptions) {
? buildSSR(options)
: build(options))
console.log(M['build.done'])
} catch (e) {
} catch (e: any) {
console.error(`error during build:\n${e.stack || e}`)
process.exit(1)
}
......
......@@ -79,7 +79,7 @@ export async function createSSRServer(options: CliOptions & ServerOptions) {
.replace(`<!--app-html-->`, appHtml)
.replace(`<!--app-context-->`, appContext)
res.status(200).set({ 'Content-Type': 'text/html' }).end(html)
} catch (e) {
} catch (e: any) {
vite && vite.ssrFixStacktrace(e)
res.status(500).end(e.stack)
}
......
......@@ -22,8 +22,7 @@
"node",
"@dcloudio/types",
"vue",
"miniprogram-api-typings",
"css-font-loading-module"
"miniprogram-api-typings"
],
"rootDir": ".",
"paths": {
......
......@@ -2363,11 +2363,6 @@
dependencies:
"@types/node" "*"
"@types/css-font-loading-module@^0.0.6":
version "0.0.6"
resolved "https://registry.yarnpkg.com/@types/css-font-loading-module/-/css-font-loading-module-0.0.6.tgz#1ac3417ed31eeb953134d29b56bca921644b87c0"
integrity sha512-MBvSMSxXFtIukyXRU3HhzL369rIWaqMVQD5kmDCYIFFD6Fe3lJ4c9UnLD02MLdTp7Z6ti7rO3SQtuDo7C80mmw==
"@types/debug@^4.1.5":
version "4.1.7"
resolved "https://registry.yarnpkg.com/@types/debug/-/debug-4.1.7.tgz#7cc0ea761509124709b8b2d1090d8f6c17aadb82"
......@@ -9959,12 +9954,7 @@ typedarray@^0.0.6:
resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777"
integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c=
typescript@~4.3.5:
version "4.3.5"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.3.5.tgz#4d1c37cc16e893973c45a06886b7113234f119f4"
integrity sha512-DqQgihaQ9cUrskJo9kIyW/+g0Vxsk8cDtZ52a3NGh0YNTfpUSArXSohyUGnvbPazEPLu398C0UxmKSOrPumUzA==
typescript@~4.4.2:
typescript@^4.4.3, typescript@~4.4.2:
version "4.4.3"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.4.3.tgz#bdc5407caa2b109efd4f82fe130656f977a29324"
integrity sha512-4xfscpisVgqqDfPaJo5vkd+Qd/ItkoagnHpufr+i2QCHBsNYp+G7UAoyFl8aPtx879u38wPV65rZ8qbGZijalA==
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册