0 votes
in ReactJS by
What is an event in React?

1 Answer

0 votes
by

An event is an action that a user or system may trigger, such as pressing a key, a mouse click, etc.

React events are named using camelCase, rather than lowercase in HTML.

With JSX, you pass a function as the event handler, rather than a string in HTML.

<Button onPress={lightItUp} />

Related questions

0 votes
asked Jul 2, 2019 in ReactJS by Venkatshastri
0 votes
asked Mar 2, 2020 in ReactJS by RShastri
...