Get Updates By E-mail 

Article Written By:
Johann Dowa

Open Source NSString Category Adding Many Ruby Inspired Helper Methods

  •  
  •  
  •  
  •  
  •  

I’ve mentioned a number of NSString add-on categories such as this one that allows you to integrate the iconic FontAwesome within your NSStrings and a useful fuzzy string matching library.

Here’s an NSString Category from Zach Davison that aims to bring the Ruby String methods to Objective-C called NSString Ruby.

The category implements over 60 of Ruby string methods in Objective-C including accessing subscripts through easily defined ranges, and regex matching.

As the readme states:

NSString+Ruby is an attempt to improve NSString by porting Ruby String methods onto a category on NSString.

This means you can use the majority of Ruby String methods in obj-c, with the exception of a few unnecessary, unimplemented (as of yet), and mutating methods (Mutation of strings is not the objective-c ‘way’, so we don’t do it here).

You can find NSString-Ruby on Github here.

A very nice add-on for NSString.


  •  
  •  
  •  
  •  
  •  

Submit A Resource

Have you created a useful tutorial, library or tool for iOS development that you would like to get in front of our 300,000+ monthly page views from iOS developers?

You can submit the url here.

The resources we feel will appeal to our readers the most will be posted on the front page.

Comments