-
-
Notifications
You must be signed in to change notification settings - Fork 7.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add a function like findRE
that will return all sub/group matching.
#10594
Comments
findRE
that will return all sub-matching.findRE
that will return all sub/group matching.
I believe that FindAllStringSubmatch provides the desired functionality, but I am concerned that site developers will have a difficult time wrapping their heads around this. For your specific example, you can do this:
The resulting data structure (jsonified)...
|
@jmooring Thank you for the workaround, but I'm concerned about the performance between
I think it's related to the documentations. |
I don't think we need to benchmark to to show the value, and I have needed this myself in some cases. |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Related topic: https://discourse.gohugo.io/t/regular-expressions-sub-matching-groups-not-supported/15368
I would like to create functions that parse and return some stuff of HTML like following.
Result (something like this)
The text was updated successfully, but these errors were encountered: