Modern Dependency Management With Version Catalogs - Android Studio Tutorial 💻

preview_player
Показать описание
In this video I will show you an Android Studio Tutorial about Modern Dependency Management With Version Catalogs!

💻 Let me be your mentor and become an industry-ready Android developer in 10 weeks:

⭐ Courses with real-life practices
⭐ Save countless hours of time
⭐ 100% money back guarantee for 30 days
⭐ Become a professional Android developer now:

Get my FREE PDF about 20 things you should never do in Jetpack Compose:

Join my Discord server:
Рекомендации по теме
Комментарии
Автор

So a tip I figured out by trial and error: My recommendation is to always add -"core" to to artifact ids like 'androidx.compose.ui:ui' that have a package name that will be part of other imports. That way auto complete plays nicely and it actually improves the wizard tooltip accuracy when you do that by allowing you to click "androidx.compose.ui.core" in your gradle files and it properly auto click through to the correct dependency. This works so nicely since Import Names and even Version Names don't have to 1:1 match the artifact IDs, and you can use "-base", or any other suffix you like to make it that auto-complete works nicely all the time, etc.

righteouscoder
Автор

You can also have a bundles section, where you set up way add multiple dependencies will a single line. It's very handy for things you always use together. Like all the compose dependencies.

johngray
Автор

You're the best, Native developer!!!

Otabekuz
Автор

Ah! This is great. Been working on the same big project for a while, so when i created a new project in Jellyfish for a small app this morning and went to add dependencies, the first reaction seeing the libs system was "WTF!?". Was tempted to revert back, but the OCD had won 😂

After it had taken me the best part of the morning to figure out the version catalog system on my own and add all my drpendencies manually, decided to migrate my big project... for which this video was, as usual, A GODSEND!

Seriously, you're a lifesaver ❤

annaberkovitch
Автор

In addition to your content I'm also making use of "bundles" there. For example all the compose dependencies could be bundle together and instead of 4 implementation you only got 1 left in your gradle file. But that's of course an indivuall preference 🙂

Narazgul
Автор

Will you make a video combining versionCatalog with buildSrc ?

romanosp
Автор

Now I'm using Android Studio Koala and it already appled the version catalogs for the library dependencies. Thanks for your information 6 months ago :)

嘿嘿嘿-zv
Автор

I hope to see a new video about buildSrc module that supports this toml file

abada-s
Автор

this was helpful i was watching an old tutorial on app development that was released on 2021 and i was confused as to why my dependency lines were red while his was fine XD

readysetgo
Автор

Another nice feature is that you can create "bundles". So say that you have related dependencies like compose for instance, then you can create a bundle of these. You can then in you app gradle file just refer to for instance.

dahlola
Автор

This is nice and definitely makes it easier to manage dependencies for large projects. When I look at build scripts that use version catalogs, I just find it a bit hard to build a mental model of dependencies. Before version catalogs, it was easier on the eyes to figure out what "groups" we are using in our application.

vighnesh
Автор

Great Video Philipp.

Rant:-

IDE support for this is worse, why don't Android Studio, just create a simple GUI interface, which makes it easier.

Upgrading is mess, unused libraries in version catalogue is a mess.

I don't like the new way of doing things, it's like we are intentionally making it difficult to import libraries, but as long as we get paid, eh.

Pulkit__
Автор

They are just increasing complexity, adding dependency is much easier in other frameworks, this is the thing which i don't like about android.

itssinghankit
Автор

this is very helpful for me . for this i can use string dependencies to library dependencies.
thank you .

dhimanpaul
Автор

It would be nice to mention about bundle in version catalog. And it would be pretty convenient if version catalog has opportunity to define groups like versions )))

McMouse
Автор

Nice to see this is being done. Sad that I did this all manually and now I have to unwind it. :)

robertfontaine
Автор

thanks for this video. this tutorial helped me a lot upgrading my gradle from to old and I now understand toml very well. thanks again bro

tasnimulhasan
Автор

Great video, Philipp!
Is it possible to use the versions catalog and group dependencies like you did in the video "Perfect Dependency Management"? I mean, call room() and add all the dependendencies related to it.

tarsilacostalonga
Автор

How about Version Catalogue vs Gradle Kotlin DSL comparation?

argahutama
Автор

will you update multi-module course with version catalogs instead buildSrc ??

mohancena