CenteredCollectionView
是一个轻量级的、可直接使用的 UICollectionViewFlowLayout
,它可以分页并保持单元格居中,从而产生“轮播效果” 🎡
使用 CocoaPods 尝试示例
pod try CenteredCollectionView
此 Pod 需要 iOS 9.0 或更高的部署目标
CenteredCollectionView 可以通过 Swift Package Manager, CocoaPods 和 Carthage 安装。
要使用 Swift Package Manager 安装,请在 Xcode 的 Add Package Dependency 助手中添加 URL https://github.com/BenEmdon/CenteredCollectionView
;或者添加到您自己的 Package.swift
中
dependencies: [
.package(url: "https://github.com/BenEmdon/CenteredCollectionView", from: "2.2.2")
]
要使用 Cocoapods 安装,请将以下行添加到您的 Podfile
中
pod "CenteredCollectionView"
要使用 Carthage 安装,请将以下行添加到您的 Cartfile
中
github "BenEmdon/CenteredCollectionView"
请查看 USAGE.md
请查看 API.md
有任何建议?欢迎所有贡献!
如果您提交 pull request 或 issue,您很可能会得到迅速的响应!
CenteredCollectionView 根据 MIT 许可证提供。 有关更多信息,请参见 LICENSE 文件。