This starter kit uses Svelte and Eleventy to build the static site frontend. It also includes a basic example of using JavaScript Managed Functions as a backend.
You can use degit
create a copy one of the available starter kits by running one of the commands below.
# Copy the latest starter kit with JS API
npx degit itlackey/azure-swa-starter {you_dir_name}
# Copy the latest starter kit with PY API
npx degit itlackey/azure-swa-starter#py {you_dir_name}
# Copy the latest starter kit with no API or Svelte components, plain old static HTML/JS/CSS
npx degit itlackey/azure-swa-starter#basic {you_dir_name}
To use the pre-configured npm scripts, you will need to install the Azure Static Website CLI tool globally.
npm i -g @azure/static-web-apps-cli
npm start
- local server using swa CLInpm run debug
- swa cli will wait for you to launch the 'Debug Functions' session in VSCodenpm run watch
- runs rollup and eleventy with watch flagsnpm run 11ty
- runs rollup and eleventy with serve flagsnpm run build
- runs rollup and eleventy build stepsnpm run clean
- deletes .distA few good places to start customizing this template...
site/assets
folder
Using VSCode extension...
Using VSCode extension...
Updates to the .github/workflows
file