example/DuckDuckGo - advanced matchers/3 - RegExpMatcherScenario.js
description: 'Match the Zero Click Info box header with RegExps',
steps: [
{
'ZeroClickComponent.meanings': expandedAcronym, // match the textual content with a static regexp…
'SearchBarComponent.field': new RegExp('^' + query + '$') // …or with a dynamic one
// notice how we can match both the textual content of an element or the value of a field with the same syntax
}
]