Please enable JavaScript to use regex101
/
^
r
e
g
e
x
[
\
-
_
]
?
1
0
1
$
/
i
Reg
ular
Ex
pressions
101
Upgrade to Pro
Enterprise
Regular Expression
/
<([a-z][-a-z]*[a-z]*)\s+[^>]*?(?:class="([^"]*)")[^>]*?\/?>
/
g
Input 1
<view class="pixel-art-container flex flex-col items-center"> <view class="pixel-art-wrapper"> <scroll-view class="pixel-art-scroll-view" scroll-x="{{true}}" scroll-y="{{true}}"> <view data-event-opts="{{[['touchmove',[['onTouchmove',['$event']]]],['touchstart',[['onTouchstart',['$event']]]]]}}" class="pixel-art-scroll-view-inner" style="{{'top:'+(positionX+'px')+';'+('left:'+(positionY+'px')+';')+('transform:'+('scale('+scale+')')+';')}}" bindtouchmove="__e" bindtouchstart="__e"> <block wx:for="{{pixelMatrix}}" wx:for-item="row" wx:for-index="rowIdx" wx:key="rowIdx"> <view class="pixel-art-row flex"> <block wx:for="{{row}}" wx:for-item="item" wx:for-index="colIdx" wx:key="id"> <view data-event-opts="{{[['tap',[['select',[rowIdx,colIdx]]]]]}}" class="{{['pixel-art-item','z-50',rowIdx===activePosition.y&&colIdx===activePosition.x?'active':'']}}" catchtap="__e"> <block wx:if="{{item.avatarUrl}}"> <i
Extraction
<view class="pixel-art-container flex flex-col items-center"> <view class="pixel-art-wrapper"> <scroll-view class="pixel-art-scroll-view" scroll-x="{{true}}" scroll-y="{{true}}"> <view data-event-opts="{{[['touchmove',[['onTouchmove',['$event']]]],['touchstart',[['onTouchstart',['$event']]]]]}}" class="pixel-art-scroll-view-inner" style="{{'top:'+(positionX+'px')+';'+('left:'+(positionY+'px')+';')+('transform:'+('scale('+scale+')')+';')}}" bindtouchmove="__e" bindtouchstart="__e"> <block wx:for="{{pixelMatrix}}" wx:for-item="row" wx:for-index="rowIdx" wx:key="rowIdx"> <view class="pixel-art-row flex"> <block wx:for="{{row}}" wx:for-item="item" wx:for-index="colIdx" wx:key="id"> <view data-event-opts="{{[['tap',[['select',[rowIdx,colIdx]]]]]}}" class="{{['pixel-art-item','z-50',rowIdx===activePosition.y&&colIdx===activePosition.x?'active':'']}}" catchtap="__e"> <block wx:if="{{item.avatarUrl}}"> <i