Skip to main content
Version: 0.20.3

containsText

production

Filters for text containing the text provided as an argument.

Examples:

'This is a text' === containsText('text') => true
'This is a text' === containsText('other text') => false
'This is a text' === containsText('other') => false

  • @param {string} text - A text to be matched.