1seok2

add flask

1 import os 1 import os
2 -
3 from config.firebase import db 2 from config.firebase import db
3 +from flask import Flask, render_template
4 +
5 +# data = {
6 +# "age": 24,
7 +# "name": "choi",
8 +# "date": "2020.12.03"
9 +# }
10 +
11 +# db.child("name").child("name").update(data)
12 +
13 +app = Flask(__name__)
14 +
15 +
16 +@app.route("/")
17 +def home():
18 + return render_template('index.html')
19 +
4 20
5 -print("-" * 60) 21 +if __name__ == "__main__":
22 + print("-" * 60)
23 + print(" server is start")
24 + print("-" * 60)
6 25
7 -db.child("name").push({"company": "google"}) 26 + app.run(debug=True)
......
1 +<!DOCTYPE html>
2 +<html>
3 +<body>
4 + <h1>메인 화면</h1>
5 +</body>
6 +</html>
...\ No newline at end of file ...\ No newline at end of file