6 changed files with 27 additions and 0 deletions
@ -0,0 +1,5 @@ |
|||||
|
from fastapi import FastAPI |
||||
|
|
||||
|
app = FastAPI() |
||||
|
|
||||
|
app.frontend("/", directory="dist") |
||||
@ -0,0 +1,5 @@ |
|||||
|
from fastapi import FastAPI |
||||
|
|
||||
|
app = FastAPI() |
||||
|
|
||||
|
app.frontend("/", directory="dist", fallback="index.html") |
||||
@ -0,0 +1,5 @@ |
|||||
|
from fastapi import FastAPI |
||||
|
|
||||
|
app = FastAPI() |
||||
|
|
||||
|
app.frontend("/", directory="dist", fallback="404.html") |
||||
@ -0,0 +1,7 @@ |
|||||
|
from fastapi import APIRouter, FastAPI |
||||
|
|
||||
|
app = FastAPI() |
||||
|
router = APIRouter() |
||||
|
|
||||
|
router.frontend("/", directory="dist", fallback="index.html") |
||||
|
app.include_router(router, prefix="/app") |
||||
@ -0,0 +1,5 @@ |
|||||
|
from fastapi import FastAPI |
||||
|
|
||||
|
app = FastAPI() |
||||
|
|
||||
|
app.frontend("/", directory="dist", fallback=None) |
||||
Loading…
Reference in new issue