Comments (9)
@sphaso you are missing two things (when looking at your code):
- In the providers, you include ANGULAR2_GOOGLE_MAPS_DIRECTIVES but it must be ANGULAR2_GOOGLE_MAPS_PROVIDERS.
- You have to include the directives ANGULAR2_GOOGLE_MAPS_DIRECTIVES in a directives array
@Page({
templateUrl: 'build/pages/mappa/mappa.html',
style: '.sebm-google-map-container { height: 300px; }',
directives: [ANGULAR2_GOOGLE_MAPS_DIRECTIVES],
providers: [
ANGULAR2_GOOGLE_MAPS_PROVIDERS
]
})
from angular-google-maps.
Thank you!
Now I get an error when loading the page: "No Directive annotation found on SebmGoogleMap". Any idea?
from angular-google-maps.
Try to update the versions for the following packages in your package.json file:
"dependencies": {
"angular2": "^2.0.0-beta.2",
"angular2-google-maps": "^0.6.1"
}
Then run npm install
in the terminal and restart your app.
from angular-google-maps.
I was already using those versions. Anything else I can do to help?
from angular-google-maps.
@sphaso played with Ionic and angular2-google-maps a few days ago. Uploaded my working app here, so you can diff with your code: https://github.com/SebastianM/MyIonic2Project
For running this project:
npm install
ionic serve
from angular-google-maps.
The angular2-google-maps related code is here: https://github.com/SebastianM/MyIonic2Project/blob/master/app/pages/hello-ionic/hello-ionic.ts
Closing this for now, feel free to reopen if you find any bugs/issues working with ionic.
from angular-google-maps.
Hi.
I've reopened this issue because I have the exact same problem. I'm working with Ionic 2 (2.0.0-beta.6) and Angular 2 (2.0.0-beta.15).
I have the latest version of angular2-google-maps.
I'm using this package as specified in the documentation & comments.
Here is my code :
import {Page} from 'ionic-angular';
import {ANGULAR2_GOOGLE_MAPS_DIRECTIVES, SebmGoogleMap} from 'angular2-google-maps/core';
@Page({
directives: [ANGULAR2_GOOGLE_MAPS_DIRECTIVES, SebmGoogleMap],
template: `
<sebm-google-map [latitude]="lat" [longitude]="lng"></sebm-google-map>
`,
styles: [`
.sebm-google-map-container {
height: 300px;
}
`]
})
export class MapPage {
lat: number = -34;
lng: number = 138;
constructor() {}
}
And the error:
Uncaught (in promise): No Directive annotation found on SebmGoogleMap
I'm currently investigating, I'll update this comment if I found anything.
from angular-google-maps.
Hi @mildful,
the latest angular2-google-maps version (0.10.0) supports angular2-rc.1 only - the current docs/getting started guide is out of date (sorry, update of the docs coming soon).
from angular-google-maps.
import {ANGULAR2_GOOGLE_MAPS_DIRECTIVES} from 'angular2-google-maps/core';
is now
{GOOGLE_MAPS_PROVIDERS} from 'angular2-google-maps/core';
from angular-google-maps.
Related Issues (20)
- Not getting lat long data from Circle and Rectangle
- No Support for Angular 12 version. HOT 1
- How to grey the Map? HOT 2
- Angular 14 support? HOT 15
- Warning Error
- Can you provide a support to create a Context Menu on Marker Right click.
- agm-polygon path is not getting updated on changes in component.ts file
- click
- fullscreenControl and fullscreenControlOptions is not working as expected
- Blur the map area when a polygon is drawn
- NG 14 support not published HOT 15
- Publish please HOT 2
- In Angular version 16 not working HOT 4
- How to implement data-driven styling based on placeId?
- error TS2314: Generic type 'MapHandlerMap<T>' requires 1 type argument(s). HOT 3
- error in (agm-core.js:299:31) when using @Agm/core
- In Angular-16 gives error
- Angular 16 compatibility? HOT 2
- Google Maps warning HOT 1
- google.maps.MouseEvent returns "r"
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from angular-google-maps.