examples-es icon indicating copy to clipboard operation
examples-es copied to clipboard

Upgrade nextjs example to NextJS 14

Open smaye81 opened this issue 6 months ago • 5 comments

This updates the example in nextjs to use Next.js v14. A few minor changes to accommodate v14:

  • Accessing dynamic data sources such as cookies is not permitted inside a cache scope, so the getMessages function we use for a fake DB had to be refactored to accept a cookie instead of doing the lookup inside: See https://nextjs.org/docs/app/api-reference/functions/unstable_cache
  • serverActions are no longer experimental and are the default so that was removed from the nextjs config file.

smaye81 avatar Jul 29 '24 17:07 smaye81