[Beta] useContext API (#4378)

* [Beta] useContext API

* Simplify + add

* Tweaks

* Softer

* Tweaks

* Small tweaks
This commit is contained in:
dan
2022-02-24 22:00:02 +00:00
committed by GitHub
parent ac9a984a5b
commit 299dad85be
3 changed files with 1400 additions and 0 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -15,6 +15,7 @@ const ref = useRef(initialValue)
- [Usage](#usage)
- [Referencing a value with a ref](#referencing-a-value-with-a-ref)
- [Manipulating the DOM with a ref](#manipulating-the-dom-with-a-ref)
- [Exposing a ref from your component](#exposing-a-ref-from-your-component)
- [Avoiding recreating the ref contents](#avoiding-recreating-the-ref-contents)
- [Reference](#reference)
- [`useRef(initialValue)`](#useref)

View File

@@ -15,6 +15,10 @@
"title": "useState()",
"path": "/apis/usestate"
},
{
"title": "useContext()",
"path": "/apis/usecontext"
},
{
"title": "useRef()",
"path": "/apis/useref"