Giter Club home page Giter Club logo

patilshreyas / notykt Goto Github PK

View Code? Open in Web Editor NEW
1.7K 23.0 236.0 4.54 MB

📒 NotyKT is a complete 💎Kotlin-stack (Backend + Android) 📱 application built to demonstrate the use of Modern development tools with best practices implementation🦸.

Home Page: https://patilshreyas.github.io/NotyKT/

License: Apache License 2.0

Kotlin 99.99% Procfile 0.01%
kotlin ktor backend api rest-api android coroutines testing mvvm-android mvvm-architecture

notykt's Introduction

NotyKT 🖊️

Build (API) Build (Android) Release

GitHub license Android Weekly ktlint

NotyKT is the complete Kotlin-stack note taking 🖊️ application 📱 built to demonstrate a use of Kotlin programming language in server-side and Modern Android development tools. Dedicated to all Android Developers with ❤️.

You can Install and test latest NotyKT Android app from below 👇

Noty Simple App Noty Compose App

📄 Project Documentation

Visit the documentation of this project to get more information in detail.

💡 About the Project

This project includes two subprojects:

This is a REST API built using Ktor Framework deployed on Heroku.
Navigate to /noty-api directory to browse and know more about Noty API project.

This is an Android application which uses Noty REST API. It has application UI implementation using traditional Android's Navigation Architecture as well as modern Jetpack 🚀 Compose UI.
Navigate to /noty-android directory to browse and know more about Noty Android project.

Want to Contribute 🙋‍♂️?

Awesome! If you want to contribute to this project, you're always welcome! See Contributing Guidelines. You can also take a look at NotyKT's Project Status Tracker for getting more information about current or upcoming tasks.

Want to discuss? 💬

Have any questions, doubts or want to present your opinions, views? You're always welcome. You can start discussions.

Contributors

See our rockstar contributors 😄

NotyKT Contributors

The beautiful UI of the application has been designed and developed by Spikey Sanju

License

Copyright 2020 Shreyas Patil

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.

notykt's People

Contributors

actions-user avatar ch8n avatar dependabot[bot] avatar fossabot avatar iamanbansal avatar kasem-sm avatar lightninggem avatar mrfamouskk7 avatar patilshreyas avatar pranaypatel512 avatar raghavawasthi avatar rivuchk avatar sairajphonepe avatar spikeysanju avatar varsha-kulkarni avatar yogeshpaliyal avatar zsmb13 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

notykt's Issues

[JetpackCompose] Improvements for Jetpack Compose App

  • [#117-1] Clear back stack after successful login/signup (Issue: When back navigation is pressed from Notes Screen, it tries to go back for sign in). [Fixed by #135]
  • [#117-2] Add transitions while navigating among different screens (As present in simple app module).
  • [#117-3] Add About screen for details regarding app (As present in simple app module). [Fixed by #135]
  • [#117-4] Validate text fields before performing actions with ViewModel. [Fixed by #135]
  • [#117-5] Create re-usable Composable components to reduce repetitive code.

About section for the app

Currently, on the main screen (notes list), we have a menu which has "About". But it does nothing on click of the menu. Need to add AboutFragment which will have App details.

About screen can contain details as below:

  • App logo
  • App name
  • App version
  • GitHub URL

Add offline capability for the application

If the internet is unavailable, then save notes data locally and when connectivity is back then process the changes.

For e.g.

When the note is updated and if the internet is off then save change locally and process this change on the network once internet connectivity is back.

Use SwipeRefreshLayout in NotesFragment

  • Use SwipeRefreshLayout in NotesFragment for refreshing notes on demand.
  • We can also look on a case where notes should get automatically refreshed when the note is deleted/updated or new note is added.

Optimize APK size

Currently, we don't have an optimized size of the application since we didn't shrink resources neither enabled proguard. It'll be good to have ProGuard enabled.

Add menu for sharing note as Image

Currently, we can share a note as text to external media. The feature request is to add a submenu where we will also be able to share a note as Image.

Getting error while sync Dagger2 dependency in Ktor

Dagger not installed properly, getting error

  • What went wrong:
    Execution failed for task ':kaptGenerateStubsKotlin'.

Could not resolve all files for configuration ':kapt'.
Could not resolve com.google.devtools.ksp:symbol-processing-api:1.5.20-1.0.0-beta03.
Required by:
project : > com.google.dagger:dagger-compiler:2.38.1 > com.google.dagger:dagger-spi:2.38.1
> Could not resolve com.google.devtools.ksp:symbol-processing-api:1.5.20-1.0.0-beta03.
> Could not get resource 'https://kotlin.bintray.com/ktor/com/google/devtools/ksp/symbol-processing-api/1.5.20-1.0.0-beta03/symbol-processing-api-1.5.20-1.0.0-beta03.pom'.
> Could not GET 'https://kotlin.bintray.com/ktor/com/google/devtools/ksp/symbol-processing-api/1.5.20-1.0.0-beta03/symbol-processing-api-1.5.20-1.0.0-beta03.pom'. Received status code 403 from server: Forbidden

And below my build.gradle

buildscript {
    repositories {
        jcenter()
    }
    
    dependencies {
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
    }
}

apply plugin: 'kotlin'
apply plugin: 'kotlin-kapt'
apply plugin: 'application'

group 'com.learn_ktor'
version '0.0.1'
mainClassName = "io.ktor.server.netty.EngineMain"

sourceSets {
    main.kotlin.srcDirs = main.java.srcDirs = ['src']
    test.kotlin.srcDirs = test.java.srcDirs = ['test']
    main.resources.srcDirs = ['resources']
    test.resources.srcDirs = ['testresources']
}

repositories {
    mavenLocal()
    jcenter()
    maven { url 'https://kotlin.bintray.com/ktor' }
}

dependencies {
    implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
    implementation "io.ktor:ktor-server-netty:$ktor_version"
    implementation "ch.qos.logback:logback-classic:$logback_version"
    implementation "io.ktor:ktor-server-core:$ktor_version"
    implementation "io.ktor:ktor-locations:$ktor_version"
    implementation "io.ktor:ktor-server-host-common:$ktor_version"
    implementation "io.ktor:ktor-auth:$ktor_version"
    implementation "io.ktor:ktor-auth-jwt:$ktor_version"
    implementation "io.ktor:ktor-gson:$ktor_version"
    testImplementation "io.ktor:ktor-server-tests:$ktor_version"

    // Exposed
    implementation "org.jetbrains.exposed:exposed-core:$exposed_version"
    implementation "org.jetbrains.exposed:exposed-dao:$exposed_version"
    implementation "org.jetbrains.exposed:exposed-jdbc:$exposed_version"
    implementation "org.jetbrains.exposed:exposed-jodatime:$exposed_version"

    // PostgreSQL
    implementation "org.postgresql:postgresql:$postgres_version"

    // Dagger
    implementation "com.google.dagger:dagger:$dagger_version"
    kapt "com.google.dagger:dagger-compiler:$dagger_version"
}


ktor_version=1.6.3
kotlin.code.style=official
kotlin_version=1.5.21
logback_version=1.2.5


exposed_version=0.33.1
hikari_version = 4.0.3
postgres_version=42.2.23.jre7
dagger_version = 2.38.1

Create release workflow

  • When tags are pushed, CI workflow should be triggered, APK should be generated.
  • Generated APK should be automatically attached as a release artifact.

Room database injection - Dagger hilt

Here, room database is provided through dagger hilt as a singleton in the Application component, so I think it is not required to have the singleton pattern as hilt would ensure that room database instance is a singleton.

So it would be better to build the database in DatabaseModule itself.

    @Singleton
    @Provides
    fun provideDatabase(
        @ApplicationContext context: Context
    ) = Room.databaseBuilder(
        context.applicationContext,
        NotyDatabase::class.java,
        DB_NAME
    ).addMigrations(*DatabaseMigrations.MIGRATIONS).build()

Add documentation for repository/project

  • Add documentation for info about the project/repository.
  • Add documentation for setting up the project locally.

Documentation Site (TBD)

This is a proposed idea for setting up a documentation site for this project where everything used in the project should be explained in the detail.
We can use docsify to set it up.

Setup CodeCov for test coverage

  • Setup CodeCov tool for measuring code coverage of the Noty Android application and API service.
  • Not important at all. Still, we can consider this at then end.
  • Currently blocked due to #15

Update release workflow to publish 'Release APK' instead of Debug

The motive behind this change is currently when tags are pushed then debug APK is generated and uploaded as a release artifact. We have also implemented LeakCanary library for debug mode. So app users are getting unnecessary notifications of LeakCanary which is bad experience :(. To avoid this, we should update release Actions workflow to upload only release APK which won't include LeakCanary.

[composeapp] Improve UI for input fields of Note

In compose app variant, UI for input fields is not looking good and not in sync with the simple app as well. Make input fields of title and note body simple instead of using material component

Can't add more than 1 note

Hello, when i add a note, i'm redirected to the main notes fragment, and when i click on the Add FAB, the app navigate to the AddNoteFragment and instantly navigate back to the NotesFragment, because in the AddNoteViewModel, the viewState variable is not reset when a new note is created and if we navigate in AddNoteFragment it will re-observe the Success state of the viewState and navigate back

Test cases for Android application components

  • Add Unit tests for modules data, repository, app etc.
  • Add some integrations tests for Android.
  • We can use libraries like Kotest, Mockk, etc for testing which are completely Kotlin libraries.

Handle No-Connectivity State

  • Show error dialog in Sign In/Sign up fragments
  • Show small info in Notes fragment
  • Show error when tried to add/update/delete note.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.