This is bad UX because the user may not have any idea what to do, so I opened
index.html and added a
<script type="module" src="/src/main.tsx"></script>
Sure, it’s probably not very common. But one of the points of Ionic is that there is pretty good support for web standards.
So I thought this would be easy (drop in a
<noscript> tag and call it a day). Unfortunately that doesn’t work, and I don’t understand enough about how Ionic is put together to identify the problem. Actually it occurs to me it could be due to Vite, which I’m using as a build tool, as well.
Any insight into how to get a message “you need to enable JS” would be much appreciated.
You can workaround it by adding hydrated class to your html element, i.e.
hydrated makes the
<noscript> message appear!
Initial testing shows no effects on the app with JS enabled, but I’ll report back if I find this somehow breaks my app.