Do You Have to Learn Clean Architecture as a Beginner? - Android Development

Поделиться
HTML-код
  • Опубликовано: 21 авг 2024
  • In this video you will get the answer if you have to learn clean Architecture as a Beginner.
    💻 Let me be your mentor and become an industry-ready Android developer in 10 weeks:
    pl-coding.com/...
    ⭐ Courses with real-life practices
    ⭐ Save countless hours of time
    ⭐ 100% money back guarantee for 30 days
    ⭐ Become a professional Android developer now:
    pl-coding.com/...
    Get my FREE PDF about 20 things you should never do in Jetpack Compose:
    pl-coding.com/...
    Regular programming advice on my Instagram page: / _philipplackner_
    Join my Discord server:
    / discord

Комментарии • 41

  • @inememonday6815
    @inememonday6815 8 месяцев назад +15

    Learning Clean Architecture as a Beginner will make you see Android development as arduous because is for advanced App developers, do yourself good as a beginner to avoid it, until you are really good.

  • @ErikBongers
    @ErikBongers 20 дней назад +1

    I just spent a couple of weeks learning android compose. I do have prior experience with programming, including Java J2EE ages ago, but not in Kotlin.
    My idea was to start with a "full architecture example" as a scaffolding, a foundation. Unfortunately, that does not exist.
    I thought I'd found it, with the now-in-android example and accompanying video on recommended architecture, but alas, it was still a rollercoaster experience.
    For one, the github repo seems to be in constant maintenance....while the video is of course still the old one. Differences may be subtle to an experienced developer, but for a beginner - if the instructor says you should turn the key clockwise...and it doesn't work...well, you will likely try to turn it counterclockwise, and that may work - but you're a beginner - so you wonder if just set off an explosive side-effect. In any case, most of the time in android, it's not the direction of the key that has changed...the lock has been upgraded, that is - the key your well intending instructor (Philipp Lackner?) gave you...is deprecated.
    One of the first things you have to do when setting up your essentially empty project is your dependencies. They have version numbers. Loads of them. And your default project has completely different version numbers than all the tutorials and documentation and repos you can find. How to deal with that? Consult your religious leader for guidance.
    To be fair, version hell wasn't that bad, but mainly just intimidating. In most cases I was prompted with some messages like "Perhaps upgrade Kotlin or gradle to version...".
    What was definitely annoying is that your dependencies, and there are MANY of them, can not be added as described. For each lib, the android ref gives you a nice gradle build statement, and even a legacy statement. Unfortunately both formats are obsolete. It is now recommended to put dependencies in a versions file and only include symbolic links or aliases in the build files.
    You have to manually (21st century here) split the version strings up into, what was it again...symbolic aliases with a domain, a name, version id...then create a version variable...then add the alias in the gradle build file...
    Note that as a beginner, you have to first figure this out, and hope you got it correct! You don't want to know how long it took me to get @Parceable working.
    Then there's solutions for all the life-time coping you have to do. I understand the reasons - phones have limited resources. But there's lots of solutions. Most of them deprecated. Just look at all the stackoverflow examples that contradict each other - my goth, it's all over the place! I think I finally settled with StateFlows and SavedStateHandles, but the journey to figure out what is best. You are more likely to stumble onto obsolete information than recent information.
    I'll stop here, as I think you get the idea of my journey. I ended up with a scaffolding or foundation that is duck-taped and hot-glued together and that I want to surround with a yellow caution tape that says "Warning: do not approach or enter. This (new!) building is unstable and at risk of collapsing."
    My conclusion and recommendation to the android team is the following.
    Freeze big API releases for **multiple** years.
    Use the extra time you have to update the documentation, the videos and tutorials.
    LABEL (!) all the above with clear version labels.
    Have a scaffold project or two to get started - a minimal one and a full-architecture one.
    So, Philipp, your video is titled with a question: "Do you have to learn clean architecture as a beginner?"
    Well, I tried. I really tried.
    Perhaps let the Android team know how THEY can create a clean architecture. A stable one, well delineated and well documented.
    With my experience, starting with a C64, with a bit if assembly there, Amiga in C and C++, a first job with Win32, Java J2EE, C# .net WPF, web CMS, a bit of full stack stuff, WASM, a keen interest in language design and compilers and a frustratingly steep learning curve into Rust (although I do love it), the Android "getting started" experience is by far the worst. And the reason is that it clearly and easily could be much better. And that's a google management issue.

  • @SerarEstaifan
    @SerarEstaifan 8 месяцев назад +4

    Great video! I would like to see a video highlighting the best way to write UI/Unit tests (TDD) for clean architecture

  • @JacobArvizu
    @JacobArvizu 8 месяцев назад +1

    I love your point at the end! I hate when people play the snarky "It depends" or some similar variation of card. Whether they are trying to or not it just seems standoffish. We all know what the person, usually a beginner, is asking. They are just asking what are valid guidelines and principles I should stick to and can you give me advice. They aren't stupid, we don't need a lecture how clean code architecture or some other pattern isn't the word of god, yes we know. They just want to learn from someone with knowledge in the area, you don't need to turn it into a "well actuallly" rant.

  • @Jannis368
    @Jannis368 8 месяцев назад +8

    I started Android development with absolute garbage architecture (Screen = Activity and not even using ViewModels), but made pretty succesful and good looking apps with this. While I wish I actually used a proper architecture back then, it properly just would have overwhelmed me and I would have quitted. That beeing said, now we have much better ressources for learning android development (like this channel).

    • @port3-
      @port3- 8 месяцев назад

      Excellent point of view. I'm in the same boat.

  • @ramodsasanga6169
    @ramodsasanga6169 8 месяцев назад +3

    Thank you! We want a video about planning and system design of Android App.

  • @ubersticks
    @ubersticks 8 месяцев назад +2

    I think "Clean Architecture" is a gray scale and there are some aspects that are very simple to apply and make sense to learn in the beginning. Other aspects (such as use cases) often are a struggle to justify for simple projects. Using state hoisting instead of passing around NavHost, use of Repositories to insulate the ViewModel from implementation details of API/Database, uni-directional data flow with UiState and UiEvents -- these are examples of good practices that are not that complicated and are part of clean arch -- beginning projects should include them IMO.

  • @clamum9648
    @clamum9648 8 месяцев назад +1

    I gave Clean Architecture a shot when beginning to rewrite my app, cause I saw it in your tutorial videos, but I didn't care for it at all and ended up starting over without it (not just because of CA). I guess it might be good in extremely complex apps or specific apps, but I think for the most part it's overkill and makes things way more complex than they need to be.

  • @penelopeisgoingofftopic6786
    @penelopeisgoingofftopic6786 8 месяцев назад

    as a beginner CA has made my learning and developing experience better. personally i decided that i would make my apps with the assumption that they would become larger at some later stage or i might get the opportunity to sell it to some larger tech company and i even try to organise as if im part of a team with documentation, project-wide conventions and stuff like that.
    i usually setup my projects with data, domain, and presentation and i just like how whenever im working in one area, it becomes clearer what i expect to see especially when I haven't been coding for a while. i remember my earlier projects each being uniquely prganized and being frustrated about not understanding what I was trying to accomplish or why.

  • @events4089
    @events4089 8 месяцев назад +3

    Philip content is very quality

  • @UsmonWasTaken
    @UsmonWasTaken 8 месяцев назад +23

    CA is overrated in my opinion. I would rather create a function with 25 lines of code instead of separating it into 20 small functions :)

    • @rahulraj94391
      @rahulraj94391 8 месяцев назад

      Does this apply to small as well as very large project ?

    • @PhilippLackner
      @PhilippLackner  8 месяцев назад +16

      That wasn't the point of this video whether CA is overrated or not. But if you learn it, you'll be able to estimate when it's fine to keep these 25 lines and when it's better to not do that. That feeling for how an architecture should be for a specific app can't be taught in a single video

    • @joshflugel
      @joshflugel 8 месяцев назад +3

      Now let's discuss a scenarios where CA is NOT overrated: 1) you want to become a senior dev, 2) you want to bag a juicy job and the employer says they use and require CA experience.

    • @rahulraj94391
      @rahulraj94391 8 месяцев назад

      @@joshflugel 😁

    • @TravelVideos1234
      @TravelVideos1234 8 месяцев назад

      If you are working in a small team or small project, it will be easy to use a single layer architecture. If you are working in a multi team environment and want scalability and extensibility CA is a must. Plus if you want your code to be testable.

  • @ihatejune
    @ihatejune 8 месяцев назад +1

    Great video as always! I really wish you'd make a detailed video about MVI pattern, it seems to gather attention all around the community, especially with KMM gaining its popularity. Thanks in advance!

  • @JasonRicciardi081
    @JasonRicciardi081 Месяц назад

    It's not confusing when you think in terms of Low Coupling and High Cohesion or in general, minimize risk by separating the code base into minimalist projects that all work together but function separately as much as possible.

  • @mircodev
    @mircodev 8 месяцев назад

    This is a very popular question. In my opinion it is important to deal with clean architecture. But I think it's even more important to learn the basic principles. You mentioned SOLID. But I think clean code and the ability to write tests are at least as important. You should only get involved with architecture once you have the basics of reasonable coding. Until then, you will hopefully have an experienced developer at your side to support you. Architectural decisions always require a certain amount of experience.

  • @OrlanDroyd
    @OrlanDroyd 8 месяцев назад +1

    excellent video, I wish I had seen it when I was a junior 😅

  • @MobileMastersAndroidiOS
    @MobileMastersAndroidiOS 8 месяцев назад

    At my company, we have completed several projects using Clean Architecture, however, we find that MVVM is the most suitable architecture for our projects.

  • @ArthurKhazbs
    @ArthurKhazbs 8 месяцев назад +1

    And you did it again Philipp! WTF!! Reading my mind? :D

  • @akhileshmaurya3380
    @akhileshmaurya3380 3 месяца назад

    Hii philip , i am an android developer with 2 year of experience and i have just started working on clean architecture since last 4 months and really it is great but i am struggling to implement pagination 3 into this architecture can make a video on this. Please..

  • @Tuepp
    @Tuepp 8 месяцев назад

    Clean code matter a lot when having big software that is developed for many years... what nearly every software was I earned money with... it matters most when you are one of the first developers of such a project... unfortunately at the beginning where it matters most on a long run, the least time is often spent into architectural thoughts. Maybe because young companies, growing with the software do not have enough money to spend enough thoughts in clean code...

  • @riyupapa39
    @riyupapa39 8 месяцев назад

    The most import thing about "clean architecture" is every body can code same way. And clean architecture can make developers do that. So, I like clean architecture.

  • @Ayor88
    @Ayor88 4 месяца назад

    to make it simple: you have to learn the rules to know how to breaks them

  • @umardev500
    @umardev500 5 месяцев назад

    Clean arch is better implement on backend, on frontend better use atomic design

  • @j2shoes288
    @j2shoes288 7 месяцев назад

    it's good when you go for interviews ( you'll get the job ), since we are sheeple, but it's bollocks, basically, you're writing lots of boilerplate code, for no gains,

  • @hasnainahmad8295
    @hasnainahmad8295 7 месяцев назад

    Sir, should we use MVVM or Clean Architecture for Android?

  • @yogeshsahni5808
    @yogeshsahni5808 6 месяцев назад +1

    Note : Video is not for beginners

  • @ccmonkey1106
    @ccmonkey1106 8 месяцев назад

    Thanks for the video, Philipp. I'm trying to get the free PDF from the link. But the first button only refreshes the page and the second is redirecting somewhere else

  • @overfero
    @overfero 8 месяцев назад

    please make tutorial about assisted injection in viewmodel called in composable function

  • @wolfrudel7624
    @wolfrudel7624 6 месяцев назад

    Where can I find tbe turorial of the calory Tracker App course?

  • @redhotbits
    @redhotbits 6 месяцев назад

    clean architecture is for beginners only

  • @readmeandanswer8142
    @readmeandanswer8142 7 месяцев назад

    presentation, domain, data - this is not "clean architecture", this is just folders.
    There is no clean architecture, there is a specific architecture that is suitable for a particular task, but you need to study a lot, study OOP to understand when and why.

  • @SiamakAshrafi
    @SiamakAshrafi 8 месяцев назад

    No one will pay your for a hello world app. The faster you lear MVVM/MVI, clean Clean Arch, MAD (Hilt, Room, Compose [Material3]), CI/CD etc ... the better 🙂

  • @negaaa5080
    @negaaa5080 8 месяцев назад +1

    68th view