# Ionic Starter App missing main.js

**URL:** <https://forum.ionicframework.com/t/ionic-starter-app-missing-main-js/91627>\
**Category:** ionic-v3\
**Created:** [May 24, 2017, 3:22pm UTC](https://forum.ionicframework.com/t/ionic-starter-app-missing-main-js/91627 "2017-05-24T15:22:02Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![G00330024](https://avatars.discourse-cdn.com/v4/letter/g/e495f1/32.png) [@G00330024](https://forum.ionicframework.com/u/G00330024)\
**Post date:** [May 24, 2017, 3:22pm UTC](https://forum.ionicframework.com/t/ionic-starter-app-missing-main-js/91627/1 "2017-05-24T15:22:03Z")

</div>

Hi,

I installed today NodeJs. from scratch then installed Ionic and Cordova:  
npm install -g cordova ionic

It went fine, no errors.Now my versions are:  
global packages:

```
@ionic/cli-utils : 1.2.0
Ionic CLI : 3.2.0

```

System:

```
Node : v6.10.3
OS : Windows 7
Xcode : not installed
ios-deploy : not installed
ios-sim : not installed

```

Then I tried to start a new app with blank(or sidemenu) template. Which started with no errors.

Now when i run ionic serve, i get no errors in console, but i get only a blank app in browser stating the main.js is missing.  
Indeed the file is not in www\bild, neither the map for main.js.

What i tried:

- Different version of node js (6.10.3 and 6.7.0 with nvm-windowds)
- Uninstall and delete the whole thing
- Use windows command line instead of gitbash
- Google the answer for a few hours

The question is: What else could i try? What could be the issue?

**UPDATE**

This is the start:

> user@user-PC MINGW64 /e/!EPApp  
> $ ionic start asd blank  
> ✔ Creating directory .\asd - done!  
> [INFO] Fetching app base ([https://github.com/driftyco/ionic2-app-base/archive/master.tar.gz](https://github.com/driftyco/ionic2-app-base/archive/master.tar.gz))  
> ✔ Downloading - done!  
> [INFO] Fetching starter template blank ([https://github.com/driftyco/ionic2-starter-blank/archive/master.tar.gz](https://github.com/driftyco/ionic2-starter-blank/archive/master.tar.gz))  
> ✔ Downloading - done!  
> ✔ Updating package.json with app details - done!  
> ✔ Creating configuration file ionic.config.json - done!  
> [INFO] Installing dependencies may take several minutes!
> 
> > npm install  
> > ✔ Running command - done!  
> > npm install --save-dev --save-exact @ionic/cli-plugin-ionic-angular@latest  
> > ✔ Running command - done!  
> > git init  
> > ✔ Running command - done!  
> > git add -A  
> > ✔ Running command - done!  
> > git commit -m Initial commit  
> > ✔ Running command - done!

> ♬ ♫ ♬ ♫ Your Ionic app is ready to go! ♬ ♫ ♬ ♫

> Run your app in the browser (great for initial development):  
> ionic serve

> Run on a device or simulator:  
> ionic cordova run ios

> Test and share your app on a device with the Ionic View app:  
> [http://view.ionic.io](http://view.ionic.io)

> ? Link this app to your Ionic Dashboard to use tools like Ionic View? (Y/n) n  
> ? Link this app to your Ionic Dashboard to use tools like Ionic View? No

> Go to your newly created project: cd .\asd

Ionic info in project:

> $ ionic info

> global packages:

> ```
> @ionic/cli-utils : 1.2.0
> Ionic CLI : 3.2.0
> 
> ```

> local packages:

> ```
> @ionic/app-scripts : 1.3.7
> @ionic/cli-plugin-ionic-angular : 1.2.0
> Ionic Framework : ionic-angular 3.2.1
> 
> ```

> System:

> ```
> Node : v6.10.3
> OS : Windows 7
> Xcode : not installed
> ios-deploy : not installed
> ios-sim : not installed
> 
> ```

Ionic serve:

Shows a blank page in the browser and writes this into the console:  
_Failed to load resource: the server responded with a status of 404 (Not Found) main.js_

Ionic Serve:

> $ ionic serve -lab  
> [INFO] Starting app-scripts server: --nobrowser --b --lab --l --a --port 8100 – p 8100 --livereload-port 35729 --r 35729 --address 0.0.0.0 - Ctrl+C to cancel  
> [16:12:12] watch started …  
> [16:12:12] build dev started …  
> [16:12:12] clean started …  
> [16:12:12] clean finished in 2 ms  
> [16:12:12] copy started …  
> [16:12:12] transpile started …  
> [16:12:15] transpile finished in 3.65 s  
> [16:12:15] preprocess started …  
> [16:12:15] deeplinks started …  
> [16:12:15] deeplinks finished in 25 ms  
> [16:12:15] preprocess finished in 25 ms  
> [16:12:16] webpack started …  
> [16:12:16] webpack finished in 235 ms  
> [16:12:16] sass started …  
> [16:12:16] copy finished in 3.93 s  
> [16:12:16] sass finished in 290 ms  
> [16:12:16] postprocess started …  
> [16:12:16] postprocess finished in 8 ms  
> [16:12:16] lint started …  
> [16:12:16] build dev finished in 4.25 s  
> [16:12:16] watch ready in 4.36 s  
> [16:12:16] dev server running: [http://localhost:8100/](http://localhost:8100/)

> [16:12:20] lint finished in 3.58 s

npm build runs without output and nothing seems to change.

---

<div class="post-metadata">

**Author:** ![Sujan12](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/sujan12/32/108395_2.png) [@Sujan12](https://forum.ionicframework.com/u/Sujan12)\
**Post date:** [May 24, 2017, 4:44pm UTC](https://forum.ionicframework.com/t/ionic-starter-app-missing-main-js/91627/2 "2017-05-24T16:44:05Z")

</div>

What exact command are you using to `start` the app?  
What is the `ionic info` output in your created project folder?  
What exactly does `ionic serve` output?  
Try running `npm run build` there and tell us what happens.

---

<div class="post-metadata">

**Author:** ![G00330024](https://avatars.discourse-cdn.com/v4/letter/g/e495f1/32.png) [@G00330024](https://forum.ionicframework.com/u/G00330024)\
**Post date:** [May 24, 2017, 4:55pm UTC](https://forum.ionicframework.com/t/ionic-starter-app-missing-main-js/91627/3 "2017-05-24T16:55:54Z")

</div>

Updated the question.

---

<div class="post-metadata">

**Author:** ![Sujan12](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/sujan12/32/108395_2.png) [@Sujan12](https://forum.ionicframework.com/u/Sujan12)\
**Post date:** [May 24, 2017, 5:31pm UTC](https://forum.ionicframework.com/t/ionic-starter-app-missing-main-js/91627/4 "2017-05-24T17:31:19Z")

</div>

Something is strange on your system.

I just tried to reproduce this:

```auto
PS C:\Users\Jan\Documents> ionic info
[WARN] You are not in an Ionic project directory. Project context may be missing.

global packages:

    @ionic/cli-utils : 1.2.0
    Ionic CLI : 3.2.0

System:

    Node : v6.10.3
    OS : Windows 10
    Xcode : not installed
    ios-deploy : not installed
    ios-sim : not installed

PS C:\Users\Jan\Documents> ionic start asd blank
✔ Creating directory .\asd - done!
[INFO] Fetching app base (https://github.com/driftyco/ionic2-app-base/archive/master.tar.gz)
✔ Downloading - done!
[INFO] Fetching starter template blank (https://github.com/driftyco/ionic2-starter-blank/archive/master.tar.gz)
✔ Downloading - done!
✔ Updating package.json with app details - done!
✔ Creating configuration file ionic.config.json - done!
[INFO] Installing dependencies may take several minutes!
> npm install
✔ Running command - done!
> npm install --save-dev --save-exact @ionic/cli-plugin-ionic-angular@latest
✔ Running command - done!
> git init
✔ Running command - done!
> git add -A
✔ Running command - done!
> git commit -m Initial commit
✔ Running command - done!

♬ ♫ ♬ ♫ Your Ionic app is ready to go! ♬ ♫ ♬ ♫

Run your app in the browser (great for initial development):
  ionic serve

Run on a device or simulator:
  ionic cordova run ios

Test and share your app on a device with the Ionic View app:
  http://view.ionic.io

? Link this app to your Ionic Dashboard to use tools like Ionic View? No

Go to your newly created project: cd .\asd
PS C:\Users\Jan\Documents> cd .\asd\
PS C:\Users\Jan\Documents\asd> ionic info

global packages:

    @ionic/cli-utils : 1.2.0
    Ionic CLI : 3.2.0

local packages:

    @ionic/app-scripts : 1.3.7
    @ionic/cli-plugin-ionic-angular : 1.2.0
    Ionic Framework : ionic-angular 3.3.0

System:

    Node : v6.10.3
    OS : Windows 10
    Xcode : not installed
    ios-deploy : not installed
    ios-sim : not installed

PS C:\Users\Jan\Documents\asd> ionic serve
[INFO] Starting app-scripts server: --port 8100 --p 8100 --livereload-port 35729 --r 35729 --address 0.0.0.0 - Ctrl+C to
 cancel
[19:27:04] watch started ...
[19:27:04] build dev started ...
[19:27:04] clean started ...
[19:27:04] clean finished in 3 ms
[19:27:04] copy started ...
[19:27:04] transpile started ...
[19:27:09] transpile finished in 4.35 s
[19:27:09] preprocess started ...
[19:27:09] deeplinks started ...
[19:27:09] deeplinks finished in 18 ms
[19:27:09] preprocess finished in 21 ms
[19:27:09] webpack started ...
[19:27:09] copy finished in 4.83 s
[19:27:24] webpack finished in 15.00 s
[19:27:24] sass started ...
[19:27:25] sass finished in 1.65 s
[19:27:25] postprocess started ...
[19:27:25] postprocess finished in 32 ms
[19:27:25] lint started ...
[19:27:25] build dev finished in 21.12 s
[19:27:25] watch ready in 21.27 s
[19:27:25] dev server running: http://localhost:8100/

[19:27:31] lint finished in 5.43 s

```

Browser opened with the expected “Ionic Blank” template.

Same for `-lab` by the way:

```auto
PS C:\Users\Jan\Documents\asd> ionic serve -lab
[INFO] Starting app-scripts server: --nobrowser --b --lab --l --a --port 8100 --p 8100 --livereload-port 35729 --r 35729
 --address 0.0.0.0 - Ctrl+C to cancel
[19:29:43] watch started ...
[19:29:43] build dev started ...
[19:29:43] clean started ...
[19:29:43] clean finished in 21 ms
[19:29:43] copy started ...
[19:29:43] transpile started ...
[19:29:50] transpile finished in 6.80 s
[19:29:50] preprocess started ...
[19:29:50] deeplinks started ...
[19:29:50] deeplinks finished in 40 ms
[19:29:50] preprocess finished in 44 ms
[19:29:50] webpack started ...
[19:29:51] copy finished in 7.61 s
[19:30:13] webpack finished in 23.46 s
[19:30:13] sass started ...
[19:30:15] sass finished in 1.80 s
[19:30:15] postprocess started ...
[19:30:15] postprocess finished in 7 ms
[19:30:15] lint started ...
[19:30:15] build dev finished in 32.23 s
[19:30:15] watch ready in 32.38 s
[19:30:15] dev server running: http://localhost:8100/

[19:30:21] lint finished in 5.96 s

```

---

<div class="post-metadata">

**Author:** ![G00330024](https://avatars.discourse-cdn.com/v4/letter/g/e495f1/32.png) [@G00330024](https://forum.ionicframework.com/u/G00330024)\
**Post date:** [May 24, 2017, 6:49pm UTC](https://forum.ionicframework.com/t/ionic-starter-app-missing-main-js/91627/5 "2017-05-24T18:49:45Z")

</div>

Reproduced the whole thing in a VM on my PC. It works. Something gonna be with my system then.  
Thanks for the help!

UPDATE:

The issue was not with ionic itself. The issue what with webpack. I had an ! in my folder name. Once i removed the !, it worked perfectly.

---

<div class="post-metadata">

**Author:** ![Sujan12](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/sujan12/32/108395_2.png) [@Sujan12](https://forum.ionicframework.com/u/Sujan12)\
**Post date:** [June 13, 2017, 1:45pm UTC](https://forum.ionicframework.com/t/ionic-starter-app-missing-main-js/91627/6 "2017-06-13T13:45:08Z")

</div>

> [@G00330024](#):
>
> The issue was not with ionic itself. The issue what with webpack. I had an ! in my folder name. Once i removed the !, it worked perfectly.

Whoah, what a strange thing!
