簡介
我們往往會使用列表組件(UITableView or UICollectionView) 來展示App內(nèi)容。但是,這些組件在數(shù)據(jù)為空的時候有可能會出現(xiàn)空白頁,特別當(dāng)新賬號用戶,網(wǎng)絡(luò)異?;蛘逜pp出現(xiàn)bug。為了讓用戶清楚了解空白頁的原因,開發(fā)者很有必要對那些常由異常造成的空白頁,給出溫馨提示和引導(dǎo)視圖。
安裝
- Add
pod 'TBScrollViewEmpty'to your Podfile. - Run
pod installorpod update. #import <TBScrollViewEmpty.h>
特性
- 自動化: 自動添加或移除提示視圖.
- 結(jié)構(gòu): 該框架可以使你快速自定義視圖.
- 網(wǎng)絡(luò): 監(jiān)聽網(wǎng)絡(luò)狀態(tài)變化.
- NSAttributedString: 使用NSAttributedString可以更加快速建立視圖表達(dá).
Demo

如何用
-
#import <TBScrollViewEmpty.h>,框架會在數(shù)據(jù)為空的時候自動幫添加或者移除提示視圖。 - 你無須遵循本框架的代理,除非你需要自定義視圖開發(fā)。
授權(quán)
TBScrollViewEmpty完全公開源代碼給開發(fā)者使用。
使用TBScrollViewEmpty應(yīng)遵守MIT協(xié)議. 詳情見協(xié)議文件。
Company and Organization
@Shanghai,HC???@Shanghai,HK???@Shanghai,SW
Github和源碼
英文
What
Typically we use list component (UITableView or UICollectionView) to show App content. However, these components may display blank when the data is empty, specially for new users with accounts, the network is not reachable or something wrong with our app. To let the users konw what is going on when the blank page comes out, it’s necessary for empty states to be dealt with by developers as blank pages often caused by exceptions.
Installation
- Add
pod 'TBScrollViewEmpty'to your Podfile. - Run
pod installorpod update. #import <TBScrollViewEmpty.h>
Feature
- Automatic: Automatically add or remove the tip view.
- Structure: This framework allows you customized development easily.
-
Network:
Monitor the status of network. - NSAttributedString: Uses NSAttributedString for easier appearance customisation.
Demo

How to use
-
#import <TBScrollViewEmpty.h>, then this framework will show standard emptyView automatically when the data is empty. - You don't even need to conform to delegate, unless you want to customize development.
License
TBScrollViewEmpty is provided under the MIT license. See LICENSE file for details.
Company and Organization
@Shanghai,HC???@Shanghai,HK???@Shanghai,SW