Skip to Content
  • Website
Codsen
  • Home
  • Open Source
  • Articles
  • About

backOpen Source→string-left-right→Examples

Table of Contents

  • Quick Take
  • Match a character sequence without regard to letter case
  • Match repeated sequences on the left and include nearby whitespace
  • Control how chomp functions include surrounding whitespace
  • Match repeated sequences on the right and include nearby whitespace
  • Match a whitespace-tolerant character sequence on the left
  • Combine optional and repeated sequence flags
  • Mark one sequence value as optional with a question mark
  • Match one or more repeated sequence values with an asterisk
  • Match a whitespace-tolerant character sequence on the right
  • Find the nearest non-whitespace character on the right
  • Treat a newline as a stopping point in either direction
  • Treat a raw non-breaking space as a stopping point
↑ back to top

Quick Take

↑ back to top

Match a character sequence without regard to letter case

↑ back to top

Match repeated sequences on the left and include nearby whitespace

↑ back to top

Control how chomp functions include surrounding whitespace

↑ back to top

Match repeated sequences on the right and include nearby whitespace

↑ back to top

Match a whitespace-tolerant character sequence on the left

↑ back to top

Combine optional and repeated sequence flags

↑ back to top

Mark one sequence value as optional with a question mark

↑ back to top

Match one or more repeated sequence values with an asterisk

↑ back to top

Match a whitespace-tolerant character sequence on the right

↑ back to top

Find the nearest non-whitespace character on the right

↑ back to top

Treat a newline as a stopping point in either direction

↑ back to top

Treat a raw non-breaking space as a stopping point

↑ back to top
back 

Copyright

All rights reserved © Roy Revelt 2026
All our open source packages are under MIT licenceopens in a new tab

Activities

🐛 See a bug? Raise an issueopens in a new tab
💘 Check out the Indiewebopens in a new tab and Libera manifestoopens in a new tab