오늘만살자
Template 적용하기 본문
루트에 templates 폴더 생성
app.py 수정
from flask import Flask, render_template
app = Flask(__name__)
@app.route("/", methods=['GET', 'POST', 'PUT'])
def home():
return render_template('index.html')
app.run(debug=True)
cd templates
vi index.html
<html>
<body>
<h3><u>Hello World!</u></h3>
</body>
</html
'Flask' 카테고리의 다른 글
flask 프로젝트 생성 (0) | 2020.08.06 |
---|
Comments