Skip to content

Commit

Permalink
update to tsx example
Browse files Browse the repository at this point in the history
  • Loading branch information
Ocupe committed Nov 6, 2023
1 parent 2150ae0 commit 66da4c2
Show file tree
Hide file tree
Showing 8 changed files with 29,270 additions and 1,659 deletions.
2 changes: 1 addition & 1 deletion examples/nextjs-14/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ bun dev

Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.

You can start editing the page by modifying `app/page.js`. The page auto-updates as you edit the file.
You can start editing the page by modifying `app/page.tsx`. The page auto-updates as you edit the file.

This project uses [`next/font`](https://nextjs.org/docs/basic-features/font-optimization) to automatically optimize and load Inter, a custom Google Font.

Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,19 @@
import type { Metadata } from 'next'
import { Inter } from 'next/font/google'
import './globals.css'

const inter = Inter({ subsets: ['latin'] })

export const metadata = {
export const metadata: Metadata = {
title: 'Create Next App',
description: 'Generated by create next app',
}

export default function RootLayout({ children }) {
export default function RootLayout({
children,
}: {
children: React.ReactNode
}) {
return (
<html lang="en">
<body className={inter.className}>{children}</body>
Expand Down
File renamed without changes.
7 changes: 0 additions & 7 deletions examples/nextjs-14/jsconfig.json

This file was deleted.

8 changes: 6 additions & 2 deletions examples/nextjs-14/package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "@livekit/component-example-next-14",
"name": "nextjs-14",
"version": "0.1.0",
"private": true,
"scripts": {
Expand All @@ -17,7 +17,11 @@
"react-dom": "^18"
},
"devDependencies": {
"@types/node": "^20",
"@types/react": "^18",
"@types/react-dom": "^18",
"eslint": "^8",
"eslint-config-next": "14.0.1"
"eslint-config-next": "14.0.1",
"typescript": "^5"
}
}
27 changes: 27 additions & 0 deletions examples/nextjs-14/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"compilerOptions": {
"target": "es5",
"lib": ["dom", "dom.iterable", "esnext"],
"allowJs": true,
"skipLibCheck": true,
"strict": true,
"noEmit": true,
"esModuleInterop": true,
"module": "esnext",
"moduleResolution": "bundler",
"resolveJsonModule": true,
"isolatedModules": true,
"jsx": "preserve",
"incremental": true,
"plugins": [
{
"name": "next"
}
],
"paths": {
"@/*": ["./*"]
}
},
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"],
"exclude": ["node_modules"]
}
Loading

0 comments on commit 66da4c2

Please sign in to comment.