test news
❌ tRPC failed on blog.create:
Invalid ctx.db.blogPost.create() invocation in
/Users/leocromwel/Desktop/DEV/supa-estates-front/.next/server/chunks/[root of the server]__ddf086._.js:2448:32
2445 "news" 2446 ]).default("blog") 2447 })).mutation(async ({ ctx, input })=>{ → 2448 return ctx.db.blogPost.create({ data: { title: "test news", slug: "test-news", content: "You are an expert in TypeScript, Node.js, Next.js App Router, React, Shadcn UI, Radix UI and Tailwind.\n\nYou actually are in a t3 stack project (you can always check de the documentation "t3 structure" in the context).\n \n Very Important: Always comment and code in English regardless of the language of the query.\n Important: Always respond in English, regardless of the language of the query.\n\n Code Style and Structure\n - Write concise, technical TypeScript code with accurate examples.\n - Use functional and declarative programming patterns; avoid classes.\n - Prefer iteration and modularization over code duplication.\n - Use descriptive variable names with auxiliary verbs (e.g., isLoading, hasError).\n - Structure files: exported component, subcomponents, helpers, static content, types.\n \n Naming Conventions\n - Use lowercase with dashes for directories (e.g., components/auth-wizard).\n - Favor named exports for components.\n \n TypeScript Usage\n - Use TypeScript for all code; prefer interfaces over types.\n - Avoid enums; use maps instead.\n - Use functional components with TypeScript interfaces.\n \n Syntax and Formatting\n - Use the "function" keyword for pure functions.\n - Avoid unnecessary curly braces in conditionals; use concise syntax for simple statements.\n - Use declarative JSX.\n \n UI and Styling\n - Use Shadcn UI, Radix, and Tailwind for components and styling.\n - Implement responsive design with Tailwind CSS; use a mobile-first approach.\n \n Performance Optimization\n - Minimize 'use client', 'useEffect', and 'setState'; favor React Server Components (RSC).\n - Wrap client components in Suspense with fallback.\n - Use dynamic loading for non-critical components.\n - Optimize images: use WebP format, include size data, implement lazy loading.\n \n Key Conventions\n - Use 'nuqs' for URL search parameter state management.\n - Optimize Web Vitals (LCP, CLS, FID).\n - Limit 'use client':\n - Favor server components and Next.js SSR.\n - Use only for Web API access in small components.\n - Avoid for data fetching or state management.\n \n Follow t3 structure doc for Data Fetching, Rendering, and Routing.", excerpt: "testtesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttest", coverImage: "https://s2-techtudo.glbimg.com/Mk1Js8w-XCRu35d1fkvXQxjuzJs=/0x0:1200x675/984x0/smart/filters:strip_icc()/i.s3.glbimg.com/v1/AUTH_08fbf48bc0524877943fe86e43087e7a/internal_photos/bs/2023/R/F/j33isEQU69iUiObx7jPg/grand-theft-auto-6-gta-6-vs-gta-5-comparacao-video-youtuber-ponte.jpg", category: "Neighborhood Guide", tags: [ "Bangkok" ], published: false, type: "news", ~~~~ publishedAt: null, ? createdAt?: DateTime, ? updatedAt?: DateTime } })
Unknown argument type. Did you mean title? Available options are marked with ?.
ok
bonjour
sympa l'image!