Failed to load module.js.map on ios

#1

I am new to ionic (2) . I created a very simple application, few pages and a web services.
It works fine on android 6, but some pages wont open on ios (tested on 8 & 9).
and here is the error in console:

[Error] Failed to load resource: The requested URL was not found on this server. (login-main.module.js.map, line 0)

I see this for every page in my app plus this one:

[Error] Failed to load resource: The requested URL was not found on this server. (Observable.js.map, line 0)

What caused this? How can I fix it?
My guess is that this is somehow related to lazy loading? Other wise I really have no idea.

Edit 1: updated my error messages to be more helpful.

#2

What is your ionic info output?
What did you program?
Do you have the same problem with a blank app created by ionic start blank blank?

#3

Sorry for the delay.

Ionic info:

global packages:

    @ionic/cli-utils : 1.5.0
    Cordova CLI      : 7.0.1 
    Ionic CLI        : 3.5.0

local packages:

    @ionic/app-scripts              : 1.3.12
    @ionic/cli-plugin-cordova       : 1.4.1
    @ionic/cli-plugin-ionic-angular : 1.3.2
    Cordova Platforms               : android 6.2.3 ios 4.4.0
    Ionic Framework                 : ionic-angular 3.5.0

System:

    Node       : v6.11.0
    OS         : OS X Yosemite
    Xcode      : Xcode 7.1 Build version 7B91b 
    ios-deploy : 1.9.1 
    ios-sim    : 5.0.13 
    npm        : 3.10.10 

I practically programmed nothing. Just about 3 pages with lazy loading and static html and 1 page with dynamic content from a web service.

##On Blank App:
I got slightly different error.

[Error] Failed to load resource: The requested URL was not found on this server. (home.js.map, line 0)

And another one:
[Error] Failed to load resource: The requested URL was not found on this server. (core.es5.js.map, line 0)

Thanks for your help.

#4

Upgrade both to most current version (2.0.2 - read the release notes for bereaking changes! - and 3.5.3) first befor ewe try to debug this further.

#5

I successfully updated @ionic/app-scripts : 1.3.12 to 2.0.2 but couldn’t update Ionic Framework : ionic-angular further than 3.5.0. I thought that was the latest. Is there is a way to get 3.5.3 (except npm install ionic)?!

The error sill there btw.

#6

npm install -g ionic is the globale Ionic CLI installation.
You update ionic-angular by running npm install ionic-angular@latest --save-exect on the command line.

#7

Thanks, now both are updated. The problem is still there. What next?

#8

Post your ionic info again.
Create a new project with ionic start blank blank and try with this one. Same problem?

#9

ionic info:

global packages:

    @ionic/cli-utils : 1.5.0
    Cordova CLI      : 7.0.1 
    Ionic CLI        : 3.5.0

local packages:

    @ionic/app-scripts              : 2.0.2
    @ionic/cli-plugin-cordova       : 1.4.1
    @ionic/cli-plugin-ionic-angular : 1.3.2
    Cordova Platforms               : ios 4.4.0
    Ionic Framework                 : ionic-angular 3.5.3

System:

    Node       : v6.11.0
    OS         : OS X Yosemite
    Xcode      : Xcode 7.1 Build version 7B91b 
    ios-deploy : 1.9.1 
    ios-sim    : 5.0.13 
    npm        : 3.10.10 

##On Blank app
I have the same errors I had before.

#11

It works in production build.
After updating (and reading release notes for breaking changes),
run using --prod flag:

ionic cordova build ios --prod
1 Like
#12

Also, I have confirmed that production build wont solve the problem with out the updates.
For more details about the cause of the problem: As far as my understanding goes, it’s a minifiction problem.