We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 06c9a00 + 8f7f7d9 commit e1fd7ecCopy full SHA for e1fd7ec
README.md
@@ -1200,10 +1200,6 @@ longer. For short strings, `String#match?` performs similarly to
1200
> Sometimes you cant replace regexp with `start_with?`, <br>
1201
> for example: `"a\nb" =~ /^b/ #=> 2` but `"a\nb" =~ /\Ab/ #=> nil`.<br>
1202
> :warning: <br>
1203
-> You can combine `start_with?` and `end_with?` to replace
1204
-> `error.path =~ /^#{path}(\.rb)?$/` to this <br>
1205
-> `error.path.start_with?(path) && error.path.end_with?('.rb', '')`<br>
1206
-> —— @igas [rails/rails#17316](https://github.com/rails/rails/pull/17316)
1207
1208
```
1209
$ ruby -v code/string/start-string-checking-match-vs-start_with.rb
0 commit comments