ionic-team / ionic-starter-maps Goto Github PK
View Code? Open in Web Editor NEWAn Ionic starter project using Google Maps and a side menu
An Ionic starter project using Google Maps and a side menu
ionic 4 Map does not show in device (works with browser)...
Freezes upon clicking current location arrow. Also, where is the sidemenu?
It may be util to have this template for ionic v2.
Works great in a regular ionic tab view.
Tried to get it working in an ionic modal, and though it renders, but is not visible. Have had to look at it from web console in the dom.
There is a reference in the forum:
http://forum.ionicframework.com/t/google-maps-doesnt-show-up-in-modal/4128/2
Though i am not sure how that's working.
I created a new project with the maps template. When I run it with ionic (ionic serve), I'm able to see the map in my browser. Running the project in my device or emulator, after installing the platform, (ionic run android or ionic emulate android) the map does not load and I get a blank screen. What could be causing this?
I just got a fresh install of ionic and I tried this starter template but I cannot see a map on chrome or safari after doing: ionic serve
I don't see any errors on the browser console but here is the console output of the app creation, etc:
~/d/p/ionicplay $ ionic start myApp maps
Creating Ionic app in folder /Users/andrebatista/dev/projects/ionicplay/myApp based on maps project
Downloading: https://github.com/driftyco/ionic-app-base/archive/master.zip
[=============================] 100% 0.0s
Downloading: https://github.com/driftyco/ionic-starter-maps/archive/master.zip
Update config.xml
Initializing cordova project
Fetching plugin "org.apache.cordova.device" via plugin registry
Fetching plugin "org.apache.cordova.console" via plugin registry
Fetching plugin "com.ionic.keyboard" via plugin registry
Your Ionic project is ready to go! Some quick tips:
For more help use ionic --help or visit the Ionic docs: http://ionicframework.com/docs
+---------------------------------------------------------+
[email protected] install /Users/andrebatista/dev/projects/ionicplay/myApp/node_modules/gulp-sass/node_modules/node-sass
node build.js
child_process: customFds option is deprecated, use stdio instead.
child_process: customFds option is deprecated, use stdio instead.
CXX(target) Release/obj.target/binding/binding.o
CXX(target) Release/obj.target/binding/sass_context_wrapper.o
CXX(target) Release/obj.target/binding/libsass/ast.o
CXX(target) Release/obj.target/binding/libsass/base64vlq.o
CXX(target) Release/obj.target/binding/libsass/bind.o
CXX(target) Release/obj.target/binding/libsass/constants.o
CXX(target) Release/obj.target/binding/libsass/context.o
CXX(target) Release/obj.target/binding/libsass/contextualize.o
CXX(target) Release/obj.target/binding/libsass/copy_c_str.o
CXX(target) Release/obj.target/binding/libsass/error_handling.o
CXX(target) Release/obj.target/binding/libsass/eval.o
CXX(target) Release/obj.target/binding/libsass/expand.o
CXX(target) Release/obj.target/binding/libsass/extend.o
CXX(target) Release/obj.target/binding/libsass/file.o
CXX(target) Release/obj.target/binding/libsass/functions.o
CXX(target) Release/obj.target/binding/libsass/inspect.o
CXX(target) Release/obj.target/binding/libsass/output_compressed.o
CXX(target) Release/obj.target/binding/libsass/output_nested.o
CXX(target) Release/obj.target/binding/libsass/parser.o
CXX(target) Release/obj.target/binding/libsass/prelexer.o
CXX(target) Release/obj.target/binding/libsass/sass.o
CXX(target) Release/obj.target/binding/libsass/sass_interface.o
CXX(target) Release/obj.target/binding/libsass/source_map.o
CXX(target) Release/obj.target/binding/libsass/to_c.o
CXX(target) Release/obj.target/binding/libsass/to_string.o
CXX(target) Release/obj.target/binding/libsass/units.o
CXX(target) Release/obj.target/binding/libsass/utf8_string.o
CXX(target) Release/obj.target/binding/libsass/util.o
CXX(target) Release/obj.target/binding/libsass/sass2scss/sass2scss.o
SOLINK_MODULE(target) Release/binding.node
SOLINK_MODULE(target) Release/binding.node: Finished
Installed in /Users/andrebatista/dev/projects/ionicplay/myApp/node_modules/gulp-sass/node_modules/node-sass/bin/darwin-x64-v8-3.28/binding.node
[email protected] node_modules/gulp-rename
[email protected] node_modules/shelljs
[email protected] node_modules/gulp-util
โโโ [email protected]
โโโ [email protected]
โโโ [email protected] ([email protected])
โโโ [email protected] ([email protected], [email protected])
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected])
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected])
โโโ [email protected] ([email protected], [email protected])
โโโ [email protected] ([email protected])
[email protected] node_modules/gulp-concat
โโโ [email protected] ([email protected], [email protected])
โโโ [email protected] ([email protected])
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected])
[email protected] node_modules/gulp-minify-css
โโโ [email protected]
โโโ [email protected] ([email protected], [email protected])
โโโ [email protected] ([email protected])
โโโ [email protected] ([email protected])
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected])
โโโ [email protected] ([email protected], [email protected])
[email protected] node_modules/gulp
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected] ([email protected])
โโโ [email protected]
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected])
โโโ [email protected]
โโโ [email protected] ([email protected], [email protected], [email protected])
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected])
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected])
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected])
[email protected] node_modules/bower
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected]
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected])
โโโ [email protected]
โโโ [email protected] ([email protected])
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected])
โโโ [email protected]
โโโ [email protected] ([email protected], [email protected], [email protected])
โโโ [email protected] ([email protected])
โโโ [email protected] ([email protected])
โโโ [email protected] ([email protected])
โโโ [email protected] ([email protected])
โโโ [email protected] ([email protected], [email protected], [email protected])
โโโ [email protected] ([email protected], [email protected])
โโโ [email protected] ([email protected], [email protected])
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected])
โโโ [email protected] ([email protected], [email protected], [email protected])
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected])
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected])
โโโ [email protected] ([email protected])
โโโ [email protected]
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected])
โโโ [email protected] ([email protected], [email protected])
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected])
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected])
[email protected] node_modules/gulp-sass
โโโ [email protected]
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected])
โโโ [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected])
Successful npm install
Updated /Users/andrebatista/dev/projects/ionicplay/myApp/www/index.html references to sass compiled css
Ionic project ready to use Sass!
[02:54:55] Using gulpfile ~/dev/projects/ionicplay/myApp/gulpfile.js
[02:54:55] Starting 'sass'...
[02:54:55] Finished 'sass' after 323 ms
Successful sass build
~/d/p/i/myApp $ ionic serve
Gulp startup tasks: [ 'sass', 'watch' ]
Running dev server: http://localhost:8100
Running live reload server: http://localhost:35729
Watching : [ 'www//*', '!www/lib//*' ]
Ionic server commands, enter:
restart or r to restart the client app from the root
goto or g and a url to have the app navigate to the given url
consolelogs or c to enable/disable console log output
serverlogs or s to enable/disable server log output
quit or q to shutdown the server and exit
[02:55:12] Using gulpfile ~/dev/projects/ionicplay/myApp/gulpfile.js
[02:55:12] Starting 'sass'...
[02:55:12] Starting 'watch'...
[02:55:12] Finished 'watch' after 6.79 ms
CSS changed: www/css/ionic.app.css
[02:55:12] Finished 'sass' after 341 ms
CSS changed: www/css/ionic.app.min.css
I have this error: angular.js:13424 TypeError: Cannot read property 'setCenter' of undefined
at $cordovaGeolocation.getCurrentPosition.then.Dialogs.alert.title (create-spot.controller.js:33)
at processQueue (angular.js:15757)
at angular.js:15773
at Scope.$eval (angular.js:17025)
at Scope.$digest (angular.js:16841)
at angular.js:17064
at completeOutstandingRequest (angular.js:5824)
at angular.js:6100(anonymous function) @ angular.js:13424(anonymous function) @ angular.js:10137processQueue @ angular.js:15765(anonymous function) @ angular.js:15773$eval @ angular.js:17025$digest @ angular.js:16841(anonymous function) @ angular.js:17064completeOutstandingRequest @ angular.js:5824(anonymous function) @ angular.js:6100
And here is the code that i'm using:
`function CreateSpotController($scope, $cordovaGeolocation, Dialogs, $ionicPlatform) {
$scope.showMap = false;
$scope.getCurrentPosition = function (options) {
$scope.mapCreated = function (map) {
$scope.map = map;
};
options = options || {
timeout: 10000,
enableHighAccuracy: false
//maximumAge: 5000
};
$ionicPlatform.ready(function () {
$cordovaGeolocation
.getCurrentPosition(options)
.then(function (position) {
//show map
$scope.showMap = true;
$scope.latitude = position.coords.latitude;
$scope.longitud = position.coords.longitude;
$scope.map.setCenter(new google.maps.LatLng(position.coords.latitude, position.coords.longitude));
}, function(error) {
// error
Dialogs.alert({
title: 'Error',
message: error,
buttonName: 'Aceptar'
});
});
});
}; // end getCurrentPosition
} // end CreateSpotController`
can you help me please?
I'm wondering if there are any changes in the sidemenu-starter project that could be integrated into this one? If so I'd really appreciate that, thanks ๐
Hey folks,
I'm having trouble to add Google maps to my Ionic app so decided to go back to the basic examples. This app works well on the browser, but I can't seem to get it to work smoothly on iOS.
On 7.1 it asks for permission to get the location twice, the second being an odd prompt:
On 8.1 and 8.2 the app simply becomes unresponsive (can't scroll or click on anything). It seems to happen just before it can ask for permissions to get the location. I was able to reproduce this both on the emulator and on my own iPhone.
Any ideas/suggestions?
Thanks!
For some reason, when I click on the Locate Me icon at the bottom left corner, the application freezes !
I'm using iPhone 5 (ios 8.3).
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.