-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #250 from kinde-oss/chore/prettier-update
chore: pretter run
- Loading branch information
Showing
90 changed files
with
1,050 additions
and
1,032 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,30 @@ | ||
const packageJson = require('./package.json'); | ||
const packageJson = require("./package.json"); | ||
|
||
import babel from '@rollup/plugin-babel'; | ||
import {terser} from 'rollup-plugin-terser'; | ||
import tsPlugin from '@rollup/plugin-typescript'; | ||
import babel from "@rollup/plugin-babel"; | ||
import { terser } from "rollup-plugin-terser"; | ||
import tsPlugin from "@rollup/plugin-typescript"; | ||
|
||
export default { | ||
plugins: [babel({babelHelpers: 'bundled'}), terser(), tsPlugin()], | ||
input: './src/index.ts', | ||
plugins: [babel({ babelHelpers: "bundled" }), terser(), tsPlugin()], | ||
input: "./src/index.ts", | ||
output: [ | ||
{ | ||
file: packageJson.module, | ||
format: 'esm', | ||
format: "esm", | ||
sourcemap: true, | ||
exports: 'named' | ||
exports: "named", | ||
}, | ||
{ | ||
file: packageJson.main, | ||
format: 'cjs', | ||
format: "cjs", | ||
sourcemap: true, | ||
exports: 'named' | ||
} | ||
exports: "named", | ||
}, | ||
], | ||
external: [ | ||
'react', | ||
'react-dom', | ||
'@kinde-oss/kinde-typescript-sdk', | ||
'@kinde/jwt-decoder' | ||
] | ||
"react", | ||
"react-dom", | ||
"@kinde-oss/kinde-typescript-sdk", | ||
"@kinde/jwt-decoder", | ||
], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,23 @@ | ||
import babel from '@rollup/plugin-babel'; | ||
import {terser} from 'rollup-plugin-terser'; | ||
import tsPlugin from '@rollup/plugin-typescript'; | ||
import babel from "@rollup/plugin-babel"; | ||
import { terser } from "rollup-plugin-terser"; | ||
import tsPlugin from "@rollup/plugin-typescript"; | ||
|
||
export default { | ||
plugins: [babel({babelHelpers: 'bundled'}), terser(), tsPlugin()], | ||
input: 'src/components/index.js', | ||
plugins: [babel({ babelHelpers: "bundled" }), terser(), tsPlugin()], | ||
input: "src/components/index.js", | ||
output: [ | ||
{ | ||
file: 'dist/components/cjs/index.js', | ||
format: 'cjs', | ||
file: "dist/components/cjs/index.js", | ||
format: "cjs", | ||
sourcemap: true, | ||
exports: 'named' | ||
exports: "named", | ||
}, | ||
{ | ||
file: `dist/components/index.js`, | ||
sourcemap: true, | ||
exports: 'named', | ||
format: 'esm' | ||
} | ||
exports: "named", | ||
format: "esm", | ||
}, | ||
], | ||
external: ['react', '@kinde-oss/kinde-typescript-sdk'] | ||
external: ["react", "@kinde-oss/kinde-typescript-sdk"], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
/** @type {import('ts-jest').JestConfigWithTsJest} */ | ||
module.exports = { | ||
preset: 'ts-jest', | ||
testEnvironment: 'jsdom', | ||
preset: "ts-jest", | ||
testEnvironment: "jsdom", | ||
transform: { | ||
'^.+\\.(ts|tsx)?$': 'ts-jest', | ||
'^.+\\.(js|jsx)$': 'babel-jest' | ||
"^.+\\.(ts|tsx)?$": "ts-jest", | ||
"^.+\\.(js|jsx)$": "babel-jest", | ||
}, | ||
moduleNameMapper: { | ||
uncrypto: 'uncrypto' | ||
} | ||
uncrypto: "uncrypto", | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,27 @@ | ||
import babel from '@rollup/plugin-babel'; | ||
import {terser} from 'rollup-plugin-terser'; | ||
import tsPlugin from '@rollup/plugin-typescript'; | ||
import babel from "@rollup/plugin-babel"; | ||
import { terser } from "rollup-plugin-terser"; | ||
import tsPlugin from "@rollup/plugin-typescript"; | ||
|
||
export default { | ||
plugins: [babel({babelHelpers: 'bundled'}), terser(), tsPlugin()], | ||
input: 'src/middleware/index.js', | ||
plugins: [babel({ babelHelpers: "bundled" }), terser(), tsPlugin()], | ||
input: "src/middleware/index.js", | ||
output: [ | ||
{ | ||
file: 'dist/middleware/cjs/index.js', | ||
format: 'cjs', | ||
file: "dist/middleware/cjs/index.js", | ||
format: "cjs", | ||
sourcemap: true, | ||
exports: 'named' | ||
exports: "named", | ||
}, | ||
{ | ||
file: `dist/middleware/index.js`, | ||
sourcemap: true, | ||
exports: 'named', | ||
format: 'esm' | ||
} | ||
exports: "named", | ||
format: "esm", | ||
}, | ||
], | ||
external: [ | ||
'@kinde-oss/kinde-typescript-sdk', | ||
'next/server', | ||
'@kinde/jwt-decoder' | ||
] | ||
"@kinde-oss/kinde-typescript-sdk", | ||
"next/server", | ||
"@kinde/jwt-decoder", | ||
], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
import {handleAuth} from '@kinde-oss/kinde-auth-nextjs/server'; | ||
import { handleAuth } from "@kinde-oss/kinde-auth-nextjs/server"; | ||
|
||
export const GET = handleAuth(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
import {getKindeServerSession} from '@kinde-oss/kinde-auth-nextjs/server'; | ||
import {NextResponse} from 'next/server'; | ||
import { getKindeServerSession } from "@kinde-oss/kinde-auth-nextjs/server"; | ||
import { NextResponse } from "next/server"; | ||
|
||
export async function GET() { | ||
const {getUser, isAuthenticated} = getKindeServerSession(); | ||
const { getUser, isAuthenticated } = getKindeServerSession(); | ||
|
||
if (!(await isAuthenticated())) { | ||
return new Response('Unauthorized', {status: 401}); | ||
return new Response("Unauthorized", { status: 401 }); | ||
} | ||
|
||
const user = await getUser(); | ||
const data = {message: 'Hello User', id: user?.given_name}; | ||
const data = { message: "Hello User", id: user?.given_name }; | ||
|
||
return NextResponse.json({data}); | ||
return NextResponse.json({ data }); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
import {NextResponse} from 'next/server'; | ||
import { NextResponse } from "next/server"; | ||
|
||
export async function GET() { | ||
const data = {message: 'Hello world'}; | ||
const data = { message: "Hello world" }; | ||
|
||
return NextResponse.json({data}); | ||
return NextResponse.json({ data }); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
import Link from 'next/link'; | ||
import Link from "next/link"; | ||
|
||
export default function Home() { | ||
return ( | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
import {withAuth} from '@kinde-oss/kinde-auth-nextjs/middleware'; | ||
import { withAuth } from "@kinde-oss/kinde-auth-nextjs/middleware"; | ||
|
||
export default function middleware(req: Request) { | ||
return withAuth(req); | ||
} | ||
|
||
export const config = { | ||
matcher: ['/dashboard'] | ||
matcher: ["/dashboard"], | ||
}; |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
packages: | ||
- 'playground' | ||
- "playground" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
import clientConfig from './clientConfig/rollup.config.js'; | ||
import serverConfig from './serverConfig/rollup.config.js'; | ||
import componentConfig from './componentConfig/rollup.config.js'; | ||
import middlewareConfig from './middlewareConfig/rollup.config.js'; | ||
import clientConfig from "./clientConfig/rollup.config.js"; | ||
import serverConfig from "./serverConfig/rollup.config.js"; | ||
import componentConfig from "./componentConfig/rollup.config.js"; | ||
import middlewareConfig from "./middlewareConfig/rollup.config.js"; | ||
|
||
export default [clientConfig, serverConfig, componentConfig, middlewareConfig]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,30 @@ | ||
import babel from '@rollup/plugin-babel'; | ||
import {terser} from 'rollup-plugin-terser'; | ||
import tsPlugin from '@rollup/plugin-typescript'; | ||
import babel from "@rollup/plugin-babel"; | ||
import { terser } from "rollup-plugin-terser"; | ||
import tsPlugin from "@rollup/plugin-typescript"; | ||
|
||
export default { | ||
plugins: [babel({babelHelpers: 'bundled'}), terser(), tsPlugin()], | ||
input: 'src/server/index.js', | ||
plugins: [babel({ babelHelpers: "bundled" }), terser(), tsPlugin()], | ||
input: "src/server/index.js", | ||
output: [ | ||
{ | ||
file: 'dist/server/cjs/index.js', | ||
format: 'cjs', | ||
file: "dist/server/cjs/index.js", | ||
format: "cjs", | ||
sourcemap: true, | ||
exports: 'named' | ||
exports: "named", | ||
}, | ||
{ | ||
file: `dist/server/index.js`, | ||
sourcemap: true, | ||
exports: 'named', | ||
format: 'esm' | ||
} | ||
exports: "named", | ||
format: "esm", | ||
}, | ||
], | ||
external: [ | ||
'next/server', | ||
'next/navigation', | ||
'next/headers', | ||
'react', | ||
'@kinde-oss/kinde-typescript-sdk', | ||
'@kinde/jwt-decoder' | ||
] | ||
"next/server", | ||
"next/navigation", | ||
"next/headers", | ||
"react", | ||
"@kinde-oss/kinde-typescript-sdk", | ||
"@kinde/jwt-decoder", | ||
], | ||
}; |
Oops, something went wrong.