Skip to content

Commit

Permalink
Creating app/main.py done.
Browse files Browse the repository at this point in the history
  • Loading branch information
shinokada committed Dec 10, 2020
1 parent 74beed9 commit cb8816d
Show file tree
Hide file tree
Showing 28 changed files with 49 additions and 0 deletions.
Empty file added app/__init__.py
Empty file.
Binary file added app/__pycache__/__init__.cpython-39.pyc
Binary file not shown.
Binary file added app/__pycache__/main.cpython-39.pyc
Binary file not shown.
Empty file added app/lib/__init__.py
Empty file.
Empty file added app/lib/helpers.py
Empty file.
20 changes: 20 additions & 0 deletions app/main.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
from fastapi import FastAPI, Request
from fastapi.responses import HTMLResponse

app = FastAPI()


@app.get("/")
async def home():
data = {
"text": "hi"
}
return {"data": data}


@app.get("/page/{page_name}")
async def page(page_name: str):
data = {
"page": page_name
}
return {"data": data}
Empty file added app/pages/about.md
Empty file.
4 changes: 4 additions & 0 deletions app/pages/home.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Welcome to FastAPI Starter

This project uses [FastAPI](https://fastapi.tiangolo.com/), [Jinja2](https://jinja.palletsprojects.com/en/2.11.x/), and [Bootstrap4](https://getbootstrap.com/docs/4.1/getting-started/introduction/).

Empty file added app/pages/info.md
Empty file.
Empty file added app/routers/__init.py
Empty file.
Binary file added app/routers/__pycache__/accordion.cpython-39.pyc
Binary file not shown.
Binary file added app/routers/__pycache__/twoforms.cpython-39.pyc
Binary file not shown.
Empty file added app/routers/accordion.py
Empty file.
Empty file added app/routers/twoforms.py
Empty file.
8 changes: 8 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
requests==2.25.0
fastapi==0.62.0
python-dotenv==0.15.0
uvicorn==0.12.3
aiofiles==0.6.0
python-multipart==0.0.5
jinja2==2.11.2
Markdown==3.3.3
Empty file added runtime.txt
Empty file.
2 changes: 2 additions & 0 deletions settings.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
from dotenv import load_dotenv
load_dotenv()
Empty file added static/css/style.css
Empty file.
Binary file added static/images/favicon.ico
Binary file not shown.
15 changes: 15 additions & 0 deletions static/images/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Empty file added static/js/index.js
Empty file.
Empty file added templates/accordion.html
Empty file.
Empty file added templates/base.html
Empty file.
Empty file added templates/home.html
Empty file.
Empty file added templates/include/footer.html
Empty file.
Empty file added templates/include/sidebar.html
Empty file.
Empty file added templates/include/topbar.html
Empty file.
Empty file added templates/twoforms.html
Empty file.

0 comments on commit cb8816d

Please sign in to comment.