Hi guys,
Trying to integrate an interactive map into my project:
unfortunately OSM and Leaflet won’t work (Looks like they’re not being rendered in the webcontainer at all).
Tried multiple fixes, different approaches, different llms - nothing helped so far. Would be cool if someone has a workaround
OSM is working, we had this several times and there was an extra fix with cors cause of this. @shawn is the expert on this and can help you for sure
But maybe you want to share your prompt / chat history, so we can verify/find out what the problem is.
Hint: if you are on the stable release, try using the main branch for now, as there are the fixes 100% sure. I dont know at the moment about all and wheater or not they are already on the stable
dont think so
Leaflet works just fine now. There are many issues you could be encountering too. I’ve been through therapy to recover from my ordeal but I’m improving every day.
I’ll keep this as brief as possible too.
Pretty much the only Provider / Model I have had any success with is Google and Gemini 2.0 Flash. This will change very soon but please try this. And it’s free.
We’ve recently had fixes for CORS/COEP issues bye setting the header to ‘credentialless’. Now we’re waiting on Geolocation to be fixed also. It’s a problem working in the webcontainer, but once deployed, the Geolocation works very accurately.
As @leex279 Thomas said - make sure you’re on the main branch first as it’s about 3 weeks ahead of the stable currently and has the fixes.
One fix for the CORS issue was to apply a proxy server which came before the fixes and worked for me but is embedded in my code now so I’ll leave it.
After you’ve gotten on on the main branch and redeployed, and I’d suggest resetting all your chats so you’re not getting any issues with history corrupting your journey moving forward (not always required). Let me know and try a simple prompt to add a map or map component to a page then check to see it it renders then post your results back here.