diff --git a/README.md b/README.md index b94342c..5fe6579 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,66 @@ -# WanLearning -Kotlin 实战项目练习 +# WanLearning-Kotlin 实战项目 +「**WanLearning App**」基于 Material Design 风格构建的 **玩 Android** 客户端,主要是为了适应Kotlin语言开发流程。 + + + +### 主要特点 + +- 基于Google官方宣贯的MVVM模式开发实践 +- 基于Jetpack组件库构建:LiveData、ViewModel、Lifecycle、Room、DataBinding,目前项目中只是集成的Paging组件,暂未用到 +- 使用Kotlin语言开发,自定义扩展函数,代码简洁 +- 使用协程来构建网络请求,链式调用,方便调试 +- 工程模式以单Activity + 多Fragment架构编写,容易做单元测试和好扩展维护,提升开发效率 + + + +### 架构图 + +![架构组件](images/final-architecture.png) + + + +### 效果图 + +![Demo](images/demo_maker.gif) + +### 更新记录 + +V1.0.0 + +- 第一个版本,包括首页、公众号、项目、导航、我的5个Tab项页面功能 +- 支持协程方式获取网络请求数据,LiveData来更新UI +- 支持登陆和注册功能、支持自定义切换主题颜色、支持加载Web Url + + + +### 感谢 + +- 数据来源:[玩 Android](https://www.wanandroid.com/blog/show/2) + +- [UnPeek-LiveData](https://github.com/KunMinX/UnPeek-LiveData)事件通知 +- [LoadSir](https://github.com/KingJA/LoadSir) 加载反馈 +- [Retrofit](https://github.com/square/retrofit) 网络请求框架封装 +- [Glide](https://github.com/bumptech/glide) 图片加载 +- [OkHttp](https://github.com/square/okhttp) 网络请求 +- [Gson](https://github.com/google/gson) Gson 解析 +- [Permissionx](https://github.com/guolindev/PermissionX) 动态请求权限封装 +- [SmartRefreshLayout](https://github.com/scwang90/SmartRefreshLayout) 下拉刷新框架 +- [VasSonic](https://github.com/Tencent/VasSonic) 提升H5首屏加载速度 + + + +### 给予支持💪 + +通过这个项目希望能够帮助大家更好地学习 Jetpack 与 MVVM 架构的结合。 + +如果你喜欢 WanLearning App 的工程项目,本项目的源代码对你的学习有所帮助,可以点右上角 **"Star"** 支持一下,谢谢! + + + +### 关于我 + +- 个人博客:http://cryallen.com/ +- 简书:https://www.jianshu.com/u/6f6f18ef43e5 +- Email: cr330326@126.com +- Wechat: cr330326 +- 公众号:![个人信息](images/me.jpeg) diff --git a/app/build.gradle b/app/build.gradle index 9ecd98f..df2a73c 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -17,23 +17,40 @@ android { testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" } + signingConfigs { + release { + storeFile file("keystore") + storePassword "330326" + keyPassword "330326" + keyAlias "key0" + } + } + buildTypes { debug { debuggable true jniDebuggable true minifyEnabled false shrinkResources false + signingConfig signingConfigs.release } release { debuggable false jniDebuggable false - minifyEnabled true - shrinkResources true + minifyEnabled false + shrinkResources false + signingConfig signingConfigs.release proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' } } + android.applicationVariants.all { variant -> + variant.outputs.all { + outputFileName = defaultConfig.applicationId + "_" + defaultConfig.versionName+"_release" + ".apk" + } + } + compileOptions { sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 diff --git a/app/keystore b/app/keystore new file mode 100644 index 0000000..0e92019 Binary files /dev/null and b/app/keystore differ diff --git a/app/release/com.cryallen.wanlearning_1.0.0_release.apk b/app/release/com.cryallen.wanlearning_1.0.0_release.apk new file mode 100644 index 0000000..49cc2ca Binary files /dev/null and b/app/release/com.cryallen.wanlearning_1.0.0_release.apk differ diff --git a/config.gradle b/config.gradle index e98d50a..f58e686 100644 --- a/config.gradle +++ b/config.gradle @@ -54,7 +54,7 @@ build_versions.target_sdk = 30 build_versions.compile_sdk = 30 build_versions.android_gradle_plugin = "7.0.2" build_versions.kotlin = '1.5.30' -build_versions.app_version_name = "0.0.1" +build_versions.app_version_name = "1.0.0" build_versions.app_version_code = 100 ext.build_versions = build_versions diff --git a/images/demo_maker.gif b/images/demo_maker.gif new file mode 100644 index 0000000..ef25bf5 Binary files /dev/null and b/images/demo_maker.gif differ diff --git a/images/final-architecture.png b/images/final-architecture.png new file mode 100644 index 0000000..0188f59 Binary files /dev/null and b/images/final-architecture.png differ diff --git a/images/me.jpeg b/images/me.jpeg new file mode 100644 index 0000000..0785d8b Binary files /dev/null and b/images/me.jpeg differ