0
java.lang.LinkageError: com.facebook.litho.sections.widget.RecyclerCollectionComponent

使用 litho RecyclerCollectionComponent 时

RecyclerCollectionComponent component = RecyclerCollectionComponent.create(c).section(
                    section
            ).setRootAsync(false).disablePTR(true).build();
4

1 回答 1

0

浪费了几天后,我发现这是由于 litho 框架中的一个错误,我通过使用旧版本的 Litho 解决了它。

尝试使用

implementation 'com.facebook.litho:litho-core:0.12.0'
implementation 'com.facebook.litho:litho-widget:0.12.0'
compileOnly 'com.facebook.litho:litho-annotations:0.12.0'
annotationProcessor 'com.facebook.litho:litho-processor:0.12.0'
// Sections
implementation 'com.facebook.litho:litho-sections-core:0.12.0'
implementation 'com.facebook.litho:litho-sections-widget:0.12.0'
compileOnly 'com.facebook.litho:litho-sections-annotations:0.12.0'
annotationProcessor 'com.facebook.litho:litho-sections-processor:0.12.0'
// SoLoader
implementation 'com.facebook.soloader:soloader:0.2.0'
于 2021-10-20T05:56:27.740 回答