Giter Club home page Giter Club logo

supabase-kt's Introduction

supabase-kt

A Kotlin Multiplatform Client for Supabase.

For information about supported Kotlin targets, see the corresponding module README.

Migrating from version 1.4.X to 2.0.0

Note: WASM build available: 2.1.1-wasm0

Links

Documentation

Getting started with Android and Supabase [Video]

Quickstart

Tutorial: Build a Product Management Android App with Jetpack Compose

Dokka documentation for the latest version

Troubleshooting

Installation

Add one ore more modules to your project

Available modules: gotrue-kt, postgrest-kt, functions-kt, storage-kt, realtime-kt, apollo-graphql, compose-auth, compose-auth-ui, coil-integration, imageloader-integration

dependencies {
    implementation("io.github.jan-tennert.supabase:[module]:VERSION")
}

If you use multiple modules, you can use the bom dependency to get the correct versions for all modules:

implementation(platform("io.github.jan-tennert.supabase:bom:VERSION"))
implementation("io.github.jan-tennert.supabase:[module]")

Add a Ktor Client Engine to each of your Kotlin targets

You can find a list of available engines here. If you plan to use the Realtime dependency, make sure to check if the engine supports WebSockets. See the Ktor docs for more information.

implementation("io.ktor:ktor-client-[engine]:VERSION")
Multiplatform Example

For targets: jvm, android, js, ios

val commonMain by getting {
    dependencies {
        //supabase modules
    }
}
val jvmMain by getting {
    dependencies {
        implementation("io.ktor:ktor-client-cio:KTOR_VERSION")
    }
}
val androidMain by getting {
    dependsOn(jvmMain)
}
val jsMain by getting {
    dependencies {
        implementation("io.ktor:ktor-client-js:KTOR_VERSION")
    }
}
val iosMain by getting {
    dependencies {
        implementation("io.ktor:ktor-client-darwin:KTOR_VERSION")
    }
}

Note: It is recommended to use the same Ktor version as supabase-kt:

https://img.shields.io/badge/ktor-2.3.8-blue

Main Modules

Plugins

Apollo GraphQL integration - Creates an Apollo GraphQL Client for interacting with the Supabase API.

Compose Auth - Provides easy Native Google & Apple Auth for Compose Multiplatform targets.

Compose Auth UI - Provides UI Components for Compose Multiplatform.

Coil Integration - Provides a Coil Integration for displaying images stored in Supabase Storage.

Compose-ImageLoader Integration - Provides a Compose ImageLoader Integration for displaying images stored in Supabase Storage.

Demos

Need help?

Videos

Contribution

How to contribute

  1. Fork the repository
  2. Create a branch
  3. Make your changes
  4. Submit a pull request with your new branch

Credits

supabase-kt's People

Contributors

jan-tennert avatar dependabot[bot] avatar hieuwu avatar brezinajn avatar jollygreenegiant avatar shubhamsinghshubham777 avatar dshukertjr avatar temk0 avatar yuchan2215 avatar vinceglb avatar softwaresale avatar kiwicopple avatar mohamedrejeb avatar ramirond avatar dancing-koala avatar ferhatwi avatar

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.