报错“Cannot access androidx.lifecycle.HasDefaultViewModelProviderFactory” 可正常运行
解决方法:
添加库:
implementation 'androidx.lifecycle:lifecycle-extensions:2.2.0'
implementation 'androidx.lifecycle:lifecycle-runtime:2.2.0'
或者更新androidx.appcompat:appcompat:
implementation 'androidx.appcompat:appcompat:1.3.0-alpha02'