Avoiding try-catch block on examples/app-dir-i18n-routing (#51786)
`Negotiator.languages()` accepts an array of available locales and
returns only results that are present in it.
This effectively eliminates the need to use a try-catch block when
calling `matchLocale`.
---------
Co-authored-by:
JJ Kasper <jj@jjsweb.site>
Showing
Please
register
or
sign in
to comment