Skip to content

Fix hook deprecation warning #1240

New issue

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

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/py/reactpy/reactpy/backend/hooks.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
def use_connection() -> Connection[Any]: # nocov
"""Get the current :class:`~reactpy.backend.types.Connection`."""
warn(
"The module reactpy.backend.hooks has been deprecated and will be deleted in the future. ",
"The module reactpy.backend.hooks has been deprecated and will be deleted in the future. "
"Call reactpy.use_connection instead.",
DeprecationWarning,
)
Expand All @@ -26,7 +26,7 @@ def use_connection() -> Connection[Any]: # nocov
def use_scope() -> MutableMapping[str, Any]: # nocov
"""Get the current :class:`~reactpy.backend.types.Connection`'s scope."""
warn(
"The module reactpy.backend.hooks has been deprecated and will be deleted in the future. ",
"The module reactpy.backend.hooks has been deprecated and will be deleted in the future. "
"Call reactpy.use_scope instead.",
DeprecationWarning,
)
Expand All @@ -37,7 +37,7 @@ def use_scope() -> MutableMapping[str, Any]: # nocov
def use_location() -> Location: # nocov
"""Get the current :class:`~reactpy.backend.types.Connection`'s location."""
warn(
"The module reactpy.backend.hooks has been deprecated and will be deleted in the future. ",
"The module reactpy.backend.hooks has been deprecated and will be deleted in the future. "
"Call reactpy.use_location instead.",
DeprecationWarning,
)
Expand Down
Loading