Closed megha0071994 closed 1 year ago
Can you try adding this to your webpack config
webpack.chainWebpack((config) => {
config.optimization.usedExports(false);
Thank you very mush @triniwiz this seems to have fix the issue. The app is building successfully now. But could you please explain why this was happening and if this is a permanent solution can this be added to the documentation.
when I use tns run android to test the application locally, the app works fine. But when I build the application tns build android the application is crashing with the following exception on startup.
![image](https://user-images.githubusercontent.com/44086358/178345451-5103773d-51d7-45dc-b107-431b7618db66.png)
As we are using angular in our app we added Admob.init() in APP_INITIALIZER. import { Admob } from "@nativescript/firebase-admob";
export function initializeAdmob() { return (): Promise => {
return Admob.init();
};
}
node version: 18.4.0 npm version: 8.1.4 ns version: 8.2.3 ns firebase version: 2.1.0