Starter for SvelteKit
frontend, powered by Flask
backend, using the Application Factory Pattern
.
Includes support for:
To deploy your app, you may need to
create an account
for Deta Space.
Instructions for developing the frontend on Windows. You may need to install Node
first.
# navigate to frontend
cd .\frontend\
# install dependencies
npm i
# start development server
npm run dev
Instructions for developing the backend on Windows. You may need to install Python
and Pipenv
first.
# navigate to backend
cd .\backend\
# create virtual environment dir (optional)
md .venv
# install dependencies
pipenv install --dev
# activate virtual environment
pipenv shell
# start development server
flask run --reload
It is also possible to start the development server directly from the frontend without activating the virtual environment.
# navigate to frontend
cd .\frontend\
# start development server
npm run flask
To deploy your app, first setup the Space CLI
.
Create a requirements.txt
file which is expected in the build pipeline.
# navigate to backend
cd .\backend\
# create requirements.txt
pipenv requirements > requirements.txt
Deploy from the project root directory.
# create a new project (once)
space new
# package and upload files
space push