---
title: "Discussion on \"A simple way to manage global DOM events in React with hooks\" | Hashnode"
description: "Discussion on \"A simple way to manage global DOM events in React with hooks\". Creating UI components like dialog, modal, or drawers mostly requires adding keyboard accessibilities like closing them when ESC (escape) key is pressed, and doing that may require you to attach an event listener for keyup event inside use useEffect ..."
url: "https://hashnode.com/posts/a-simple-way-to-manage-global-dom-events-in-react-with-hooks/5fa826d7774df85ae0e48783"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [A simple way to manage global DOM events in React with hooks](https://akumzy.hashnode.dev/a-simple-way-to-manage-global-dom-events-in-react-with-hooks?utm_source=hashnode&utm_medium=feed)

Creating UI components like dialog, modal, or drawers mostly requires adding keyboard accessibilities like closing them when ESC (escape) key is pressed, and doing that may require you to attach an event listener for keyup event inside use useEffect ...

Nov 8, 2020 · 4 min read · akumzy.hashnode.dev  
Read the article

-   [#reactjs](https://hashnode.com/tag/reactjs)
-   [#typescript](https://hashnode.com/tag/typescript)
-   [#javascript](https://hashnode.com/tag/javascript)
-   [#react-hook-1](https://hashnode.com/tag/react-hook-1)

## Written by

[Akuma Isaac Akuma](https://hashnode.com/@Akumzy)

@Akumzy

  
[View profile](https://hashnode.com/@Akumzy)

Software Developer

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
