An introduction to building globally scaled modern static web apps on Azure and how to publish existing javascript based web app to Azure Static Web Apps.
If you are developing modern web apps that are build using javascript or javascript based frameworks and uses client-side rendering using, and want to streamline the full-stack development from source code to global high availability, this article for you.
Keep reading, you will be amazed…
Azure static Web apps service (currently in preview) announced at Microsoft Build 2020 and is in public review as of May 2020
What does Azure Static Web Apps provide out of the box?
What are the current limitations (at the time of writing)?
Deploying an existing static react app using to Azure Static Web Apps (this will guide you on how to migrate your existing react static app to Azure Static Web Apps)
Azure Static Web Apps service is currently only supports apps build with javascript based frameworks.
Since it is in public preview and is free it has some limitations on bandwidth, app size, number of custom domains, etc. detail of which can be found here
It does not integrate with Azure DevOps and only supports integration with GitHub at the moment.
Since we’re living in these unprecedented times of COVID-19 and working from the home era, I started learning React and built an app to track and provide live COVID-19 stats rolling updates.
So in this hands-on exercise we’ll be deploying my live Covid-19 stats react app using Azure Static Web Apps.
Now that the repository is created, let’s open it in the Visual Studio Code and add a routes.json file in the public folder.
Our app relies on client-side routing for web app navigation. These client-side routing rules update the browser’s window location without making requests back to the server.
Add the following fallback route in routes.json file:
The whole experience of building and deploying a static web app with global availability couldn’t get any simpler and easier.
Azure Static Web Apps is currently in public preview and FREE to use and based on announcements made during Microsoft Build 2020 there will be a free plan (which should be sufficient for most of us nerds 😅), however that may change in future as it becomes generally available.
I would definitely be using #AzureStaticWebApps going forward for my projects and would recommend you give it a go too.