Best android open-source packages and libraries.

Weather_compose_clean_architecture

This is sample app about Jetpack Compose, Clean Architecture, etc.
Updated 1 month ago

Weapose - Weather ❤️ Compose

This is an example for show current weather from any location. The Weapose is builted by Android Jetpack Compose, MVVM, Clean Architecture, etc.

🙆‍♀️ Firstly

This app is inspired by:

I want to say thanks for those people to help me to make this app.

🚧 In progress

I'm trying to implement Version Catalog for new Gradle's version but the Dependabot doesn't support it (seeing this).

You can check out from v1.0.4/version_catalog to see what I done.

🎉 Ready on Google Play

Now, you can download it on Google Play Store. Install it and give me your feedback!

"Get it on Google Play"

🔨 How to build app

  • Using the newest version of Android Studio Canary.

  • You must add BASE_URL, API_KEY and MAPS_API_KEY inside local.properties to build and run Weapose app, like the code below:

    BASE_URL=https://api.openweathermap.org/data/2.5/
    API_KEY=API_KEY // Fill your open weather api key in here
    MAPS_API_KEY=GOOGLE_MAPS_API_KEY // Fill your google maps api key in here

📷 Screenshots

Light mode Dark mode
Home Light Home Dark
Seven Days Light Seven Days Light
Search By Map Light Search By Map Dark
Drawer Light Drawer Dark
Search By Text Light Search By Text Dark

📘 Features

  • Show the current weather by location or name.
  • Show the seven days weather by location or name.
  • Choice the location you want by using Google Map.
  • Search location by address name by using Google Places.
  • Support dark mode.
  • Support dynamic material from Android 13 and above.
  • Support English and Vietnamese.
  • Upcomming ….

📂 Module

Weapose is built according to the Clean Architecture model combined with the MVVM design pattern. To learn more, refer to the links below.

  • Guild to app architecture by Google Android.
  • Clean architectur by Uncle Bob.

🔎 Unit test

  • Using MockK to write unit test.
  • Using Kotlin Reflection to access the private method, private property, etc.
  • Using Kotlin Kover to generate the test coverage. To generate, you just run command ./gradlew koverHtmlReport.

🚊 Data flow

Weapose is supported by Flow and suspend for data stream flow in app.

Data flow

❌ Error flow

In data module, when data is returned error, I will transform the error to ResponseException. And then in domain and presentation, I transform the error from ResponseException to WeatherException to show the error to UI.

Error flow

🔔 Notes

If you have any issues with the project, don't hesitate to create an issue. Also I'm glad you can contribute to my project.

Let's develop together to create quality and beautiful Android Jetpack Compose applications!

☕ Buy me a coffee

Welcome to my github! 👋

Don't forget to buy me a coffee so that I have more motivation to improve the project! 🔥

"Buy Me A Coffee"

License

Copyright 2022 The Android Open Source Project

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.