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.

`unicorn/better-regex` produces unreadable regex

See original GitHub issue

The rule is useful in some situations: https://github.com/xojs/xo/issues/227

But counterproductive in others: https://github.com/DmitrySoshnikov/regexp-tree/issues/208

/http:\/\/[^/]+\/pull\/commits/gi

👆 Readable

/ht{2}p:\/{2}[^/]+\/pul{2}\/com{2}its/gi

👆 Nonsense, longer

Can this specific regexp-tree transform be disabled?

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:7
  • Comments:19 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
fiskercommented, Jan 28, 2021

Haha, you are right, so strange.

1reaction
fiskercommented, Jan 28, 2021

I like that, but it’s rejected in previous discussion.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Is there a specific reason for the poor readability of regular ...
The unwarranted use of regular expressions can lead to unreadable expressions. Regular expressions need not be encoded as strings. If you have a...
Read more >
Are regexes really maintainable? - Stack Overflow
If regexes are long and impenetrable, making them hard to maintain then they should be commented. A lot of regex implementations allow you...
Read more >
Regex use vs. Regex abuse - Coding Horror
All developers should learn to use basic regular expressions, because they'll produce better, more flexible, more maintainable code with ...
Read more >
re — Regular expression operations — Python 3.11.1 ...
Source code: Lib/re/ This module provides regular expression matching ... Causes the resulting RE to match 0 or more repetitions of the preceding...
Read more >
#"" regex - ClojureScript API
Details: The concept of "global match" (i.e. /.../g in JavaScript) is not encoded in ClojureScript regular expressions ...
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