Skip to content

Commit

Permalink
fix: Add default exports to next-auth's package.json for better modul…
Browse files Browse the repository at this point in the history
…e support
  • Loading branch information
FckYeah committed Jun 25, 2024
1 parent d00d913 commit 4f788b7
Showing 1 changed file with 24 additions and 17 deletions.
41 changes: 24 additions & 17 deletions packages/next-auth/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,23 @@
"exports": {
".": {
"types": "./index.d.ts",
"import": "./index.js"
"import": "./index.js",
"default": "./index.js"
},
"./jwt": {
"types": "./jwt.d.ts",
"import": "./jwt.js"
"import": "./jwt.js",
"default": "./jwt.js"
},
"./middleware": {
"types": "./middleware.d.ts",
"import": "./middleware.js"
"import": "./middleware.js",
"default": "./middleware.js"
},
"./next": {
"types": "./next.d.ts",
"import": "./next.js"
"import": "./next.js",
"default": "./next.js"
},
"./providers": {
"types": "./providers/index.d.ts"
Expand All @@ -37,15 +41,18 @@
},
"./providers/*": {
"types": "./providers/*.d.ts",
"import": "./providers/*.js"
"import": "./providers/*.js",
"default": "./providers/*.js"
},
"./react": {
"types": "./react.d.ts",
"import": "./react.js"
"import": "./react.js",
"default": "./react.js"
},
"./webauthn": {
"types": "./webauthn.d.ts",
"import": "./webauthn.js"
"import": "./webauthn.js",
"default": "./webauthn.js"
},
"./package.json": "./package.json"
},
Expand All @@ -61,14 +68,6 @@
"oidc",
"nextauth"
],
"scripts": {
"build": "pnpm clean && pnpm providers && tsc",
"clean": "rm -rf *.js *.d.ts* lib providers",
"dev": "pnpm providers && tsc -w",
"test": "vitest run -c ../utils/vitest.config.ts",
"test:watch": "vitest -c ../utils/vitest.config.ts",
"providers": "node ../utils/scripts/providers"
},
"files": [
"*.d.ts*",
"*.js",
Expand All @@ -78,12 +77,12 @@
],
"license": "ISC",
"dependencies": {
"@auth/core": "workspace:*"
"@auth/core": "0.32.0"
},
"peerDependencies": {
"@simplewebauthn/browser": "^9.0.1",
"@simplewebauthn/server": "^9.0.2",
"next": "^14.0.0-0 || ^15.0.0-0",
"next": "^14 || ^15.0.0-0",
"nodemailer": "^6.6.5",
"react": "^18.2.0 || ^19.0.0-0"
},
Expand All @@ -103,5 +102,13 @@
"next": "14.2.3",
"nodemailer": "^6.9.3",
"react": "^18.2.0"
},
"scripts": {
"build": "pnpm clean && pnpm providers && tsc",
"clean": "rm -rf *.js *.d.ts* lib providers",
"dev": "pnpm providers && tsc -w",
"test": "vitest run -c ../utils/vitest.config.ts",
"test:watch": "vitest -c ../utils/vitest.config.ts",
"providers": "node ../utils/scripts/providers"
}
}

0 comments on commit 4f788b7

Please sign in to comment.