Friday, July 5, 2024
HomeiOS Developmentjavascript - Service Discovery to dynamically set server location

javascript – Service Discovery to dynamically set server location


I am utilizing capacitor to construct what is actually a PWA with service discovery to determine the server. The server delivers to the consumer a pair requisite gadgets to run, akin to icons and different issues. The service discovery is working accurately as I can see the proper ip within the logs. The app works as anticipated after I set the server url within the capacitor config json, however after I both take away the server parameter, or attempt to set an inventory of acceptable hosts, the app now not works. Within the first case, it’s as a result of any of the http:// are changed by capacitor://. Within the second case, I’m not certain the issue.

Is it attainable to make use of service discovery to set the situation of the online view? Or, how can I configure the config.json to permit the appliance to make requests to an exterior server?

variations I’ve tried:

"server":{
    "iosScheme": "http"
}```
"server":{
"hosts:"["192.168.*,
"10.168.*"]

I am new to app dev so apologize if it is a dumb query.



Supply hyperlink

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

- Advertisment -
Google search engine

Most Popular

Recent Comments