attempt at creating proper abstraction for re-usable view components across different contexts
Overrideequals
when in RecyclerView and diff is used to detect if contents are the same
- if wrapping happens, then diff must use a different logic, to check viewType properly and then id, currently class is compared directly
- distinct viewType for a wrapping chain
Padding Margin Item
andMargin Padding Item
are not the samePadding Margin Item
andPadding Item
are not the same - uniqueness of generated viewType combined with reliable generator that can be proven and does not rely on some randomness of hashcode
- adding background would require modification of existing components, so delegation
- for single file - refactoring, for example cleaning