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

[googleapis_auth] support running both io and browser in the same app #433

Open
YazeedAlKhalaf opened this issue Aug 1, 2022 · 0 comments

Comments

@YazeedAlKhalaf
Copy link

YazeedAlKhalaf commented Aug 1, 2022

i would like to share a proposal for adding new apis that do nothing but make sure that io and browser parts can work together.

i am not an expert on the matter but with trial and error i got to know about the if directive thing in dart.

my use case is an app that has google sign in, i want it to work on desktop and web simultaneously.

the problem is that i am not able to run the code when i import web things to io host and vice versa. this is understandable since they are not made for each other.

i would like to add fake apis, if that is a thing, that mimic apis that are not found in io and browser together.

i would also add it to the README so that is so clear how to use it since you will need to use kIsWeb to make sure the compiled code runs.

i know this is unsafe in runtime if the developer forgets about kIsWeb, but that is my proposed solution.

if you have a better one share it so we can reach a solution.

i can open a PR so we can discuss the possibilities

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

No branches or pull requests

1 participant