Open flashspys opened 9 years ago
hmm... I've been using Swifter in production and have had no problems running it on a device. https://github.com/Kitware/arctic-viewer-ios
Maybe try the following: Start the Swifter Demo App on a real device. Then press home button and open Safari and try to access localhost:8080 . On my devices it wont load. Only after I switch back to Demo App and switch back again to Safari I can see the loaded content
For what it's worth, I'm using the last version of swifter compatible with Swift 1.2. Perhaps something small has changed that causes the reported issue?
I notice the same behavior as tristaaan. The application cannot run in the background, so it must have focus on your iPhone to process your requests. Additionally, I cannot connect to the web server from other devices on the network.
If you'd like to try the application I mentioned App Store link, but again it's using an older version of swifter. I see the backgrounding problem now, but while the app is active I've had no problems accessing the server from other computers and devices on the same network.
When the app is active, everything works as far as I know fine. But I think Swifter should handle the situation that the webserver is called when Swifter is in background.
I have the same problem. Have anyone solved it?
Swifter does not start its server in a UIBackgroundTask That is the reason why the Swifter Demo App does not work on a real iOS Device but in iOS Simulator. It's very important to start the server in a Background Task. Otherwise the app wont answer for Example to the request when you access your webpage from MobileSafari!