We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8b9dba9 commit 6aefcb0Copy full SHA for 6aefcb0
1 file changed
Types/MarkX/get_LiquidPattern.ps1
@@ -0,0 +1,28 @@
1
+<#
2
+.SYNOPSIS
3
+ Get the Liquid Pattern
4
+.DESCRIPTION
5
+ Gets the regular expression pattern used to match Liquid tags.
6
+#>
7
+param()
8
+$liquidPattern = @(
9
+ '(?>'
10
+ '\{\%\s{0,}'
11
+ '(?<tag>[^\%]+)'
12
+ '\s{0,}\%}'
13
+
14
+ '|'
15
16
+ '(?<noescape>\{{3})'
17
+ '(?<expression>[^\}]+)'
18
+ '\}{3}'
19
20
21
22
+ '\{{2}'
23
24
+ '\}{2}'
25
+ ')'
26
+) -join ''
27
28
+return [Regex]::new($liquidPattern)
0 commit comments