我正在为我的 Next js 应用程序创建一个登录方法,并使用 GitHub 存储库提供的推荐文档。
但是,当我到达 auth 文件夹步骤时,我收到此错误。对于登录提供商。
在 [...nextauth].ts 中
This expression is not callable.
Type 'typeof import("/Users/farishtawazir/Desktop/template/next-auth")' has no call signatures.ts(2349)
Run Code Online (Sandbox Code Playgroud)
我不明白为什么,因为我已按照文档进行操作,但仍然收到此错误
这是文件代码
import NextAuth from 'next-auth'
import Auth0Provider from 'next-auth/providers/auth0'
import FacebookProvider from 'next-auth/providers/facebook'
import GithubProvider from 'next-auth/providers/github'
import GoogleProvider from 'next-auth/providers/google'
import TwitterProvider from 'next-auth/providers/twitter'
// import AppleProvider from "next-auth/providers/apple"
// import EmailProvider from "next-auth/providers/email"
// For more information on each option (and a full list of options) go to
// https://next-auth.js.org/configuration/options
export default NextAuth({ …Run Code Online (Sandbox Code Playgroud)