Skip to content

An offline-first application implemented using Foursquare Places Api and Jetpack Compose

Notifications You must be signed in to change notification settings

8lueMeth/foursquare-nearby

Repository files navigation

NearbyForsquare

An offline-first application wich uses foursquare places api to fetch nearby places around you based on your current lat/long. the list will only updates itself when you move at least 100 meters.

Usage

In order to make this application able to retrieve responses from foursquare api you need to generate a access token, create a text file named keystore.properties like below.

ACCESS_TOKEN = "your api access token"

paste your access token as the value of ACCESS_TOKEN key.

then copy this file into the root folder of this project. the AuthHeaderInterceptor will read the access token value from generated BuildConfig file.

class AuthorizationHeaderInterceptor @Inject constructor() : Interceptor {

    override fun intercept(chain: Interceptor.Chain): Response {
        val original = chain.request()
        val request = original.newBuilder()
        request.addHeader("Authorization", BuildConfig.ACCESS_TOKEN")
        return chain.proceed(request.build())
    }
}

Features & Libraries

  • Kotlin
  • MVVM
  • Repository
  • NetworkBoundResource (with Flow)
  • Hilt
  • Jetpack Compose
  • Room
  • Offline-First / Local Caching
  • Flow
  • Navigation
  • Coil

About

An offline-first application implemented using Foursquare Places Api and Jetpack Compose

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages