I\'m new to Flask, and having some issues setting up a very basic Flask app. Right now, I\'m trying to get the user to submit a form on the homepage and then save that form to
If you are using flask-migrate library, you should run commands below to create and apply migrations. Database and tables will be created.
flask db migrate
flask db upgrade
Before running this commands you should create models. Models objects represent tables on a database. In your case, it may look like this
class Contact(db.Model):
id = db.Column(db.Integer, primary_key=True)
username = db.Column(db.String(80), unique=True, nullable=False)
email = db.Column(db.String(120), unique=True, nullable=False)