Skip to content

error thrown within an event handler is undefined #11465

@Gregoor

Description

@Gregoor

Vue version

3.4.35

Link to minimal reproduction

https://play.vuejs.org/#eNp9UU1vwjAM/StWLi0SKge2CyrsSxy2wzZtO0aaumDaQptEScqHqv73OekKHCZOsf2enefnlj1onewaZDOWWmFK7cCia/SCy7LWyjhoweAaOlgbVUNE1IhLLoWS1kFtc5h7PI6iEZfppB9BzZQ4rHWVOaQMoG0Duet8kv40zikK7kVViu2cs3gE8wW0HgRw5jiElBRG7UHiHpbGKBNHttF3/jMPdiAyJwqI0WOjc1cvLFSTGq3Ncvzr8E/H2aLAYzrpdZDAdHKhlo2Zs7TgusyTjVWSvAmDOROq1mWF5k27kgzgbDZ8yVlWVWr/EmrONDge6qJAsf2nvrEHX+Ps3aBFs0POTpjLTI6uh5efr3ig+ATWatVUxL4CfqBVVeM19rTHRq5I9gUvqH0OFy5l/mWXB4fSDkt5ocGowOeMrv50ZfWz3Gly0xssO3Lxe4fGzyQDCUimt6z7BWmEyoA=

Steps to reproduce

  1. use an inline event handler, e.g. `@click="() => { }"
  2. throw an error within it (could also mean within a function you are calling)
  3. catch it, still within the event handler, and observe the error object being undefined

What is expected?

The error that has been thrown

What is actually happening?

The error is undefined

System Info

No response

Any additional comments?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions