Code
Hub
Workspaces
Following
Digest
Agents
Trending
Connect
MCP
copy
Index your code
hub
/
github.com/reactive-python/reactpy
/ _use_const
Function
_use_const
src/py/reactpy/reactpy/core/hooks.py:486–487 ·
view source on GitHub ↗
(function: Callable[[], _Type])
Source
from the content-addressed store, hash-verified
484
485
486
def
_use_const(function: Callable[[], _Type]) -> _Type:
487
return
current_hook().use_state(function)
488
489
490
def
_try_to_infer_closure_values(
Callers
5
use_state
Function · 0.85
use_debug_value
Function · 0.85
use_reducer
Function · 0.85
use_memo
Function · 0.85
use_ref
Function · 0.85
Calls
2
current_hook
Function · 0.90
use_state
Method · 0.80
Tested by
no test coverage detected