We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Minimal example:
from flask import Flask, Blueprint app = Flask(__name__) parent = Blueprint('parent', __name__, url_prefix='/child') child = Blueprint('child', __name__, url_prefix='/parent') @child.get('/') def index(): return 'hello' parent.register_blueprint(child) app.register_blueprint(parent)
The output of flask routes:
flask routes
$ flask routes Endpoint Methods Rule ------------------ ------- ----------------------- parent.child.index GET / static GET /static/<path:filename>
The URL rule should be /parent/child/ instead of /.
/parent/child/
/
P.S. The URL prefix works fine if set the prefix by using register_blueprint(url_prefix).
register_blueprint(url_prefix)
Environment:
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Minimal example:
The output of
flask routes
:The URL rule should be
/parent/child/
instead of/
.P.S. The URL prefix works fine if set the prefix by using
register_blueprint(url_prefix)
.Environment:
The text was updated successfully, but these errors were encountered: