From 2e7e1504999b983648c1faf10f566bb81d0e4d0c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mariusz=20P=C4=99kala?= Date: Wed, 9 Sep 2020 17:18:31 +0200 Subject: [PATCH] Update accessibility.md When reading the guides in order, the acronym HOC may not yet be known nor understandable to the readers. A link to the guide shall ease their minds. --- content/docs/accessibility.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/docs/accessibility.md b/content/docs/accessibility.md index 911d0baf2e4..d3ad718399d 100644 --- a/content/docs/accessibility.md +++ b/content/docs/accessibility.md @@ -228,7 +228,7 @@ class Parent extends React.Component { this.inputElement.current.focus(); ``` -When using a HOC to extend components, it is recommended to [forward the ref](/docs/forwarding-refs.html) to the wrapped component using the `forwardRef` function of React. If a third party HOC does not implement ref forwarding, the above pattern can still be used as a fallback. +When using a [HOC](/docs/higher-order-components.html) to extend components, it is recommended to [forward the ref](/docs/forwarding-refs.html) to the wrapped component using the `forwardRef` function of React. If a third party HOC does not implement ref forwarding, the above pattern can still be used as a fallback. A great focus management example is the [react-aria-modal](https://github.com/davidtheclark/react-aria-modal). This is a relatively rare example of a fully accessible modal window. Not only does it set initial focus on the cancel button (preventing the keyboard user from accidentally activating the success action) and trap keyboard focus inside the modal, it also resets focus back to the element that initially triggered the modal.