MCPcopy
hub / github.com/plotly/dash / Dash

Class Dash

dash/dash.py:228–2696  ·  view source on GitHub ↗

Dash is a framework for building analytical web applications. No JavaScript required. If a parameter can be set by an environment variable, that is listed as: env: ``DASH_****`` Values provided here take precedence over environment variables. :param name: The name Flask sho

Source from the content-addressed store, hash-verified

226# pylint: disable=too-many-instance-attributes
227# pylint: disable=too-many-arguments, too-many-locals
228class Dash(ObsoleteChecker):
229 """Dash is a framework for building analytical web applications.
230 No JavaScript required.
231
232 If a parameter can be set by an environment variable, that is listed as:
233 env: ``DASH_****``
234 Values provided here take precedence over environment variables.
235
236 :param name: The name Flask should use for your app. Even if you provide
237 your own ``server``, ``name`` will be used to help find assets.
238 Typically ``__name__`` (the magic global var, not a string) is the
239 best value to use. Default ``'__main__'``, env: ``DASH_APP_NAME``
240 :type name: string
241
242 :param server: Sets the server for your app. There are three options:
243 ``True`` (default): Dash will create a new server using the specified backend
244 ``False``: The server will be added later via ``app.init_app(server)``
245 A server instance: Use a pre-existing server (Flask, Quart, or FastAPI)
246 :type server: boolean or server instance
247
248 :param backend: The backend to use for the Dash app. Can be a string
249 (name of the backend) or a backend class. Default is None, which
250 selects the Flask backend. Currently, "flask", "fastapi", and "quart" backends
251 are supported.
252 :type backend: string or type
253
254 :param assets_folder: a path, relative to the current working directory,
255 for extra files to be used in the browser. Default ``'assets'``.
256 All .js and .css files will be loaded immediately unless excluded by
257 ``assets_ignore``, and other files such as images will be served if
258 requested.
259 :type assets_folder: string
260
261 :param pages_folder: a relative or absolute path for pages of a multi-page app.
262 Default ``'pages'``.
263 :type pages_folder: string or pathlib.Path
264
265 :param use_pages: When True, the ``pages`` feature for multi-page apps is
266 enabled. If you set a non-default ``pages_folder`` this will be inferred
267 to be True. Default `None`.
268 :type use_pages: boolean
269
270 :param include_pages_meta: Include the page meta tags for twitter cards.
271 :type include_pages_meta: bool
272
273 :param assets_url_path: The local urls for assets will be:
274 ``requests_pathname_prefix + assets_url_path + '/' + asset_path``
275 where ``asset_path`` is the path to a file inside ``assets_folder``.
276 Default ``'assets'``.
277 :type asset_url_path: string
278
279 :param assets_ignore: A regex, as a string to pass to ``re.compile``, for
280 assets to omit from immediate loading. Ignored files will still be
281 served if specifically requested. You cannot use this to prevent access
282 to sensitive files.
283 :type assets_ignore: string
284
285 :param assets_path_ignore: A list of regex, each regex as a string to pass to ``re.compile``, for

Calls

no outgoing calls

Used in the wild real call sites across dependent graphs

searching dependent graphs…