fullstack-graphql-next-nexus-prisma icon indicating copy to clipboard operation
fullstack-graphql-next-nexus-prisma copied to clipboard

Error when using latest Nexus an Prisma

Open fullStackDataSolutions opened this issue 4 years ago • 0 comments

Hey I'm using the latest version of Nexus and Prisma, see below:

  "dependencies": {
    "@apollo/client": "^3.3.19",
    "@apollo/react-hooks": "^4.0.0",
    "@apollo/react-ssr": "^4.0.0",
    "@auth0/nextjs-auth0": "^1.3.1",
    "@prisma/client": "^2.23.0",
    "apollo-server-micro": "^2.25.0",
    "deepmerge": "^4.2.2",
    "dotenv": "^10.0.0",
    "graphql": "^15.5.0",
    "micro-cors": "^0.1.1",
    "next": "10.2.2",
    "nexus": "^1.0.0",
    "nexus-plugin-prisma": "^0.35.0",
    "react": "17.0.2",
    "react-dom": "17.0.2"
  },
  "devDependencies": {
    "@types/node": "^15.6.0",
    "@types/react": "^17.0.6",
    "eslint-config-prettier": "^8.3.0",
    "eslint-plugin-prettier": "^3.4.0",
    "prettier": "^2.3.0",
    "prisma": "^2.23.0",
    "typescript": "^4.3.2"

I get the following error:

./node_modules/.prisma/client/index.d.ts
Module parse failed: Unexpected token (7:8)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See https://webpack.js.org/concepts#loaders
| 
| import * as runtime from '@prisma/client/runtime';
> declare const prisma: unique symbol
| export type PrismaPromise<A> = Promise<A> & {[prisma]: true}
| type UnwrapPromise<P extends any> = P extends Promise<infer R> ? R : P

I've used Nexus and Prisma to do around 20 servers and never had issues, but they where all stand alone servers without using next. Any ideas what may be causing this error?

fullStackDataSolutions avatar May 31 '21 08:05 fullStackDataSolutions