@hakuna-matata-ui/live-region
TypeScript icon, indicating that this package has built-in type declarations

1.1.2 • Public • Published

Live Regions

ARIA Live Regions are used to communicate important information to screen reader software.

Installation

yarn add @hakuna-matata-ui/live-region

Import components

import { LiveRegion, useLiveRegion } from "@hakuna-matata-ui/live-region"

Usage

import { useLiveRegion } from "@hakuna-matata-ui/live-region"

function Example() {
  const region = useLiveRegion()
  return (
    <button
      onClick={() => {
        region.speak("Filtering categories was successful")
      }}
    >
      Click me
    </button>
  )
}

Package Sidebar

Install

npm i @hakuna-matata-ui/live-region

Weekly Downloads

0

Version

1.1.2

License

MIT

Unpacked Size

17.6 kB

Total Files

16

Last publish

Collaborators

  • cryptocom