Skip to content

Conversation

gamb
Copy link

@gamb gamb commented Jan 28, 2014

After calling map.remove() I tried to initialise a new map on the same DOM element , after map.on('unload'), and came up against ''Uncaught Error: Map container is already initialized."

I found that by firing 'unload' at the end of remove() I can achieve this.

@mourner
Copy link
Member

mourner commented Jan 28, 2014

Right!

mourner added a commit that referenced this pull request Jan 28, 2014
@mourner mourner merged commit 02db8b4 into Leaflet:master Jan 28, 2014
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

Successfully merging this pull request may close these issues.

2 participants