1) I've installed webpack 2) I've created a ""webpack.config.js" in the root folder 3) I'll copy the index.js file from www/js into the root folder. 4) I'll edit the index.js file in the root folder and add the code snippets from "https://mdc-docs.netlify.com/aerogear/latest/mobile-developer-console/#sdk", specifically point 3 : "In your application, import and call the "init" method:"
Rebuilt and result is "app-debug_with_webpack.apk" - see attached.
---- Next step, which is for Cordova only app, is to install webpack (this is not part of our docs afaik): ---- QE discussion - "If you have new plain cordova app, you will need to use webpack https://webpack.js.org/ just install it in your cordova project - npm install --save-dev webpack" ---- [jstaffor@jstaffor hello]$ npm install --save-dev webpack npm WARN com.example.hello@1.0.0 No repository field. npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
+ webpack@4.35.3 added 307 packages from 196 contributors and audited 4364 packages in 13.057s found 2 moderate severity vulnerabilities run `npm audit fix` to fix them, or `npm audit` for details |
|