A kit for creating FastAPI + Svelte applications
Project description
Coloco
A kit for creating full-stack apps with co-located code, built on FastAPI and Svelte. Bundle your front-end and back-end code and easily tie them together with codegen.
Example:
hello/api.py
from coloco import api
@api
def test(name: str):
return f"Hello {name}!"
hello/index.svelte
<script lang="ts">
import { test } from "./api";
</script>
{#await test({ name: "Coloco" })}
Loading...
{:then result}
The server says {result}
{/await}
Serves the page myapp.com/hello, which calls myapp.com/hello/test?name=Coloco and prints the message Hello Coloco!
Getting Started
pip install colococoloco createapp myapp- From
myapp-coloco dev
Running in Production
coloco build- Artifacts will be saved to
dist - From dist, run
coloco serve
Opinions
This framework is opinionated and combines the following excellent tools:
- FastAPI
- Svelte
- openapi-ts (codegen)
- svelte5-router (file-based routing)
- tortoise-orm (optional)
TBD Required features for launch
- Deploy tools
- Swap migrations to
tortoise-pathwayonce cross-app migrations are supported - Config with secrets encryption
- Package/share modules with git
- Docs
Features in development
- CRUD
- Caching
- User module
- Dev tools module
- Admin panel module
Dreams
- Move
node_modulesinto+node
Other TODO
- Swap to
copierfor template creation TextualCLI app / installer / dev tools?- Resolve duplicate types in openapi spec (due to model serializers)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file coloco-0.4.1.tar.gz.
File metadata
- Download URL: coloco-0.4.1.tar.gz
- Upload date:
- Size: 17.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: pdm/2.24.2 CPython/3.13.3 Linux/6.11.0-1015-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9028d45aece3184c1ac17a0961f90bf6a50596fb4576bb98ab3a258326882e20
|
|
| MD5 |
e1831a1892f1f0f12410325e9a1e0a5c
|
|
| BLAKE2b-256 |
17877c637cfdc267443cf034dcd279f6b2420b4abe932fa006e726ecf1913e2e
|
File details
Details for the file coloco-0.4.1-py3-none-any.whl.
File metadata
- Download URL: coloco-0.4.1-py3-none-any.whl
- Upload date:
- Size: 26.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: pdm/2.24.2 CPython/3.13.3 Linux/6.11.0-1015-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fa40cc6ff90b2f409768e590b8673ef18bd076d432db93fe5852f340c8caa12f
|
|
| MD5 |
02cc605a98a0f46307a247e15bcf95e4
|
|
| BLAKE2b-256 |
88145e99bdf381ef0eefb3a564a9b0c66f2a75a284ad53063068e8d0a2108086
|