首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Ionic 3应用程序在iOS设备上运行缓慢: ionic cordova build ios --prod --aot

Ionic 3应用程序在iOS设备上运行缓慢: ionic cordova build ios --prod --aot
EN

Stack Overflow用户
提问于 2018-01-14 03:20:32
回答 1查看 756关注 0票数 0

目前,我正在做一个项目,是Ionic 3。我需要在iOS设备上部署应用程序。但这款应用在iOS设备上运行速度非常慢。我试着运行这个命令ionic cordova build ios --prod --aot。但它导致了一堆离子组件错误。

使用prodaot应用程序构建时的错误屏幕截图:

package.json

代码语言:javascript
复制
{
    "name": "Demo",
    "private": true,
    "scripts": {
        "build": "ionic-app-scripts build",
        "watch": "ionic-app-scripts watch",
        "serve:before": "watch",
        "emulate:before": "build",
        "deploy:before": "build",
        "build:before": "build",
        "run:before": "build",
        "test": "ng test --code-coverage",
        "e2e": "protractor",
        "postinstall": "webdriver-manager update"
    },
    "dependencies": {
        "@angular/animations": "^5.1.3",
        "@angular/common": "^5.1.3",
        "@angular/compiler": "^5.1.3",
        "@angular/compiler-cli": "^5.1.3",
        "@angular/core": "^5.1.3",
        "@angular/forms": "^5.1.3",
        "@angular/http": "^5.1.3",
        "@angular/platform-browser": "^5.1.3",
        "@angular/platform-browser-dynamic": "^5.1.3",
        "@angular/platform-server": "^5.1.3",
        "@ionic-native/android-permissions": "*",
        "@ionic-native/badge": "*",
        "@ionic-native/camera": "*",
        "@ionic-native/core": "*",
        "@ionic-native/file": "*",
        "@ionic-native/file-chooser": "*",
        "@ionic-native/file-path": "*",
        "@ionic-native/file-transfer": "*",
        "@ionic-native/in-app-browser": "*",
        "@ionic-native/keyboard": "*",
        "@ionic-native/media": "*",
        "@ionic-native/network": "*",
        "@ionic-native/push": "^4.5.2",
        "@ionic-native/splash-screen": "*",
        "@ionic-native/status-bar": "*",
        "@ionic-native/streaming-media": "*",
        "@ionic-native/transfer": "*",
        "@ionic-native/video-player": "*",
        "@ionic/cloud-angular": "^0.12.0",
        "@ionic/storage": "*",
        "@types/googlemaps": "*",
        "@types/lodash": "^4.14.92",
        "accounts-password-client-side": "*",
        "angular-svg-round-progressbar": "*",
        "angular2-moment": "*",
        "angular2-swing": "^0.14.0",
        "aws-sdk": "*",
        "body-parser": "*",
        "braintree": "^2.4.0",
        "braintree-web": "^3.27.0",
        "cordova-android": "^7.0.0",
        "cordova-ios": "*",
        "cordova-plugin-android-permissions": "*",
        "cordova-plugin-badge": "*",
        "cordova-plugin-camera": "^4.0.1",
        "cordova-plugin-compat": "*",
        "cordova-plugin-console": "*",
        "cordova-plugin-crosswalk-webview": "*",
        "cordova-plugin-device": "^2.0.1",
        "cordova-plugin-file": "^6.0.1",
        "cordova-plugin-file-transfer": "*",
        "cordova-plugin-filechooser": "*",
        "cordova-plugin-filepath": "*",
        "cordova-plugin-filepicker": "*",
        "cordova-plugin-geolocation": "^4.0.1",
        "cordova-plugin-inappbrowser": "^2.0.1",
        "cordova-plugin-media": "^5.0.1",
        "cordova-plugin-network-information": "^2.0.1",
        "cordova-plugin-splashscreen": "^5.0.1",
        "cordova-plugin-statusbar": "*",
        "cordova-plugin-whitelist": "*",
        "cors": "*",
        "express": "*",
        "intl": "*",
        "ionic-angular": "*",
        "ionic-image-loader": "git+https://github.com/patricktyndall/ionic-image-loader.git",
        "ionic-plugin-keyboard": "*",
        "ionic2-autosize": "*",
        "ionic2-rating": "*",
        "ionicons": "*",
        "jquery": "*",
        "jssha": "^2.3.1",
        "lodash": "*",
        "meteor-rxjs": "*",
        "meteor-tracker": "*",
        "moment": "*",
        "ng2-cordova-oauth": "0.0.8",
        "ng2-currency-mask": "*",
        "ng2-translate": "*",
        "ng2-validation-manager": "^5.0.0",
        "phonegap-plugin-push": "^2.1.2",
        "rxjs": "*",
        "stripe": "^5.4.0",
        "sw-toolbox": "*",
        "underscore": "*",
        "zone.js": "*"
    },
    "devDependencies": {
        "@angular/cli": "^1.6.3",
        "@ionic/app-scripts": "^3.1.7",
        "@types/core-js": "^0.9.44",
        "@types/google-maps": "^3.2.0",
        "@types/jssha": "0.0.29",
        "@types/meteor": "^1.4.13",
        "@types/node": "^9.3.0",
        "codelyzer": "^4.0.2",
        "ionic": "^3.19.0",
        "ts-node": "^4.1.0",
        "typescript": "^2.6.2"
    },
    "cordovaPlugins": [],
    "cordovaPlatforms": [
        "ios",
        {
            "platform": "ios",
            "version": "",
            "locator": "ios"
        }
    ],
    "cordova": {
        "plugins": {
            "cordova-plugin-compat": {},
            "cordova-plugin-console": {},
            "cordova-plugin-device": {},
            "cordova-plugin-file": {},
            "cordova-plugin-filechooser": {},
            "cordova-plugin-filepicker": {},
            "cordova-plugin-filepath": {},
            "cordova-plugin-geolocation": {},
            "cordova-plugin-media": {},
            "cordova-plugin-splashscreen": {},
            "cordova-plugin-whitelist": {},
            "ionic-plugin-keyboard": {},
            "phonegap-plugin-push": {
                "SENDER_ID": "318310044174"
            },
            "cordova-plugin-network-information": {},
            "cordova-plugin-camera": {},
            "cordova-plugin-statusbar": {},
            "cordova-plugin-file-transfer": {},
            "cordova-plugin-inappbrowser": {},
            "cordova-plugin-badge": {},
            "cordova-plugin-android-permissions": {},
            "cordova-plugin-crosswalk-webview": {
                "XWALK_VERSION": "23+",
                "XWALK_LITEVERSION": "xwalk_core_library_canary:17+",
                "XWALK_COMMANDLINE": "--disable-pull-to-refresh-effect",
                "XWALK_MODE": "embedded",
                "XWALK_MULTIPLEAPK": "true"
            }
        },
        "platforms": [
            "android"
        ]
    }
}

离子信息文件:

我们已经尝试了所有现有的解决方案,但没有一个有效。请帮助我们解决这个问题。谢谢

EN

回答 1

Stack Overflow用户

发布于 2018-01-27 00:26:13

你还有这个问题吗?

如果是,那么尝试卸载所有插件,清理您的项目,然后重新安装所有以前删除的插件。确保每个插件都安装了正确的依赖项(并且在正确的版本中)。

就我个人而言,我不知道是否有快速卸载/重新安装所有东西的方法,但这实际上可能会加快应用程序的运行速度,并可能解决不一致问题,因此绝对值得尝试(如果你还没有尝试)。

希望能有所帮助!

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/48243450

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档