Default

import React from "react"

Then use as:

React.useState()

Get a function on the default import.

import React from "react"
const { useState } = React

Functions

Import a function like useState or useEffect.

import { useState } from "react"

Combined

Default and named import, from the docs.

import React, { useState } from 'react'