Flask.register_blueprint(*args, **kwargs)[source]

Register a blueprint on the application. For information about blueprints head over to Modular Applications with Blueprints.

The blueprint name is passed in as the first argument. Options are passed as additional keyword arguments and forwarded to blueprints in an “options” dictionary.

  • subdomain – set a subdomain for the blueprint
  • url_prefix – set the prefix for all URLs defined on the blueprint. (url_prefix='/<lang code>')
  • url_defaults – a dictionary with URL defaults that is added to each and every URL defined with this blueprint
  • static_folder – add a static folder to urls in this blueprint
  • static_url_path – add a static url path to urls in this blueprint
  • template_folder – set an alternate template folder
  • root_path – set an alternate root path for this blueprint

New in version 0.7.