Computer scienceBackendFlaskApplication Architecture

Structuring the application

Your package has arrived

Report a typo

In the models.py of the above structure , which is the correct way to import the variables app and db defined in the __init__.py file.

#my_app/__init__.py

from flask import Flask
from flask_sqlalchemy import SQLAlchemy


app = Flask(__name__)
db = SQLAlchemy(app)

from sample import routes
Put the items in the correct order
One
Two
Three
___

Create a free account to access the full topic