Open Source Functional Programming Toolbelt For Swift Inspired By The Underscore.js Library

I’ve mentioned a few utility objective-c utility libraries inspired by Underscore.js most recently the Aterism library.

Here’s an open source library that provides a number of functional programming helper methods in the style of Underscore and Lo-Dash for those working with the new Swift programming language called Dollar $wift from Ankur Patel.

Here are few examples of Dollar.$swift in action from the readme:

$.first([1, 2, 3, 4]) as Double == 1

$.compact([3, nil, 4, 5]) as NSObject[] == [3, 4, 5]

$.initial([3, 4, 5], numElements: 2) as Int[] == [3]

$.last([3, 4, 5]) as Int == 5

You can find Dollar.$wift on the home page here.

A nice library for anyone working with Swift.

FacebookTwitterDiggStumbleUponGoogle Plus

Original article: Open Source Functional Programming Toolbelt For Swift Inspired By The Underscore.js Library

©2014 iOS App Dev Libraries, Controls, Tutorials, Examples and Tools. All Rights Reserved.

Leave a Reply

Your email address will not be published. Required fields are marked *