DEV Community

loading...

Discussion on: Using React Hooks "useState"

Collapse
plake492 profile image
Patrick Lake

On the import, you can also simply do this:

Import React, {useState} from "react "

this is especially nice when you start adding other hooks like useEffect, useReducer, etc.

Collapse
yahaya_hk profile image
Forem Open with the Forem app