WSTagsField alternatives and similar libraries
Based on the "Tag" category.
Alternatively, view WSTagsField alternatives based on common mentions on social networks and blogs.
-
TTGTagCollectionView
Useful for showing text or custom view tags in a vertical or horizontal scrollable view and support Autolayout at the same time. It is highly customizable that most features of the text tag can be configured. 标签流显示控件,同时支持文字或自定义View -
RKTagsView
Highly customizable iOS tags view [input, edit, dynamic, tag, token, field, NSTokenField] -
PARTagPicker
This pod provides a view controller for choosing and creating tags in the style of wordpress or tumblr. -
TagCellLayout
Made in Swift - Tag layout for UICollectionView supporting 3 types of alignments - Left || Centre || Right
CodeRabbit: AI Code Reviews for Developers

* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of WSTagsField or a related project?
README
WSTagsField
An iOS text field that represents tags, hashtags, tokens in general.
Usage
let tagsField = WSTagsField()
tagsField.layoutMargins = UIEdgeInsets(top: 2, left: 6, bottom: 2, right: 6)
tagsField.contentInset = UIEdgeInsets(top: 10, left: 10, bottom: 10, right: 10)
tagsField.spaceBetweenLines = 5.0
tagsField.spaceBetweenTags = 10.0
tagsField.font = .systemFont(ofSize: 12.0)
tagsField.backgroundColor = .white
tagsField.tintColor = .green
tagsField.textColor = .black
tagsField.fieldTextColor = .blue
tagsField.selectedColor = .black
tagsField.selectedTextColor = .red
tagsField.delimiter = ","
tagsField.isDelimiterVisible = true
tagsField.placeholderColor = .green
tagsField.placeholderAlwaysVisible = true
tagsField.keyboardAppearance = .dark
tagsField.returnKeyType = .next
tagsField.acceptTagOption = .space
tagsField.shouldTokenizeAfterResigningFirstResponder = true
// Events
tagsField.onDidAddTag = { field, tag in
print("DidAddTag", tag.text)
}
tagsField.onDidRemoveTag = { field, tag in
print("DidRemoveTag", tag.text)
}
tagsField.onDidChangeText = { _, text in
print("DidChangeText")
}
tagsField.onDidChangeHeightTo = { _, height in
print("HeightTo", height)
}
tagsField.onValidateTag = { tag, tags in
// custom validations, called before tag is added to tags list
return tag.text != "#" && !tags.contains(where: { $0.text.uppercased() == tag.text.uppercased() })
}
print("List of Tags Strings:", tagsField.tags.map({$0.text}))
Installation
Carthage
To install it, simply add the following line to your Cartfile:
github "whitesmith/WSTagsField"
Then run carthage update
.
Follow the current instructions in Carthage's README for up to date installation instructions.
CocoaPods
To install it, simply add the following line to your Podfile:
pod "WSTagsField"
Then run pod install
with CocoaPods 1.8.0 or newer.
Swift Package Manager
Using Xcode 11, just go to "File" > "Swift Packages" > "Add Package Dependency..." and use this repository: https://github.com/whitesmith/WSTagsField
.
Manually
Download all the source files and drop them into your project.
Requirements
- iOS 9.0+
- Xcode 11 (Swift 5.1)
Contributing
The best way to contribute is by submitting a pull request. We'll do our best to respond to your patch as soon as possible. You can also submit a new GitHub issue if you find bugs or have questions. :octocat:
Credits
This project was inspired by CLTokenInputView.
*Note that all licence references and agreements mentioned in the WSTagsField README section above
are relevant to that project's source code only.