Compare projects

Project comparisons allow you to view any selection of projects side by side just like they're shown on regular categories or in search results. You can try out an example or start yourself by adding a library to the comparison via the input below. You can also easily share your current comparison with others by sending the URL of the current page.

match_all
0.0
No release in over a year
Ruby String's native #match method will only return the first instance of a pattern match. This gem provides the #match_all method, returns all instances of a pattern match in a String as an array. EXAMPLES: # Given the test string: string = "My cat is asleep on the couch. Now the cat is playing." # #match only returns the first match: string.match(/cat/) => #<MatchData "cat"> # However, I've found I often want to match _all_ instances of the pattern, and # then e.g. iterate through them and do something with them. #match_all does that: string.match_all(/cat/) => [ [0] #<MatchData "cat">, [1] #<MatchData "cat"> ] This is especially useful if, e.g. you want to interrogate the matches to find out their starting/ending indexes within the string, etc
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024