I've tried to import bootstrap an archive but i've face this error: "GET /bootstrap.css HTTP/1.1" 404
While when I use this tag link it works perfectly.
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.0/css/bootstrap.min.css" integrity="sha384-9aIt2nRpC12Uk9gS9baDl411NQApFmC26EwAOH8WgZl5MYYxFfc+NcPb1dKGj7Sk" crossorigin="anonymous">
It is possible to import bootstrap as a file while using Flask? If don't, I would like to know why, please
html:
<!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" href="bootstrap.css">
<title>{% block title %}{% endblock %}</title>
</head>
<body>
<h1>Hello User</h1>
{% block content %}
{% endblock %}
</body>
</html>
python:
from flask import Flask, url_for, redirect, render_template
app = Flask(__name__)
@app.route("/")
def home():
return render_template("index.html")
if __name__ == "__main__":
app.run(debug=True)