Comments (1)
Compare with the behaviour of the built-in EventTarget
:
const foo = new EventTarget();
foo.addEventListener('customEvent',()=>{
throw new Error(`I don't like that event!`)
})
function fireSomeEvent() {
console.log('Some task ...')
const ev = new CustomEvent('customEvent');
foo.dispatchEvent(ev);
console.log('Another task ...')
}
fireSomeEvent()
This will log "Another task".
We never really set the Leaflet Evented
behaviour on stone, but I guess that @Falke-Design is right - the behaviour is not as expected (since I'd expect the same behaviour than EventTarget
).
I'd even say "let's replace Evented
with a subclass of EventTarget
", since it's 2024 and all browsers implement it.
from leaflet.
Related Issues (20)
- Questions re the (upcoming?) 2.x release and its impact on third party integrations HOT 3
- Pixel origin isn't updated when panning via drag HOT 1
- Error when clicking divIcon with auto size HOT 1
- Unable to zoom the map when pinching with multitouch on top of a marker (both fingers on top of the marker)
- L.DomUtil.disableTextSelection should only disable text selection on the map container HOT 4
- Packaged CSS is not what is shown in repository HOT 1
- CSS causes issue with Turbopack HOT 6
- role="auto" unnecessarily added to images. HOT 2
- Leaflet markers move around when zooming HOT 1
- How does Leaflet handle rendering with different vector data at different zoom?
- Add Marker To Center Of All Countries HOT 1
- Is Marker missing the data attribute in the typescript definition? HOT 2
- Cannot see cursors on Chromium Browsers HOT 3
- leafletjs.com welcome banner dead URLs HOT 3
- Backup/secondary tile server HOT 1
- Map attribution Flag Removal where not appropriate HOT 3
- Marker loads png from media instead of own image folder. HOT 2
- After displaying the polygon, a canvas is created that overlaps all elements on the map HOT 1
- Allow configuration of duration multiplier for flyTo
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 leaflet.