To run the example project, clone the repo, and run pod install
from the Example directory first.
Xcode 9.2 , Swift 4
Helper4Swift is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'Helper4Swift'
- String Extension
- Array Extension
- UIButton Extension
- UILabel Extension
- UIDevice Extension
- UITextField Extension
- UIView Extension
- UIImageView Extension
- UIColor Extension
- fetchGenericData method
// fetching json data by passing the struct/class model and the url
- getCurrentDate method
// return the current date in different format
- getCurrentDateWithThisFormat method
// return the current date with specific format
- formatThisNumber method
// takes string numbers (e.g Arabic numbers) and return string english numbers
- shakePhone method
// all kinds of UIImpactFeedbackGenerator .light .medium etc..
- disabledForSome method
// take control of what to show/hide for specific iOS devices
- toolBar method
// adding toolbar to a textField
- showBasicAlert method
// showing basic alert with title and message and OK button to dissmiss
- isValidEmail
// return true if the email match the regular expression (helful when adding sign up page)
- isValidNumber
// return true if the number match the regular expression
- isValidPassword
// return true if the string has minimum 8 characters, and at least one uppercase letter, and one lowercase letter and one number
- isValidUrl
// return true if string is valid Url
- removeWhitespace method
// removing the white space form string
- replaceString
// Replacing string by another string
- shuffle method
// returns an array containing this sequence shuffled
- applyButtonDesign method
// adding a shadow and other design
- setLineSpacing method
// adding a space between the lines
- modelName
// determines the current iOS device model
- addUnderlineDesign method
// adding underline Design to UITextField
- addVerticalGradientLayer method
// adds a vertical gradient layer with two UIColors to the UIView
- applyViewDesign method
// like drop a shadow to the UIView
- downloadedFrom method
// downloads an image asynchronously from the web using URLSession
- colorFromHexString method
// return UIColor from a given hex string color
Abdullah Alhaider,
cs.alhaider@gmail.com
Twitter
Helper4Swift is available under the MIT license. See the LICENSE file for more info.