Simplify your stack and build anything. Or everything.
Build tomorrow’s web with a modern solution you truly own.
Code-based nature means you can build on top of it to power anything.
It’s time to take back your content infrastructure.

'slugify' is not exported from 'payload/shared' when deploying on vercel

default discord avatar
alejotoro_o7 months ago
2

As the title says, i am trying to deploy on vercel and getting various errors:



./node_modules/@payloadcms/plugin-cloud-storage/node_modules/@payloadcms/ui/dist/exports/client/index.js



Attempted import error: 'slugify' is not exported from 'payload/shared' (imported as 'aq').

  • discord user avatar
    alessiogr
    7 months ago

    Could be a dependency issue. Check out

    https://payloadcms.com/docs/troubleshooting/troubleshooting#fixing-depedendency-issues

    (make sure all payload packages are on the same version)

  • default discord avatar
    alejotoro_o7 months ago

    They are all the same version



    When i run npm run build it builds correcly



    The issue is on vercel



    When i updated to version 3.59.1 i started getting this error:



    Type '{ [k: string]: unknown; type: string; version: number; }' is not assignable to type '{ children?: ({ children?: ({ children?: ({ children?: DefaultNodeTypes[] | undefined; } & DefaultNodeTypes)[] | undefined; } & DefaultNodeTypes)[] | undefined; } & DefaultNodeTypes)[] | undefined; } & DefaultNodeTypes'.


    Type '{ [k: string]: unknown; type: string; version: number; }' is not assignable to type '{ children?: ({ children?: ({ children?: ({ children?: DefaultNodeTypes[] | undefined; } & DefaultNodeTypes)[] | undefined; } & DefaultNodeTypes)[] | undefined; } & DefaultNodeTypes)[] | undefined; } & Omit<...> & { ...; }'.


    Type '{ [k: string]: unknown; type: string; version: number; }' is missing the following properties from type 'Omit<SerializedListNode, "type" | "checked">': children, start, direction, format, and 3 more.


    133 | </div>


    134 | <Separator className='max-w-[48rem] mx-auto my-5' />


    135 | <RichText className="max-w-[48rem] mx-auto" data={post.content} enableGutter={false} />


    | ^


    136 | {post.relatedPosts && post.relatedPosts.length > 0 && (


    137 | <div>


    138 | <h2 className='mt-12 lg:container'>Artículos relacionados</h2>


    Next.js build worker exited with code: 1 and signal: null


    Error: Command "npm run ci" exited with 1



    It is something with vercel because it works locally

Star on GitHub

Star

Chat on Discord

Discord

online

Can't find what you're looking for?

Get dedicated engineering support directly from the Payload team.