[Solved] TypeError: Property 'jscomp_symbol_iterator0' of object [object Array] is not a function


#1

Hi,

My code is working great in Browser. But in Android, I am getting this error.

EXCEPTION: Error in build/pages/home/home.html:17:37 browser_adapter.js:77
ORIGINAL EXCEPTION: TypeError: Property 'jscomp_symbol_iterator0' of object [object Array] is not a function browser_adapter.js:77
ORIGINAL STACKTRACE: browser_adapter.js:77
TypeError: Property 'jscomp_symbol_iterator0' of object [object Array] is not a function
at Object.areIterablesEqual (file:///android_asset/www/build/js/app.bundle.js:1718:50)
at Object.devModeEqual (file:///android_asset/www/build/js/app.bundle.js:24603:29)
at checkBinding (file:///android_asset/www/build/js/app.bundle.js:30678:33)
at DebugAppView._View_HomePage0.detectChangesInternal (HomePage.template.js:197:7)
at DebugAppView.AppView.detectChanges (file:///android_asset/www/build/js/app.bundle.js:30083:14)
at DebugAppView.detectChanges (file:///android_asset/www/build/js/app.bundle.js:30188:44)
at DebugAppView.AppView.detectViewChildrenChanges (file:///android_asset/www/build/js/app.bundle.js:30109:19)
at DebugAppView.AppView.detectChangesInternal (file:///android_asset/www/build/js/app.bundle.js:30094:14)
at DebugAppView.AppView.detectChanges (file:///android_asset/www/build/js/app.bundle.js:30083:14)
at DebugAppView.detectChanges (file:///android_asset/www/build/js/app.bundle.js:30188:44) 

Here is my home/home.html. It looks all fine:

<ion-header>
<ion-navbar primary>

    <ion-title>SO Login</ion-title>

    <ion-buttons end>
        <button id="create" (click)='newOrder($event)'>
            <ion-icon id="cr" light name="add-circle"></ion-icon>
        </button>
    </ion-buttons>

</ion-navbar>
</ion-header>

<ion-content padding class="home">
<ion-list> // Line 17
    <button ion-item detail-none *ngFor="let order of orderList" (click)='orderSelected(order)'>
        {{order.customerName}}
    </button>
</ion-list>
</ion-content>

Line 17 as specifed in the Error, refers to the line with the tag

Not sure what’s wrong with it. Please help.

My Ionic Info:

Your system information:

Cordova CLI: 6.1.0 (cordova-lib@undefined)
Gulp version: CLI version 3.9.1
Gulp local: Local version 3.9.1
Ionic Framework Version: 2.0.0-beta.10
Ionic CLI Version: 2.0.0-beta.32
Ionic App Lib Version: 2.0.0-beta.18
ios-deploy version: Not installed
ios-sim version: 5.0.6
OS: Mac OS X El Capitan
Node Version: v4.2.6
Xcode version: Xcode 7.2 Build version 7C68


Dependency warning - for the CLI to run correctly,
it is highly recommended to install/upgrade the following:

Please install your Cordova CLI to version >=4.2.0 npm install -g cordova
Install ios-deploy to deploy iOS applications to devices. npm install -g ios-deploy (may require sudo)



#2

Sounds like orderList is not being populated with an iterable.


#3

orderList is a regular array of objects. Weird thing is, the same code works fine in the browser.

This error happens only in Android.


#4

Fixed It :slight_smile:

Got solution from SO @ http://stackoverflow.com/questions/38132088/ionic-2-android-typeerror-property-jscomp-symbol-iterator0-of-object-objec

Firebase.js should be included after all other scripts like
es6-shim.min.js
Reflect.js
zone.js