I created a template in the templates folder next to my Flask app. When I try to render this template, I get a 404 error in the browser. Why can't I render the template?
from flask import Flask, render_template
app = Flask(__name__, template_folder='/templates')
@app.route('/')
def index():
return render_template('index.html')