Skip to content

@graphql-codegen/client-preset-swc-plugin ... #9450

Open
@huv1k

Description

@huv1k

Which packages are impacted by your issue?

@graphql-codegen/client-preset

Describe the bug

New @graphql-codegen/client-preset and @graphql-codegen/client-preset-swc-plugin doesn't work with the latest Next.js version. It panics when trying to build or run a development server and it crashes. When using the old babel plugin there wasn't such a problem. I know it's still early in development, but sadly it doesn't work.

Your Example Website or App

https://github.com/huv1k/nextjs-auth-prisma

Steps to Reproduce the Bug or Issue

  1. Clone https://github.com/huv1k/nextjs-auth-prisma
  2. Install dependencies using yarn install
  3. Run yarn dev or yarn build
  4. Process panicked

Expected behavior

I would expect the build to finish or the dev server to start, but it crashes.

Screenshots or Videos

CleanShot 2023-05-22 at 13 35 50@2x

Platform

  • OS: macOS 13.0.1
  • NodeJS: 18.16.0
  • graphql version: 16.6.0
  • @graphql-codegen/cli: 3.3.0
  • @graphql-codegen/client-preset: 3.0.1
  • @graphql-codegen/client-preset-swc-plugin: 0.2.0

Codegen Config File

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    stage/0-issue-prerequisitesNeeds more information before we can start working on it

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions