Skip to content

Commit

Permalink
global replace
Browse files Browse the repository at this point in the history
  • Loading branch information
bahmutov committed Nov 17, 2021
1 parent 80f50bc commit 99a1f31
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/commands/querying.md
Original file line number Diff line number Diff line change
Expand Up @@ -544,7 +544,7 @@ cy.get('#spaces').should($el => {
})
// you can also remove duplicate white spaces before calling cy.contains
// and for good measure trimp the text we are looking for
cy.contains('#spaces', 'LEGO: blocks'.replace(/\s+/, ' ').trim())
cy.contains('#spaces', 'LEGO: blocks'.replace(/\s+/g, ' ').trim())
```

<!-- fiddle-end -->
Expand Down

0 comments on commit 99a1f31

Please sign in to comment.