GoogleMap googleMap = new GoogleMap("apiKey", null, "english");
googleMap.setSizeFull();
googleMap.setMinZoom(4);
googleMap.setMaxZoom(16);
//add(googleMap); THIS DOES NOT WORK GMap is not a compnent it seems for Vaadin 10
Tabs tabs = new Tabs(tab1, tab2, tab3);
Div pages = new Div(d1, d2, d3);
add(tabs); //THIS WORKS FINE
LMap leafletMap = new LMap();
leafletMap.setCenter(60.4525, 22.301);
leafletMap.setZoomLevel(15);
// add(leafletMap); THIS DOES NOT WORK EITHER....LMap is not a compnent it seems for Vaadin 10
It depends:
If you have html templates, you can add a web component (for example google-map) and map the attribute (for example latitude, longitude, apikey) to Java.
If you don’t use HTML templates then you can create your googlemap (java) component.
You can also use other map web component (googlemap component has bugs, I don’t know if there are some good map web components )
If you add some details (what you need to display on you map) then perhaps my answer will be more accurate
Yeah I have been grappling with the wrapper (i.e. reinventing the wheel) for my project that just needs to display maps and allow interaction with a marker.
I am thinking of dumping V10 and maybe go with Angular.js or maybe…maybe V8
Jean-Christophe Gueriaud:
It depends:
If you have html templates, you can add a web component (for example google-map) and map the attribute (for example latitude, longitude, apikey) to Java.
If you don’t use HTML templates then you can create your googlemap (java) component.
any example of the said template use ?
You can also use other map web component (googlemap component has bugs, I don’t know if there are some good map web components )
If you add some details (what you need to display on you map) then perhaps my answer will be more accurate
Leaflet would be my preference but there is no support in V10. I am wondering what the point of V11 is when
there is no support for such an important component in V10.
no worries…that minor mess up is not a problem …that is fine…those are great examples simple hands on examples that should make it into Vaadin tutorial and documentation. great sensible hands on use of flow in a very manageable size requiring short attention span(believe it or not by my 5yo kid is using vaadin and he said it was FINE and he gets it).I think examples should be manageable and quick to grasp. the ones you posted are great.