usestate is not defined react functional component code example Example: 'useState' is not defined import React, {useState} from 'react';