Error: The Angular AoT build failed

After running ionic cordova build android --prod --release, i am getting the below error

[15:58:48] typescript error
Error encountered resolving symbol values statically. Function calls are not supported. Consider replacing
the function or lambda with a reference to an exported function (position 194:31 in the original .ts file),
resolving symbol NgModule in
resolving symbol RestangularModule in
resolving symbol RestangularModule in

I would reinstall ionic to the latest version.

Thanks for response, But my project is running on Ionic3 and i don’t want to update my Ionic.

can you prod build a blank app ? If not, install a fresh ionic 3 cli and retry ?

Hey Thanks trollanfer. Now it is working. I just updated my package.json file. There was a problem in ngx-restangular.