next-learn icon indicating copy to clipboard operation
next-learn copied to clipboard

Chapter 14 Improving Accessibility - useActionState is not available in React

Open dtknepper opened this issue 1 year ago • 12 comments

Uppon importing useActionState like so: import { useActionState } from 'react';

The following error appears: Module '"react"' has no exported member 'useActionState'.ts(2305)

When searching on Google, the official React Documentation actually says that the useActionState is still an experimental feature in their Canary channel.

I assume this means that when using the stable version of React, this Hook is not available yet and can therefore not be used.

If I am completely wrong on this topic, please explain me what I am doing wrong! I'm not doing this course because I am so good at this all already ;)

dtknepper avatar Jun 29 '24 19:06 dtknepper