Currently we display a message if you try to open the plugin but the development server is not active. However it would be great if a message could be displayed while you have the plugin open if the local dev server is not running.
To do this we must check the URL is active while the plugin is open. We do this before hosting the URL, but when the plugin iframe then points to the URL, the code that runs to do this is not longer loaded in the DOM. So in order to accommodate this we must have the a similar function in the code that exists on the server side. This requires a bit of refactoring to abstract the logic so that we don't have to update it in several places. While this is being done, we should also probably check if dark or light mode has been changed. This check should happen by using a poll to detect if the server is not longer active.
Currently we display a message if you try to open the plugin but the development server is not active. However it would be great if a message could be displayed while you have the plugin open if the local dev server is not running.
To do this we must check the URL is active while the plugin is open. We do this before hosting the URL, but when the plugin iframe then points to the URL, the code that runs to do this is not longer loaded in the DOM. So in order to accommodate this we must have the a similar function in the code that exists on the server side. This requires a bit of refactoring to abstract the logic so that we don't have to update it in several places. While this is being done, we should also probably check if dark or light mode has been changed. This check should happen by using a poll to detect if the server is not longer active.