Skip to content
CodeWiki
Practice
Paths
Tracks
Cheatsheets
Playground
Glossary
AI era
Search
⌘K
English
English
Chinese
Practice
Paths
Tracks
Cheatsheets
Playground
Glossary
AI era
English
English
Chinese
Practice
/
Quiz
/
JavaScript
/
Regular expressions
A search term must be treated as literal text inside a larger Node 24 pattern. What shoul…
from Regular expressions
Node 24
beginner
1 min
A search term must be treated as literal text inside a larger Node 24 pattern. What should the code do?
Insert RegExp.escape(term) into the pattern source.
Insert term directly and add the i flag.
Apply encodeURIComponent(term) before insertion.
Wrap term in a capturing group; parentheses make it literal.
Check
Ask AI about this kata
Report an error
previous kata
Which API returns every match with each match’s named captures and indices?
Quiz
next kata
What does this program print?
Predict the output
A new version is available
Reload