web sr announcer

A small library for deal with hidden aria-lives to announce messages to users that are using screen readers.

npm install web_sr_announcer

Code Example

			import webSrAnnouncer from "web_sr_announcer"
webSrAnnouncer.initialize()
// just the message is needed.
webSrAnnouncer.announce('this is a test with default params')

// using all params.
webSrAnnouncer.announce('this is a test', 'polite', 3000)

References

Aria live documentation

demo