Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

docs: update wording, reformat code

Hieu Vu524f8314c249
diff --git a/apps/docs/pages/guides/getting-started/quickstarts/kotlin.mdx b/apps/docs/pages/guides/getting-started/quickstarts/kotlin.mdx
index df0815e0ede..b13cb1cb6b2 100644
--- a/apps/docs/pages/guides/getting-started/quickstarts/kotlin.mdx
+++ b/apps/docs/pages/guides/getting-started/quickstarts/kotlin.mdx
@@ -56,7 +56,7 @@ export const meta = {
<StepHikeCompact.Details title="Install the Supabase client library">
Setup Supabase libraries requires some others libraries from ktor, so make sure all dependencies are added.
- Replace place holder of the dependency versions `$supabase_version` and `$ktor_version` with latest versions as below
+ Replace the dependency version placeholders `$supabase_version` and `$ktor_version` with the latest versions as shown below.
<div style={{ display: 'flex', flexDirection: 'row', alignItems: 'center' }}>
<a href="https://github.com/supabase-community/supabase-kt/releases" style={{ marginRight: '8px' }}>
<img src="https://img.shields.io/github/release/supabase-community/supabase-kt?label=supabase-kt stable" alt="latest stable supabase-kt version"/>
@@ -215,31 +215,31 @@ export const meta = {
private val productRepository: ProductRepository
) : ViewModel() {
- private val _productList = MutableStateFlow<List<Product>?>(listOf())
- val productList: Flow<List<Product>?> = _productList
+ private val _productList = MutableStateFlow<List<Product>?>(listOf())
+ val productList: Flow<List<Product>?> = _productList
- init {
- getProducts()
- }
+ init {
+ getProducts()
+ }
- fun getProducts() {
- viewModelScope.launch {
- val products = productRepository.getProducts()
- _productList.emit(products?.map { it -> it.asDomainModel() })
- }
- }
+ fun getProducts() {
+ viewModelScope.launch {
+ val products = productRepository.getProducts()
+ _productList.emit(products?.map { it -> it.asDomainModel() })
+ }
+ }
- private fun ProductDto.asDomainModel(): Product {
- return Product(
- productId = this.productId,
- name = this.name,
- price = this.price,
- image = this.image,
- description = this.description,
- category = this.category,
- nutrition = this.nutrition,
- _id = this._id
- )
+ private fun ProductDto.asDomainModel(): Product {
+ return Product(
+ productId = this.productId,
+ name = this.name,
+ price = this.price,
+ image = this.image,
+ description = this.description,
+ category = this.category,
+ nutrition = this.nutrition,
+ _id = this._id
+ )
}
```
</StepHikeCompact.Code>
diff --git a/apps/docs/pages/guides/getting-started/tutorials/with-kotlin.mdx b/apps/docs/pages/guides/getting-started/tutorials/with-kotlin.mdx
index d523f227ee7..2a8c97b5aa4 100644
--- a/apps/docs/pages/guides/getting-started/tutorials/with-kotlin.mdx
+++ b/apps/docs/pages/guides/getting-started/tutorials/with-kotlin.mdx
@@ -68,7 +68,7 @@ val apiKey = BuildConfig.API_KEY
### 3. Set up Supabase dependencies including Postgrest, GoTrue, Storage and serialization plugin
<img width="720" alt="Screen Shot 2023-06-05 at 21 39 24" src="https://github.com/hieuwu/product-sample-supabase-kt/assets/43868345/3f154fda-aa9e-4baa-81f2-5b744c7ad2fe"></img>
-In build.gradle (app) file, add these dependencies then press Sync now. Replace place holder of the dependency versions `$supabase_version` and `$ktor_version` with latest versions as below
+In build.gradle (app) file, add these dependencies then press Sync now. Replace the dependency version placeholders `$supabase_version` and `$ktor_version` with the latest versions as shown below.
<div style={{ display: 'flex', flexDirection: 'row', alignItems: 'center' }}>
<a href="https://github.com/supabase-community/supabase-kt/releases" style={{ marginRight: '8px' }}>
<img src="https://img.shields.io/github/release/supabase-community/supabase-kt?label=supabase-kt stable" alt="latest stable supabase-kt version"/>