"SyntaxError: Invalid regular expression: invalid group specifier name" on Safari
See original GitHub issueVersion
module: 0.6.2 nuxt: 2.14.12
Nuxt configuration
mode:
- universal
- spa
Nuxt configuration
export default {
// Target: https://go.nuxtjs.dev/config-target
target: 'static',
// Global page headers: https://go.nuxtjs.dev/config-head
head: {
title: 'sanity-test',
htmlAttrs: {
lang: 'en',
},
meta: [
{ charset: 'utf-8' },
{ name: 'viewport', content: 'width=device-width, initial-scale=1' },
{ hid: 'description', name: 'description', content: '' },
],
link: [{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }],
},
// Global CSS: https://go.nuxtjs.dev/config-css
css: [],
// Plugins to run before rendering page: https://go.nuxtjs.dev/config-plugins
plugins: [],
// Auto import components: https://go.nuxtjs.dev/config-components
components: true,
// Modules for dev and build (recommended): https://go.nuxtjs.dev/config-modules
buildModules: [
// https://go.nuxtjs.dev/eslint
'@nuxtjs/eslint-module',
'@nuxtjs/sanity',
],
// Modules: https://go.nuxtjs.dev/config-modules
modules: [],
// Build Configuration: https://go.nuxtjs.dev/config-build
build: {},
// Sanity Configuration:
sanity: {
projectId: 'vgw104pb',
},
}
Reproduction
Links:
Checklist
- I have tested with the latest Nuxt version and the issue still occurs
- I have tested with the latest module version and the issue still occurs
- I have searched the issue tracker and this issue hasn’t been reported yet
Steps to reproduce
- Open the site link: https://sad-heyrovsky-54a894.netlify.app/ on Safari.
- View the console to see this error:
SyntaxError: Invalid regular expression: invalid group specifier name
You can also test the GitHub repo locally.
Not sure if this is relevant but you can look at the sanity studio repo here: https://github.com/abdulrauf11/sanity-kitchen-sink/tree/main/studio
What is actually happening?
Issue Analytics
- State:
- Created 3 years ago
- Comments:9
Top Results From Across the Web
Works in Chrome, but breaks in Safari: Invalid regular ...
I had the same issue, and it turned out to be a RegEx expression in one of my dependencies, namely Discord.js .
Read more >Safari will not load React App. Invalid regular expression
The error concern "Invalid regular expression: invalid group specifier name". A google search revealed that Safari does not support all ...
Read more >SyntaxError: Invalid regular expression: invalid group ... - GitHub
I think this error is due to the fact that Safari does not support the "lookbehind" in regex. SyntaxError: Invalid regular expression: invalid ......
Read more >Angular SyntaxError - Apple Developer
Angular SyntaxError: SyntaxError: Invalid regular expression: invalid group specifier name.
Read more >Regex works in chrome, but breaks in safari: invalid regular ...
[Solved] Regex works in chrome, but breaks in safari: invalid regular expression: invalid group specifier name - CodeProject.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@danielroe - I was having the same issue and upgrading to 0.7.0 fixed it 😃
Thanks for spotting this. A server dependency with an unsupported RegExp (
upath
) was being included in the client build - should be fixed inv0.7.0
. Let me know if not 😃