regex for (data-*) attributes

Created on 26 September 2023, 9 months ago
Updated 29 November 2023, 7 months ago

I'm trying to remove all the data attributes from elements. This regular expression is suppose to find any data attributes and remove them:

Search expression
(<[^>]*) (data-(\S+)=\"((?:\\.|[^"\\])*)")
Replacement
$1

I'm also testing the regular expression on the RegEx101 site.

After adding this regular expressions it still doesn't remove the data attribute.

πŸ’¬ Support request
Status

Fixed

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States michael.acevedo@pomona.edu

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.69.0 2024