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 Web support #77

Merged
merged 1 commit into from
Dec 11, 2021
Merged

🎉 Add Web support #77

merged 1 commit into from
Dec 11, 2021

Conversation

czepiec
Copy link
Contributor

@czepiec czepiec commented May 25, 2021

This PR adds support for Web platform as discussed in #16. The authentication service will open in a new browser window. To capture callback URL you need to create an HTML file with JavaScript postMessage() method which sends URL to the application. It is explained with an example in README.md.

@nrubin29
Copy link

Any status update on this getting merged? I've been using it in my production app for awhile and it works perfectly.

@Silfalion
Copy link

Would really like to see it added too.

@czepiec
Copy link
Contributor Author

czepiec commented Oct 31, 2021

@LinusU in the last weeks I have made some improvements to the PR, but I do not expect any other future changes. I think it's quality code, was reviewed and it's used in several production environments. If there's anything that needs to be discussed, I'm here.

@Silfalion
Copy link

@czepiec sorry for the ping. I was planning to collect all pull requests into one repo but I have trouble running your PR.

The first problem I encounter is that the websocket cant bind because of flutter web.

I was able to overcome that by creating a separate project and testing without a server but using localhost my path(localhost:port/auth.html) can't be reached they say. Did you encounter this issue?

@Silfalion
Copy link

Hey, the appwrite org agreed to open a repo just for flutter_web_auth in the meantime LinusU is back, pushed a pull request with the changes here:

appwrite#1

@LinusU LinusU changed the title 💥 Add Web support (#16) 🎉 Add Web support (#16) Dec 11, 2021
@LinusU LinusU changed the title 🎉 Add Web support (#16) 🎉 Add Web support Dec 11, 2021
@LinusU LinusU merged commit 1de8864 into LinusU:master Dec 11, 2021
@Silfalion
Copy link

Thank you for merging it!

@LinusU
Copy link
Owner

LinusU commented Dec 11, 2021

So sorry for the long delay on this! My goal is to transition this package over to some community that can maintain it 😅

This is now published as 🚢 0.3.2 / 2021-12-11

@Silfalion
Copy link

No worries at all! When life gets busy there is no fighting it. I’m not thaaat familiar with the code right now but I’m willing to help if you’re ok with that.

@czepiec
Copy link
Contributor Author

czepiec commented Dec 12, 2021

Thanks @LinusU.

For everyone who uses my fork, I keep it active until the end of 01/2022, then I will have to delete it. Change your dependency back to the upstream, I recommend version 0.4.0 with Android V2 embedding 🙂.

@Silfalion I admit I don't understand to

The first problem I encounter is that the websocket cant bind because of flutter web.

In production, this is usually solved by starting the websocket server on another port and then pass a path to it on the web server (e.g. NGINX).

Will5 pushed a commit to Will5/flutter_web_auth that referenced this pull request Sep 9, 2024
* Successfully build on MacOS VM

* Fix lint

* Port a few more changes from iOS to macOS

* Fix macOS compile errors
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants