nuxt-modules / i18n

I18n module for Nuxt
https://i18n.nuxtjs.org
MIT License
1.66k stars 468 forks source link

SyntaxError: Invalid regular expression: invalid group specifier name (Safari) #2848

Closed tjifyodor closed 3 months ago

tjifyodor commented 3 months ago

Environment

Reproduction

https://stackblitz.com/fork/github/BobbieGoede/nuxt-i18n-starter/tree/v8 Opened on iOS <= 15

Describe the bug

Regex lookahead/lookbehind is not supported on older safari browsers, ufo@1.5.1 from the latest update, which is used as dependency, added one, so project opened in older safari is not working anymore

Additional context

No response

Logs

No response

github-actions[bot] commented 3 months ago

Would you be able to provide a reproduction? 🙏

More info ### Why do I need to provide a reproduction? Reproductions make it possible for us to triage and fix issues quickly with a relatively small team. It helps us discover the source of the problem, and also can reveal assumptions you or we might be making. ### What will happen? If you've provided a reproduction, we'll remove the label and try to reproduce the issue. If we can, we'll mark it as a bug and prioritise it based on its severity and how many people we think it might affect. If `needs reproduction` labeled issues don't receive any substantial activity (e.g., new comments featuring a reproduction link), we'll close them. That's not because we don't care! At any point, feel free to comment with a reproduction and we'll reopen it. ### How can I create a reproduction? We have a couple of templates for starting with a minimal reproduction: 👉 [Reproduction starter (v8 and higher)](https://stackblitz.com/fork/github/BobbieGoede/nuxt-i18n-starter/tree/v8) 👉 [Reproduction starter (edge)](https://stackblitz.com/fork/github/BobbieGoede/nuxt-i18n-starter/tree/edge) A public GitHub repository is also perfect. 👌 Please ensure that the reproduction is as **minimal** as possible. See more details [in our guide](https://nuxt.com/docs/community/reporting-bugs/#create-a-minimal-reproduction). You might also find these other articles interesting and/or helpful: - [The Importance of Reproductions](https://antfu.me/posts/why-reproductions-are-required) - [How to Generate a Minimal, Complete, and Verifiable Example](https://stackoverflow.com/help/mcve)
tjifyodor commented 3 months ago

@BobbieGoede, I'm not sure if it is possible to create sharable reproduction for just a "starter template" running on a specific environment (iOS 15)

BobbieGoede commented 3 months ago

If this error is triggered in a plain starter template when opened in iOS 15, then even just a link to the starter template is sufficient, it's just to reduce the steps required for debugging as well as confirmation if any additional steps are required to reproduce the behavior.

But to be honest, ufo is installed and used by various dependencies upstream (nuxt, nitropack and more), aren't you running into this issue even without Nuxt I18n? I'm fine with tracking this issue here but it's likely not something we can work towards resolving in this module, I see it's also being tracked here https://github.com/unjs/ufo/issues/224.

tjifyodor commented 3 months ago

@BobbieGoede yes, you are right, looks like every nuxt package updated to ufo@1.5.1 have this issue, just wanted to be sure that its tracked somewhere

pi0 commented 3 months ago

https://github.com/unjs/ufo/issues/224#issuecomment-2003701066