Why App.js required?


#1

Hi,
I checked the sample app of IONIC 2 and see if we don’t have app.js file is not there in the App folder its not bundling the js to bundle.js and never starts up.

There will be cases when its not always required to have app.js file.

Can you please help me Out change the app.js file to any other file and folder structure.

Thanks


#2

Could you explain a bit more about what you mean?


#3

If you’re using the default browserify, you can change the entry point using browserifyOptions, as described here. You want the src option, and the default is ‘app/app.js’. If you’re using webpack, you can just define the entry point in the entry stanza of your webpack.config.js.


Changing Ionic 2 www folder
#4

For ionic 2 project by default its asking to have a app.js file in the app root folder, which I don’t want to keep and keep different name and in different place as well.


#5

Thanks @rapropos , I am able to make the application now as I want using the browserify options [buildBrowserify({ watch: true,src :“app/common/app.component.js”}).on(‘end’, done);]