ionic 3:TypeError:无法读取未定义的属性“列”

时间:2018-03-24 19:38:24

标签: javascript ionic-framework ionic3 ionic-native

当我将所有软件包升级到最新版本后运行离子3模板应用程序时,我收到以下错误。

有人可以帮忙吗?

TypeError: Cannot read property 'columns' of undefined 
    at Object.<anonymous> (http://localhost:8100/build/vendor.js:70740:36)
    at Object.defineProperty.value (http://localhost:8100/build/vendor.js:70822:30)
    at __webpack_require__ (http://localhost:8100/build/vendor.js:55:30)
    at Object.exports.endianness (http://localhost:8100/build/vendor.js:90934:18)
    at __webpack_require__ (http://localhost:8100/build/vendor.js:55:30)
    at Object.<anonymous> (http://localhost:8100/build/vendor.js:82145:18)
    at Object.defineProperty.value (http://localhost:8100/build/vendor.js:82333:30)
    at __webpack_require__ (http://localhost:8100/build/vendor.js:55:30)
    at Object.<anonymous> (http://localhost:8100/build/vendor.js:151111:21)
    at Object.<anonymous> (http://localhost:8100/build/vendor.js:151174:30)

package.json

{  
   "name":"",
   "version":"0.0.1",
   "author":"",
   "homepage":"http://ionicframework.com/",
   "private":true,
   "scripts":{  
      "clean":"ionic-app-scripts clean",
      "build":"ionic-app-scripts build",
      "lint":"ionic-app-scripts lint",
      "ionic:build":"ionic-app-scripts build",
      "ionic:serve":"ionic-app-scripts serve"
   },
   "dependencies":{  
      "@angular/common":"5.0.3",
      "@angular/compiler":"5.0.3",
      "@angular/compiler-cli":"5.0.3",
      "@angular/core":"5.0.3",
      "@angular/forms":"5.0.3",
      "@angular/http":"5.0.3",
      "@angular/platform-browser":"5.0.3",
      "@angular/platform-browser-dynamic":"5.0.3",
      "@ionic-native/admob-free":"^4.6.0",
      "@ionic-native/app-version":"^4.6.0",
      "@ionic-native/browser-tab":"^4.6.0",
      "@ionic-native/call-number":"^4.6.0",
      "@ionic-native/camera":"^4.6.0",
      "@ionic-native/core":"4.4.0",
      "@ionic-native/diagnostic":"^4.6.0",
      "@ionic-native/file":"^4.6.0",
      "@ionic-native/geolocation":"^4.6.0",
      "@ionic-native/google-analytics":"^4.6.0",
      "@ionic-native/google-maps":"^4.6.0",
      "@ionic-native/header-color":"^4.6.0",
      "@ionic-native/in-app-browser":"^4.6.0",
      "@ionic-native/launch-navigator":"^4.6.0",
      "@ionic-native/location-accuracy":"^4.6.0",
      "@ionic-native/social-sharing":"^4.6.0",
      "@ionic-native/splash-screen":"^4.4.0",
      "@ionic-native/status-bar":"^4.4.0",
      "@ionic/pro":"1.0.16",
      "@ionic/storage":"^2.1.3",
      "@ngx-translate/core":"^9.1.1",
      "@ngx-translate/http-loader":"^2.0.1",
      "angularfire2":"^5.0.0-rc.6",
      "firebase":"^4.9.0",
      "ionic-angular":"3.9.2",
      "ionic2-rating":"^1.2.2",
      "ionicons":"3.0.0",
      "latest":"^0.2.0",
      "mongodb":"^3.0.4",
      "morgan":"^1.9.0",
      "ng-lazyload-image":"^3.4.2",
      "ng2-img-fallback":"^0.2.3",
      "parse":"^1.11.1",
      "rxjs":"5.5.2",
      "sw-toolbox":"3.6.0",
      "zone.js":"0.8.18"
   },
   "devDependencies":{  
      "@ionic/app-scripts":"3.1.8",
      "@ionic/cli-plugin-cordova":"^1.6.2",
      "@ionic/cli-plugin-ionic-angular":"^1.4.1",
      "lite-server":"^2.3.0",
      "typescript":"2.4.2",
      "@types/parse":"^2.4.7"
   },
   "cordovaPlugins":[  
      "cordova-plugin-device",
      "cordova-plugin-console",
      "cordova-plugin-whitelist",
      "cordova-plugin-splashscreen",
      "cordova-plugin-statusbar",
      "ionic-plugin-keyboard"
   ],
   "cordovaPlatforms":[  
      "ios",
      {  
         "platform":"ios",
         "version":"",
         "locator":"ios"
      }
   ],
   "description":"An Ionic project",
   "main":"index.js",
   "repository":{  
      "type":"git"
   },
   "keywords":[  
      ""
   ],
   "license":"ISC"
}

1 个答案:

答案 0 :(得分:0)

您可能正在访问代码中某处未定义对象的属性。 例如:object1.columns其中object1为null或未初始化