File tree 5 files changed +12
-18
lines changed
5 files changed +12
-18
lines changed Original file line number Diff line number Diff line change 6
6
7
7
8
8
serve_development_app = starlette .serve_development_app
9
- """Alias for :func:`idom.server .starlette.serve_development_app`"""
9
+ """Alias for :func:`idom.backend .starlette.serve_development_app`"""
10
10
11
11
# see: https://github.com/idom-team/flake8-idom-hooks/issues/12
12
12
use_location = starlette .use_location # noqa: ROH101
13
- """Alias for :func:`idom.server .starlette.use_location`"""
13
+ """Alias for :func:`idom.backend .starlette.use_location`"""
14
14
15
15
# see: https://github.com/idom-team/flake8-idom-hooks/issues/12
16
16
use_scope = starlette .use_scope # noqa: ROH101
17
- """Alias for :func:`idom.server .starlette.use_scope`"""
17
+ """Alias for :func:`idom.backend .starlette.use_scope`"""
18
18
19
19
# see: https://github.com/idom-team/flake8-idom-hooks/issues/12
20
20
use_websocket = starlette .use_websocket # noqa: ROH101
21
- """Alias for :func:`idom.server .starlette.use_websocket`"""
21
+ """Alias for :func:`idom.backend .starlette.use_websocket`"""
22
22
23
23
Options = starlette .Options
24
- """Alias for :class:`idom.server .starlette.Options`"""
24
+ """Alias for :class:`idom.backend .starlette.Options`"""
25
25
26
26
configure = starlette .configure
27
- """Alias for :class:`idom.server .starlette.configure`"""
27
+ """Alias for :class:`idom.backend .starlette.configure`"""
28
28
29
29
30
30
def create_development_app () -> FastAPI :
Original file line number Diff line number Diff line change 45
45
def configure (
46
46
app : Flask , component : RootComponentConstructor , options : Options | None = None
47
47
) -> None :
48
- """Return a :class:`FlaskServer` where each client has its own state.
49
-
50
- Implements the :class:`~idom.server.proto.ServerFactory` protocol
48
+ """Confiure a Flask application to use IDOM.
51
49
52
50
Parameters:
53
- constructor: A component constructor
51
+ app: An application instance
52
+ component: A component constructor
54
53
options: Options for configuring server behavior
55
- app: An application instance (otherwise a default instance is created)
56
54
"""
57
55
options = options or Options ()
58
56
blueprint = Blueprint ("idom" , __name__ , url_prefix = options .url_prefix )
Original file line number Diff line number Diff line change @@ -40,9 +40,7 @@ def configure(
40
40
constructor : RootComponentConstructor ,
41
41
options : Options | None = None ,
42
42
) -> None :
43
- """Return a :class:`StarletteServer` where each client has its own state.
44
-
45
- Implements the :class:`~idom.server.proto.ServerFactory` protocol
43
+ """Configure a Starlette application to use IDOM.
46
44
47
45
Parameters:
48
46
app: An application instance
Original file line number Diff line number Diff line change @@ -36,9 +36,7 @@ def configure(
36
36
component : ComponentConstructor ,
37
37
options : Options | None = None ,
38
38
) -> None :
39
- """Return a :class:`TornadoServer` where each client has its own state.
40
-
41
- Implements the :class:`~idom.server.proto.ServerFactory` protocol
39
+ """Configure a Tornado application to use IDOM.
42
40
43
41
Parameters:
44
42
app: A tornado ``Application`` instance.
Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ def run(
40
40
"Change this before deploying in production!"
41
41
)
42
42
43
- implementation = implementation or import_module ("idom.server .default" )
43
+ implementation = implementation or import_module ("idom.backend .default" )
44
44
45
45
app = implementation .create_development_app ()
46
46
implementation .configure (app , component )
You can’t perform that action at this time.
0 commit comments