white screen only in iPhone
Hello! The problem I have is when I open my site using the ngrok url on iPhone I see a white screen but when I open it on my Android device or PC I can see my site. how can this be fixed?
14 Replies
Hey @RomaY! I'm the kapa.ai support bot. I've searched through the docs to try to answer your question. :wave:
----------------------
Hmm, I don't know enough to give you a confident answer yet. The provided extracts don't mention ngrok or any specific issues related to iPhone devices. I recommend checking the refine documentation (https://refine.dev/docs) or their blog (https://refine.dev/blog) for more information on this topic.
----------------------
Overview | refine
What is refine?
Blog | refine
A Docusaurus powered blog!
<@538717491908575242> kapa.ai is still learning and improving, please let us how it did by reacting below
rival-black•2y ago
I think the problem is somewhere in the project, because I ran another project and it opened
the problem is definitely in the project itself, but I don't understand what
wise-white•2y ago
I have no idea and I cannot debug without more information.
is it opening with iphone with chrome ? if is it, probably safari has issue
rival-black•2y ago
Still the white screen problem on iPhone was in accessControl, how do I use accessControl, for my authProvider?
I am using casbin and when I removed the accessControl from the App file I could see my site on the iPhone, this problem is only on iOS
wise-white•2y ago
I'm not quite sure, There are too many abstractions and not have enough information to analyze this problem.
- iphone may not allow ngrok URL's for security reasons.
- It may not work if ngrok opened the port with http.
- maybe some casbin javascript dependencies may not be supported on iphone.
rival-black•2y ago
No, the problem is simply in the accessControl casbin of my application, how do I configure it to access these resources, because if I remove it from the file, I see my authorization resources
And I didn't find anything in the docs how to configure access control provider for auth
Because otherwise resources are blocked on iOS it is blocked
Hello @RomaY , Could you share a CodeSandbox or StackBlitz where we can reproduce the error? You can fork this example from us: https://refine.dev/docs/examples/access-control/cerbos/
Cerbos | refine
Access Control is a complex topic with a variety of sophisticated solutions that provide numerous functions. This example demonstrates how to use refine and Cerbos to simplify access control management throughout your application.
rival-black•2y ago
The problem was in the newEnforcer that I imported from “casbin”, I changed the import to “casbin.js”, this problem disappeared, accordingly I also changed the accessControl file, model and adapter imported from “casbin.js”, but now it gives access to all pages until the page is reloaded
How to make the accessControl follow the role change, without reloading, because the role changes, but the accessControl takes the initial state, and when the role changes after authorization, it does not change the access rights, how to make it change those access rights without reloading the page?
wise-white•2y ago
do you changes roles from backend ?
when you change roles from backend, client should fetch data again to get new data. so this is require reloading page or refetch query
rival-black•2y ago
Yes, in user data
How to do this without reloading the page? Because it doesn't look very good
wise-white•2y ago
but http works with request-response. of course http 3 and websocket can push data to client. but with http2 when data changes from server, client does not now until fetch data again.
supabase, appwrite like data providers has live-provider feature. maybe casbin has live-provider feature too, I don't know
rival-black•2y ago
OK, thanks, I'll deal with it later, the main thing is that the white screen is gone