h3
h3 copied to clipboard
Remove warning for `defineEventHandler`
For historical reasons, we were used to automatically convert legacy express middleware to h3 handlers and when we changed that, we started to add a warning.
Most of the advanced features of h3 including type inference, object syntax, and middleware are only possible with this wrapper only and i think we probably always advice for it in all docs too.
But.. it often causes DX issues when we want simply draft a handler (app.use(() => 'ok')
) or try something or make an internal utility that is already typed.
I am thinking to remove the warning (while keep always using in docs).
/cc @danielroe do you have any concerns specifically re legacy reasons to keep?