Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for WASM-JS and migrate to Ktor 3.0.0 #311

Draft
wants to merge 35 commits into
base: master
Choose a base branch
from
Draft

Conversation

jan-tennert
Copy link
Collaborator

@jan-tennert jan-tennert commented Oct 13, 2023

What kind of change does this PR introduce?

Feature (closes #86)

What is the current behavior?

N/A

What is the new behavior?

New wasm-js target for supabase-kt

Supported modules:

  • supabase-kt
  • gotrue-kt
  • storage-kt
  • functions-kt
  • postgrest-kt
  • realtime-kt
  • compose-auth
  • compose-auth-ui
  • apollo-graphql

Additional context

The implementation should be almost the same as the js browser implementation. wasm-wasi support may also come if the libraries support it.
Latest compatible build: 2.4.2-wasm0
Note: A pre-release version for Ktor is used, waiting for a full release to merge this PR.

@jan-tennert jan-tennert added the enhancement New feature or request label Oct 13, 2023
@jan-tennert jan-tennert added this to the 1.5.0 milestone Oct 13, 2023
@jan-tennert jan-tennert self-assigned this Oct 13, 2023
@jan-tennert jan-tennert added the freezer On hold label Oct 21, 2023
@jan-tennert
Copy link
Collaborator Author

jan-tennert commented Oct 21, 2023

Putting this on hold until official KotlinX versions release.

@jan-tennert
Copy link
Collaborator Author

jan-tennert commented Nov 15, 2023

KotlinX Serialization, Coroutines and atomicfu now have official support, ktor and coroutines to go 👍

@jan-tennert jan-tennert reopened this Dec 1, 2023
@jan-tennert jan-tennert changed the title Add support for WASM Add support for WASM-JS Dec 1, 2023
@jan-tennert jan-tennert modified the milestones: 2.0.0, 2.1.0 Dec 4, 2023
@mikepenz
Copy link

@jan-tennert
Copy link
Collaborator Author

ktor has an experimental wasm2 build available here: https://youtrack.jetbrains.com/issue/KTOR-5587/Ktor-client-for-Kotlin-Wasm#focus=Comments-27-8670434.0-0

I know, the only problem is that these builds do not support some Kotlin targets required for this project. I might publish separate wasm builds until the official release.

@jan-tennert jan-tennert changed the base branch from development to master December 27, 2023 11:41
@jan-tennert
Copy link
Collaborator Author

ktor has an experimental wasm2 build available here: https://youtrack.jetbrains.com/issue/KTOR-5587/Ktor-client-for-Kotlin-Wasm#focus=Comments-27-8670434.0-0

I know, the only problem is that these builds do not support some Kotlin targets required for this project. I might publish separate wasm builds until the official release.

Update: Published a compatible build 2.0.2-wasm0

@mikepenz
Copy link

Thank you very much!

# Conflicts:
#	gradle.properties
# Conflicts:
#	GoTrue/src/jsMain/kotlin/io/github/jan/supabase/gotrue/setupPlatform.kt
#	gradle.properties
# Conflicts:
#	gradle.properties
# Conflicts:
#	.github/workflows/test.yml
#	GoTrue/build.gradle.kts
#	GoTrue/src/nonLinuxMain/kotlin/io/github/jan/supabase/gotrue/SettingsSessionManager.kt
#	gradle.properties
@jan-tennert jan-tennert changed the base branch from master to development February 16, 2024 12:22
@jan-tennert jan-tennert removed this from the 2.2.0 milestone Feb 22, 2024
@jan-tennert jan-tennert added the blocked by dependency This feature cannot be implemented as one ore more dependencies need an update. label Feb 28, 2024
@jan-tennert jan-tennert changed the title Add support for WASM-JS Add support for WASM-JS and migrate to Ktor 3.0.0 Mar 10, 2024
# Conflicts:
#	GoTrue/src/jsMain/kotlin/io/github/jan/supabase/gotrue/setupPlatform.kt
#	gradle/libs.versions.toml
#	plugins/ComposeAuth/build.gradle.kts
# Conflicts:
#	gradle/libs.versions.toml
# Conflicts:
#	gradle.properties
#	gradle/libs.versions.toml
@jan-tennert jan-tennert changed the base branch from development to master March 22, 2024 20:05
# Conflicts:
#	gradle.properties
#	gradle/libs.versions.toml
# Conflicts:
#	Storage/build.gradle.kts
#	gradle/libs.versions.toml
# Conflicts:
#	Functions/build.gradle.kts
#	GoTrue/build.gradle.kts
#	GoTrue/src/settingsMain/kotlin/io/github/jan/supabase/gotrue/SettingsCodeVerifierCache.kt
#	GoTrue/src/settingsMain/kotlin/io/github/jan/supabase/gotrue/SettingsSessionManager.kt
#	Postgrest/build.gradle.kts
#	Realtime/build.gradle.kts
#	Storage/build.gradle.kts
#	build.gradle.kts
#	gradle.properties
#	gradle/libs.versions.toml
#	plugins/ApolloGraphQL/build.gradle.kts
#	plugins/ComposeAuth/build.gradle.kts
#	plugins/ComposeAuthUI/build.gradle.kts
# Conflicts:
#	gradle.properties
# Conflicts:
#	gradle.properties
#	gradle/libs.versions.toml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked by dependency This feature cannot be implemented as one ore more dependencies need an update. enhancement New feature or request freezer On hold
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature request]: Add support for WASM
2 participants