当我使用以下命令构建应用程序时:
quasar build -m capacitor -T ios我现在得到以下错误:
/Users/myusername/Documents/my-app-name/node_modules/@types/webpack-dev-server/index.d.ts(30,53):中的/Users/myusername/Documents/my-app-name/node_modules/@types/webpack-dev-server/index.d.ts错误
配置:命名空间'"/Users/myusername/Documents/my-app-name/node_modules/http-proxy-middleware/dist/index"‘没有导出的成员“TS2694”。
/Users/myusername/Documents/my-app-name/node_modules/@types/webpack-dev-server/index.d.ts(36,29):中的/Users/myusername/Documents/my-app-name/node_modules/@types/webpack-dev-server/index.d.ts错误
配置:命名空间'"/Users/myusername/Documents/my-app-name/node_modules/http-proxy-middleware/dist/index"‘没有导出的成员“TS2694”。
我可以在网上找到的任何关于这类错误的引用都描述了似乎与我自己的情况无关的情况。
我最后一次构建我的应用程序(大约3-4周前),它构建得很好。
我已经尝试删除以下所有内容并重新构建:
node_modules
src_capacitor
package-lock.json
yarn.lock运行quasar info命令会产生以下结果:
Operating System - Darwin(19.6.0) - darwin/x64
NodeJs - 12.18.3
Global packages
NPM - 6.14.9
yarn - 1.22.5
@quasar/cli - 1.1.2
@quasar/icongenie - 2.3.3
cordova - 10.0.0
Important local packages
quasar - 1.14.5 -- Build high-performance VueJS user interfaces (SPA, PWA, SSR, Mobile and Desktop) in record time
@quasar/app - 2.1.8 -- Quasar Framework local CLI
@quasar/extras - 1.9.10 -- Quasar Framework fonts, icons and animations
eslint-plugin-quasar - Not installed
vue - 2.6.12 -- Reactive, component-oriented view layer for modern web interfaces.
vue-router - 3.2.0 -- Official router for Vue.js 2
vuex - 3.6.0 -- state management for Vue.js
electron - 10.1.6 -- Build cross platform desktop apps with JavaScript, HTML, and CSS
electron-packager - 14.2.1 -- Customize and package your Electron app with OS-specific bundles (.app, .exe, etc.) via JS or CLI
electron-builder - 22.9.1 -- A complete solution to package and build a ready for distribution Electron app for MacOS, Windows and Linux with “auto update” support out of the box
@babel/core - 7.12.9 -- Babel compiler core.
webpack - 4.44.2 -- Packs CommonJs/AMD modules for the browser. Allows to split your codebase into multiple bundles, which can be loaded on demand. Support loaders to preprocess files, i.e. json, jsx, es7, css, less, ... and your custom stuff.
webpack-dev-server - 3.11.0 -- Serves a webpack app. Updates the browser on changes.
workbox-webpack-plugin - 5.1.4 -- A plugin for your Webpack build process, helping you generate a manifest of local files that workbox-sw should precache.
register-service-worker - 1.7.1 -- Script for registering service worker, with hooks
typescript - 3.9.5 -- TypeScript is a language for application scale JavaScript development
@capacitor/core - 2.4.3 -- Capacitor: cross-platform mobile apps with the web
@capacitor/cli - 2.4.3 -- Capacitor: Cross-platform apps with JavaScript and the web
@capacitor/android - 2.4.3 -- Capacitor: cross-platform mobile apps with the web
@capacitor/ios - 2.4.3 -- Capacitor: cross-platform mobile apps with the web
Quasar App Extensions
@quasar/quasar-app-extension-qmediaplayer - 1.1.3 -- A Quasar App Extension for @quasar/quasar-ui-qmediaplayer
Networking
Host - MacBook-Pro-3.local
en1 - 10.0.0.143有人能帮上忙吗?
**补充说明:如果我尝试使用Cordova构建,则会收到相同的错误。
发布于 2021-03-14 05:18:43
在tsconfig.json文件中添加"skipLibCheck":true解决了我的tsconfig.json现在看起来像这样的问题:
{
"extends": "@quasar/app/tsconfig-preset",
"compilerOptions": {
"skipLibCheck": true,
"baseUrl": "."
}
}https://stackoverflow.com/questions/65037575
复制相似问题