hsaini.bsky.social
@hsaini.bsky.social
Reposted
New blog post! If you are a Kotlin or Java Android developer, this one should make you go 🤯.

www.romainguy.dev/posts/2024/n...

I'm not even sorry.
Naming is Hard
Before we dive into today’s topic, I would like to make it clear that what follows is specific to how Android, and more precisely the Android RunTime (ART), works. Some of what follows applies to othe...
www.romainguy.dev
December 20, 2024 at 12:57 AM
Reposted
🤔 Finding KMP libraries feels like a chore?

Introducing klibs.io – a web service that simplifies your search for KMP libraries that are right for your needs and platforms.

Try this alpha version and share your thoughts! 🌟

Learn more: 👇
blog.jetbrains.com/kotlin/2024/...
Introducing klibs.io: A New Way to Discover Kotlin Multiplatform Libraries | The Kotlin Blog
Klibs.io is an easy web service that allows you to find a Kotlin Multiplatform library for a specific purpose that supports selected platforms (JVM, Android JVM, Wasm, JS, Kotlin/Native).
blog.jetbrains.com
December 18, 2024 at 8:01 AM
Reposted
Benchmarking can be tricky! In this blog post, I show an example of how easy it is to get the wrong results and how to fix it: www.romainguy.dev/posts/2024/y...
You Are Going to Need It
Optimizing code can be a difficult task because there are so many traps you need to avoid at every step of the way. Today I want to focus on one of the (numerous) benchmarking traps, which you may hav...
www.romainguy.dev
December 13, 2024 at 6:30 PM
Reposted
Android XR was unveiled today! You can download the preview SDK today and start using the Compose and Material Design APIs. I'm also excited that Filament (github.com/google/filam...) powers the experience.

developer.android.com/develop/xr
Android XR  |  Android Developers
Android XR (Extended Reality) device development hub
developer.android.com
December 12, 2024 at 4:47 PM
Reposted
Are you terrified about your #Android app getting compromised through a build supply chain attack? (you likely should be!)

I wrote a post on how to enable signature verification of your Gradle dependencies to make that a lot harder for the threat actors

www.liutikas.net/2024/12/12/T...

#gradle
Trust But Verify - Enabling Gradle Signature Verification for An Android Project
In my post on Gradle Security Considerations I suggested enabling Gradle dependency signature verification. It is an important practice given today’s landsca...
www.liutikas.net
December 12, 2024 at 8:33 PM
Reposted
Happy Holidays! As the last set of #JetpackReleaseNotes for the year, please enjoy ViewPager 1.1.0 and many crash fixes across Compose 1.7.6, Navigation 2.8.5, Paging 3.3.5, and Camera 1.4.1.
developer.android.com/jetpack/andr...
Recent Release Notes  |  Android Developers
developer.android.com
December 11, 2024 at 7:05 PM
Reposted
Haze 1.1 💠 has been released!

The main change is the new 'Input Scale' parameter, which allows you to set an optional (down)scaling mode. This should have a positive effect on performance when enabled.

github.com/chrisbanes/h...
December 3, 2024 at 8:27 PM
Reposted
Let's look at Bluesky performance on Android!

I managed to build a release build of the app and ran some traces, let's see what we can find...

I have ~hour, will add to this thread as I investigate
November 19, 2024 at 1:31 AM
Reposted
ViewModel APIs cheat sheet

developer.android.com/topic/librar...
November 29, 2024 at 12:11 PM
Reposted
We could go on about how we welcome publishers, we don't demote links, we encourage independent developers to build apps and extensions on top of Bluesky's network.... but instead, we'll show you.

All thanks to the incredible community here! 🦋
The Engagement Is Better on Bluesky - Bluesky
Bluesky is the lobby to the open web. Find and build your community here.
bsky.social
November 29, 2024 at 10:30 PM
Reposted
Benchmarking Koin vs. Dagger Hilt in Modern Android Development (2024) proandroiddev.com/benchmarking...
Benchmarking Koin vs. Dagger Hilt in Modern Android Development (2024)
How Koin scales and performs compared to Hilt, using practical benchmarks and insights.
proandroiddev.com
November 27, 2024 at 8:23 AM
Reposted
Did you know that the "strong skipping mode" in #jetpackcompose can make your applications more efficient? 🚀

With the arrival of 1.7.0, strong skipping mode has become the standard, bringing significant improvements in handling recompositions. What does this change really mean for us as developers?
November 27, 2024 at 12:30 PM
Reposted
Pretty incredible how Bluesky does two things no other major social network does:

1. Show content from people you follow

2. Don’t deprioritize posts with links

The “incredible” part is how ads-driven social networks & ones optimizing for “engagement” stopped doing either.
We want Bluesky to be a great home for journalists, publishers, and creators. Unlike other platforms, we don't de-promote your links. Post all the links you want — Bluesky is a lobby to the open web.
Traffic from Bluesky's @bsky.app to @theguardian.com is already 2x that of Threads

In its first week on the platform & with 300k followers, Bluesky traffic from @theguardian.com posts is already higher than it was from TwX in any week in 2024, where the account had 10.8m followers, but🧵
November 27, 2024 at 3:18 PM
Reposted
Surround yourself with capable humans who work hard to lift each other up.
November 26, 2024 at 11:37 PM
Reposted
Instead of giving people better opportunities to skill up and earn a living, we spun up digital casinos and helped them place their bets.
November 27, 2024 at 7:48 PM
Reposted
Benchmarking is hard!

This is a great example, let's dive into the diff to highlight what I'd typically surface if someone shared this benchmark at Square.

The diff: github.com/android/nowi...

(it's great that Arnaud shared the diff btw, too often benchmark authors don't)

#AndroidDev
I am trying the delicate experiment to benchmark #Koin #Kotlin framework with the Now in Android app, having real-world usage measurements: proandroiddev.com/benchmarking...
Sorry for flaming the internet again 😅 Feedback is welcome to help make this experiment process better 🙏
Benchmarking Koin vs. Dagger Hilt in Modern Android Development (2024)
How Koin scales and performs compared to Hilt, using practical benchmarks and insights.
proandroiddev.com
November 27, 2024 at 3:53 PM
Reposted
Get rich slow by investing in yourself.
November 27, 2024 at 8:29 PM
Reposted
I wrote a blog post that's really just an excuse to trick you into watching @worrydream.com's Inventing on Principle talk
The pursuit of fast feedback loops in Android development
There's something magical about having a direct connection to what we're building
saket.me
November 27, 2024 at 7:09 PM
Reposted
Ever wanted to make a stacked list of avatars or a fading edge effect in #JetpackCompose? 🤔

Check out the latest #ComposeTips to learn all about how a few tricks with BlendModes can help you get the UI you are looking for 👀

youtu.be/rdS4A2YFBHA?...
Clipping and masking | Jetpack Compose Tips
YouTube video by Android Developers
youtu.be
November 27, 2024 at 9:43 PM
Reposted
Kotlin 2.1 is out!
kotlinlang.org/docs/whatsne...

I'm excited about better dollar substitution in raw strings! In lint's test DSL there's a workaround for it. Look at the screenshot -- unescaped $'s? But how? If you look carefully, it's a lookalike!
cs.android.com/search?q=%22...
November 27, 2024 at 8:37 PM
Reposted
PSA: if you write v.pow(2f) (also .pow(3f)) on Android, please write v * v instead. pow() is a (relatively) expensive function call that won't get optimized away (yet). On a Pixel 6, pow(2f) is 5x slower than a multiplication. For long expressions, use inline fun square(v: Float) = v * v
November 27, 2024 at 10:22 PM
Reposted
My own pet peeve is when folks use `?.let {} ?:` instead of if/else when checking null

It's less readable, and more error prone (because if "doThing()" accidentally returns null, then you end up running the ?: branch, which often is not what you actually want.
November 27, 2024 at 6:35 PM
Reposted
I love Kotlin but please don't abuse its features. I regularly see code like in the first function when you can instead write a simple if statement: it's shorter, easier to read, and doesn't allocate an object!

Thankfully both functions compile to the same assembly when R8 is turned on.
November 27, 2024 at 6:20 PM