Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing resources #29

Open
Avec112 opened this issue Nov 18, 2020 · 2 comments
Open

Missing resources #29

Avec112 opened this issue Nov 18, 2020 · 2 comments

Comments

@Avec112
Copy link

Avec112 commented Nov 18, 2020

What a fantastic implementation you have made! It was love at first sight for me.

I am requesting a feature for leaflet4vaadin

I installed leaflet4vaadin 0.4.0 as a dependency in my application.
I added a Marker to the leafletMap but it would not display. After a little research I concluded that the image/ directory was not included and have to be added manually.

Would it be possible to include the needed resources with the jar dependency so the jar will be a complete product?
If not could you document what must be included in addition to configuring Maven pom?

@jimbok8
Copy link

jimbok8 commented Jan 26, 2021

If you having missing image files:
You need to read this excellent article:
"Where should I place my Vaadin 10+ static files?"

https://stackoverflow.com/questions/57553973/where-should-i-place-my-vaadin-10-static-files/57553974#57553974

Its says for Vaadin 14, and I can verify Vaadin 15, for SPRING-BOOT applications, you should put images here:
src\main\resources\META-INF\resources\images
Then you can refer to them like this new Icon("images/leaf-green.png").
Hope this helps.
(Also works with Vaadin 17.0.11)
Jim

@Avec112
Copy link
Author

Avec112 commented Jan 30, 2021

Thanks Jim. Great link you provided 👍

The problem is however not where I should place the resources, but rather leaflet4vaadin not including them. The implementation is in place but not the marker image in particular. Think of it as buying a car and when you are about to put your kids in the back seat you notice it is completely missing :-)

I found a bunch of images elsewhere but I believe implementation and needed resources should be packaged together.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants