Skip to content

Commit

Permalink
Demo: maxRecursionDepth null
Browse files Browse the repository at this point in the history
  • Loading branch information
slevithan committed Oct 25, 2024
1 parent 4542293 commit b8206df
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion demo/demo.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ function showOutput(el) {
try {
const re = toRegExp(input, flags, {
allowBestEffort: optionAllowBestEffortValue,
maxRecursionDepth: +optionMaxRecursionDepthValue,
maxRecursionDepth: optionMaxRecursionDepthValue === '' ? null : +optionMaxRecursionDepthValue,
optimize: optionOptimizeValue,
target: optionTargetValue,
});
Expand Down
2 changes: 1 addition & 1 deletion demo/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ <h2>Try it</h2>
<code>allowBestEffort</code>
</label>
<label>
<input type="number" id="option-max-recursion-depth" value="6" min="2" max="100" onchange="setOptionMaxRecursionDepth(this.value)">
<input type="number" id="option-max-recursion-depth" value="6" min="2" max="100" onchange="setOptionMaxRecursionDepth(this.value)" onkeyup="setOptionMaxRecursionDepth(this.value)">
<code>maxRecursionDepth</code>
</label>
<label>
Expand Down

0 comments on commit b8206df

Please sign in to comment.