Today I have started another project based on your tutorial. Typically I ran “ionic start TestProject --v2 --ts” then “ionic serve”. Chrome browser started, nothing appears. In the developer console error message appeared
"googlemaps.js:15 Uncaught ReferenceError: plugin is not defined". Then I have inspected project code and commented out "exports.GoogleMapsEvent = {
MAP_READY: plugin.google.maps.event.MAP_READY,
MAP_CLICK: plugin.google.maps.event.MAP_CLICK,
MAP_LONG_CLICK: plugin.google.maps.event.MAP_LONG_CLICK,
MY_LOCATION_BUTTON_CLICK: plugin.google.maps.event.MY_LOCATION_BUTTON_CLICK,
CAMERA_CHANGE: plugin.google.maps.event.CAMERA_CHANGE,
CAMERA_IDLE: plugin.google.maps.event.CAMERA_IDLE,
MAP_LOADED: plugin.google.maps.event.MAP_LOADED,
MAP_WILL_MOVE: plugin.google.maps.event.MAP_WILL_MOVE,
MAP_CLOSE: plugin.google.maps.event.MAP_CLOSE,
MARKER_CLICK: plugin.google.maps.event.MARKER_CLICK,
INFO_CLICK: plugin.google.maps.event.INFO_CLICK,
MARKER_DRAG: plugin.google.maps.event.MARKER_DRAG,
MARKER_DRAG_START: plugin.google.maps.event.MARKER_DRAG_START,
MARKER_DRAG_END: plugin.google.maps.event.MARKER_DRAG_END,
OVERLAY_CLICK: plugin.google.maps.event.OVERLAY_CLICK
};"
After that Chrome refreshed and the project started as usual.
If one doesn’t want to downgrade and doesn’t necessarily need google maps functionality then one can comment out relevant section of code in googlemaps.js. In that case the code which was reproduced to app.bundle.js would be commented out too and in turn the error wouldn’t reproduce. Am I right?