airbnb / lottie-android

Render After Effects animations natively on Android and iOS, Web, and React Native
http://airbnb.io/lottie/
Apache License 2.0
34.95k stars 5.4k forks source link

Don't export Logger #2447

Closed pm-nchain closed 6 months ago

pm-nchain commented 8 months ago

Would it be possible to not expose Logger class, so it's not visible to library consumers?

Like making it internal in kotlin?

gpeal commented 8 months ago

Unfortunately not because it's Java. You can exclude it from being suggested as an import in your IDE though.

https://www.jetbrains.com/guide/go/tips/exclude-from-imports-and-completion/

gpeal commented 6 months ago

Actually, I'll reopen this to rename it.

gpeal commented 6 months ago

Actually, Logger.setInstance is a public API and renaming it would break consumers. I agree that the naming here is not ideal and I would change it if I could do it again. As a result, telling Android Studio to exclude it from auto-import would be the ideal solution here.