diff --git a/apps/demo/.eslintrc.js b/apps/demo/.eslintrc.js
index 64a6e29852..63c8f7518e 100644
--- a/apps/demo/.eslintrc.js
+++ b/apps/demo/.eslintrc.js
@@ -1,3 +1,7 @@
module.exports = {
- extends: ["@formbricks/eslint-config/legacy-next.js"],
+ extends: ["@formbricks/eslint-config/next.js"],
+ parserOptions: {
+ project: "tsconfig.json",
+ tsconfigRootDir: __dirname,
+ },
};
diff --git a/apps/demo/components/LayoutApp.tsx b/apps/demo/components/layout-app.tsx
similarity index 68%
rename from apps/demo/components/LayoutApp.tsx
rename to apps/demo/components/layout-app.tsx
index d32aed289e..57703154a4 100644
--- a/apps/demo/components/LayoutApp.tsx
+++ b/apps/demo/components/layout-app.tsx
@@ -1,6 +1,6 @@
-import { Sidebar } from "./Sidebar";
+import { Sidebar } from "./sidebar";
-export const LayoutApp = ({ children }: { children: React.ReactNode }) => {
+export function LayoutApp({ children }: { children: React.ReactNode }): React.JSX.Element {
return (
{/* Static sidebar for desktop */}
@@ -10,4 +10,4 @@ export const LayoutApp = ({ children }: { children: React.ReactNode }) => {
{children}
);
-};
+}
diff --git a/apps/demo/components/Sidebar.tsx b/apps/demo/components/sidebar.tsx
similarity index 97%
rename from apps/demo/components/Sidebar.tsx
rename to apps/demo/components/sidebar.tsx
index 153c9ec4a3..be9f3cd8ed 100644
--- a/apps/demo/components/Sidebar.tsx
+++ b/apps/demo/components/sidebar.tsx
@@ -25,7 +25,7 @@ const secondaryNavigation = [
{ name: "Privacy", href: "#", icon: ShieldCheckIcon },
];
-export const Sidebar = () => {
+export function Sidebar(): React.JSX.Element {
return (
);
-};
+}
diff --git a/apps/demo/lib/utils.ts b/apps/demo/lib/utils.ts
index e514240df6..24e25d3d0e 100644
--- a/apps/demo/lib/utils.ts
+++ b/apps/demo/lib/utils.ts
@@ -1,3 +1,3 @@
-export const classNames = (...classes: any) => {
+export function classNames(...classes: string[]): string {
return classes.filter(Boolean).join(" ");
-};
+}
diff --git a/apps/demo/pages/_app.tsx b/apps/demo/pages/_app.tsx
index e21509444b..e2ba74a494 100644
--- a/apps/demo/pages/_app.tsx
+++ b/apps/demo/pages/_app.tsx
@@ -2,7 +2,7 @@ import type { AppProps } from "next/app";
import Head from "next/head";
import "../globals.css";
-const App = ({ Component, pageProps }: AppProps) => {
+export default function App({ Component, pageProps }: AppProps): React.JSX.Element {
return (
<>
@@ -17,6 +17,4 @@ const App = ({ Component, pageProps }: AppProps) => {
>
);
-};
-
-export default App;
+}
diff --git a/apps/demo/pages/_document.tsx b/apps/demo/pages/_document.tsx
index a25dcfc607..3a10b97bee 100644
--- a/apps/demo/pages/_document.tsx
+++ b/apps/demo/pages/_document.tsx
@@ -1,6 +1,6 @@
import { Head, Html, Main, NextScript } from "next/document";
-const Document = () => {
+export default function Document(): React.JSX.Element {
return (