26. SubHeaderの差し込みがしんどい
/**
* Returns a [PagingData] containing each original element, with the passed header [item] added
* to the start of the list.
*
* The header [item] is added to a loaded page which marks the end of the data stream in the
* prepend direction by returning null in [PagingSource.LoadResult.Page.prevKey]. It will be
* removed if the first page in the list is dropped, which can happen in the case of loaded
* pages exceeding [PagedList.Config.maxSize].
*
* Note: This operation is not idempotent, calling it multiple times will continually add
* more headers to the start of the list, which can be useful if multiple header items are
* required.
*
* @see [insertFooterItem]
*/
@CheckResult
fun insertHeaderItem(item: T) = insertSeparators { before, _ ->
if (before == null) item else null
}
● Paging 3で解決する(かも?)
31. 1. Paging 3を使う
a. そもそもまだAlphaなので今すぐには難しい
b. 「ここまだめっちゃ途中なんだよねー」みたいなコメントアウトめっちゃある
Paging Libraryでのつらみを解消する方法
32. 1. Paging 3を使う
a. そもそもまだAlphaなので今すぐには難しい
b. 「ここまだめっちゃ途中なんだよねー」みたいなコメントアウトめっちゃある
2. Paging 2でも力技で使えなくはない
Paging Libraryでのつらみを解消する方法
33. 1. Paging 3を使う
a. そもそもまだAlphaなので今すぐには難しい
b. 「ここまだめっちゃ途中なんだよねー」みたいなコメントアウトめっちゃある
2. Paging 2でも力技で使えなくはない
a. だったらPaging Library使わずに(無理してライブラリに依存せずに)
実現すればよいのでは
b. Paging Libraryの利用を(無理してやるのは)やめたいお気持ち表明
Paging Libraryでのつらみを解消する方法