Debug 2
This commit is contained in:
parent
fa34440087
commit
89373c84f8
23
my-favorites-app/next.config.mjs
Normal file
23
my-favorites-app/next.config.mjs
Normal file
@ -0,0 +1,23 @@
|
||||
/** @type {import('next').NextConfig} */
|
||||
const nextConfig = {
|
||||
// Disable the standalone output for now to simplify deployment
|
||||
// output: 'standalone',
|
||||
images: {
|
||||
domains: [
|
||||
'm.media-amazon.com',
|
||||
'i.scdn.co',
|
||||
'www.moma.org'
|
||||
],
|
||||
remotePatterns: [
|
||||
{
|
||||
protocol: 'https',
|
||||
hostname: '**',
|
||||
},
|
||||
],
|
||||
unoptimized: true, // This can help with deployment issues
|
||||
},
|
||||
// Enable strict mode for better development experience
|
||||
reactStrictMode: true,
|
||||
};
|
||||
|
||||
export default nextConfig;
|
||||
16
my-favorites-app/nixpacks.toml
Normal file
16
my-favorites-app/nixpacks.toml
Normal file
@ -0,0 +1,16 @@
|
||||
[phases.setup]
|
||||
nixPkgs = ["nodejs", "nodejs.pkgs.pnpm"]
|
||||
|
||||
[phases.install]
|
||||
cmds = ["npm ci"]
|
||||
|
||||
[phases.build]
|
||||
cmds = ["npm run build"]
|
||||
|
||||
[start]
|
||||
cmd = "npm start"
|
||||
|
||||
[variables]
|
||||
NODE_ENV = "production"
|
||||
PORT = "3000"
|
||||
HOST = "0.0.0.0"
|
||||
@ -3,25 +3,39 @@
|
||||
"version": "0.1.0",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"dev": "next dev --turbopack",
|
||||
"dev": "next dev",
|
||||
"build": "next build",
|
||||
"start": "next start",
|
||||
"start": "NODE_ENV=production node server.js",
|
||||
"lint": "next lint"
|
||||
},
|
||||
"dependencies": {
|
||||
"react": "^19.0.0",
|
||||
"react-dom": "^19.0.0",
|
||||
"next": "15.3.1"
|
||||
"@radix-ui/react-dialog": "^1.0.5",
|
||||
"@radix-ui/react-dropdown-menu": "^2.0.6",
|
||||
"@radix-ui/react-slot": "^1.0.2",
|
||||
"@supabase/auth-helpers-nextjs": "^0.9.0",
|
||||
"@supabase/supabase-js": "^2.39.7",
|
||||
"class-variance-authority": "^0.7.0",
|
||||
"clsx": "^2.1.0",
|
||||
"date-fns": "^3.3.1",
|
||||
"lucide-react": "^0.358.0",
|
||||
"next": "14.1.0",
|
||||
"react": "^18.2.0",
|
||||
"react-dom": "^18.2.0",
|
||||
"tailwind-merge": "^2.2.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"typescript": "^5",
|
||||
"@types/node": "^20",
|
||||
"@types/react": "^19",
|
||||
"@types/react-dom": "^19",
|
||||
"@tailwindcss/postcss": "^4",
|
||||
"tailwindcss": "^4",
|
||||
"eslint": "^9",
|
||||
"eslint-config-next": "15.3.1",
|
||||
"@eslint/eslintrc": "^3"
|
||||
"@eslint/eslintrc": "^3.0.2",
|
||||
"@types/node": "^20.11.25",
|
||||
"@types/react": "^18.2.64",
|
||||
"@types/react-dom": "^18.2.21",
|
||||
"autoprefixer": "^10.4.18",
|
||||
"eslint": "^8.57.0",
|
||||
"eslint-config-next": "14.1.0",
|
||||
"postcss": "^8.4.35",
|
||||
"tailwindcss": "^3.4.1",
|
||||
"typescript": "^5.4.2"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=18.0.0"
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,9 +1,31 @@
|
||||
import { FavoritesGrid } from '@/components/FavoritesGrid';
|
||||
import { getFavorites } from '@/lib/supabase';
|
||||
import { type Favorite } from '@/lib/supabase';
|
||||
|
||||
export default async function Home() {
|
||||
const favorites = await getFavorites();
|
||||
|
||||
// Mock data for initial deployment testing
|
||||
const mockFavorites: Favorite[] = [
|
||||
{
|
||||
id: '1',
|
||||
title: 'The Lord of the Rings',
|
||||
author: 'J.R.R. Tolkien',
|
||||
consumption_date: '2025-03-15',
|
||||
type: 'book',
|
||||
cover_image: 'https://m.media-amazon.com/images/I/71jLBXtWJWL._AC_UF1000,1000_QL80_.jpg',
|
||||
created_at: '2025-03-20T12:00:00Z',
|
||||
updated_at: '2025-03-20T12:00:00Z'
|
||||
},
|
||||
{
|
||||
id: '2',
|
||||
title: 'Inception',
|
||||
author: 'Christopher Nolan',
|
||||
consumption_date: '2025-02-10',
|
||||
type: 'movie',
|
||||
cover_image: 'https://m.media-amazon.com/images/M/MV5BMjAxMzY3NjcxNF5BMl5BanBnXkFtZTcwNTI5OTM0Mw@@._V1_.jpg',
|
||||
created_at: '2025-02-15T12:00:00Z',
|
||||
updated_at: '2025-02-15T12:00:00Z'
|
||||
}
|
||||
];
|
||||
|
||||
export default function Home() {
|
||||
return (
|
||||
<div className="space-y-6">
|
||||
<div className="space-y-2">
|
||||
@ -12,7 +34,7 @@ export default async function Home() {
|
||||
A collection of books, movies, series, and more that have made an impression on me.
|
||||
</p>
|
||||
</div>
|
||||
<FavoritesGrid favorites={favorites} />
|
||||
<FavoritesGrid favorites={mockFavorites} />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user