question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Bug in extension for Safari - regex in icondb.js

See original GitHub issue

Hey, There is a regex issue in the new build for Safari.

I’m getting an error on this line (2614?) in content.bundle.js.

image

(I just ran a js formatter on the js so I could see what line was causing the issue)

["tag-icon", ["medium-green", "medium-green"], /(?:\.|^)sha(?:256|sum)?$|(?:\.|^)(?:check|ck|crc(?:32)?|md5|rmd160|sha(?:224|256|384|512|1|2|3)?)?(?:sums?|(?<=\w))$/i, , !1, , /\.text\.checksums$/i],

If I comment out this line then everything is working ok.

@csandman do you have any ideas? Can we just drop that line when doing update assets?

Its coming in from file-icons/db/icondb.js.

I’m kinda surprised this isn’t popping up in chrome? I’m not sure how to test there.

To reproduce in Safari:

npm install
npm run update-assets
npm run build

Xcode, open /safari/File Icons for GitHub and GitLab.xcodeproj

Change to MacOS: image

  • Click run
  • Click quite and open in Safari
  • Safari > develop > enable unsigned extensions

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:1
  • Comments:8 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
iRoachiecommented, Jun 29, 2022

Just got it! Works great! Thanks so much 🚀

1reaction
christopherpickeringcommented, Jun 29, 2022

@iRoachie Hey, the App Store just released… working for me 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

bug in Safari javascript RegExp? - Apple Support Communities
This code splits the string into 2 pieces in Firefox and IE, but just 1 piece in Safari. It seems like a bug...
Read more >
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 >
RegExp - JavaScript - MDN Web Docs - Mozilla
Chrome Edge RegExp Full support. Chrome1. Toggle history Full support. Edge12. Toggle history @@match Full support. Chrome50. Toggle history Full support. Edge13. Toggle history @@matchAll Full...
Read more >
ClickToPlugin & ClickToFlash Safari extensions
ClickToPlugin is a lightweight and highly customizable extension that prevents Safari from launching plug-ins automatically, resulting in faster browsing, ...
Read more >
146162 - Regex causes browser to hang for 60 seconds ...
Issue 146162: Regex causes browser to hang for 60 seconds (works fine in FF,Opera,Safari). Reported by schedule a_deleted_user a_deleted_user.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found