Ionic-app-scripts: what command do I give to run 'ionic serve in production' ? so that I minifies ( all that good stuff to render page fast in production ) ?

Created on 28 Nov 2016  路  4Comments  路  Source: ionic-team/ionic-app-scripts

_From @jpca999 on November 28, 2016 4:23_

_Copied from original issue: driftyco/ionic#9376_

Most helpful comment

You could try npm run ionic:build --prod and open the www/index.html file in your browser.

All 4 comments

We don't support that at this time.

Thanks,
Dan

Can I just say, I would find this useful for quick performance testing and debugging the output from the production build process. ionic build browser --prod adds in all the cordova fluff and ionic storage doesn't seem to work on there (goes hunting for SQL Lite). So I am stuck with deploying to a web server to test unless there is a quicker way ?

I am sure there are reasons for not doing this too, such as people using it to actually serve a production application over the web...

You could try npm run ionic:build --prod and open the www/index.html file in your browser.

That actually is working quite well... I was expecting some issues without running it on a web server. But I guess it isn't trying to load the templates via ajax because they are compiled in?

Was this page helpful?
0 / 5 - 0 ratings