Not been Able to Build Production Build for my ionic 2 app

I am trying to build the production build for my ionic app. Everything works fine if am running my app with:

ionic run android

But when i am trying to build my production app by using

ionic run android --prod

i am getting this error:

Cannot read property ‘componentType’ of undefined main.js:7

and my app stays stuck at Splash Screen

Are you running ionic build android --prod

yes , still the same error

start with a plain dummy app
to see if your problem is the build command or ur app,

i have two apps , one is working perfectly fine , and other one is showing this error, both have same package.json

This may help