Command Palette
Search for a command to run...
Frequently Asked Questions
Answers to common questions about Next.js, shadcn/ui and TypeScript
Next.js App Router is a new routing system introduced in Next.js 13, built on React Server Components. It offers powerful routing capabilities including nested routes, shared layouts, loading states, and error handling. Compared to the traditional Pages Router, it provides a more intuitive file-system based routing structure and better performance optimizations.
shadcn/ui is a customizable UI component library built on Radix UI and Tailwind CSS. Its features include: no runtime dependencies, full customizability, type safety, good accessibility support, and adherence to atomic design principles. Unlike other component libraries, shadcn/ui uses a copy-paste approach, giving you complete control over component code.
TypeScript helps developers catch errors at compile time rather than runtime through static type checking. It provides better code hints and autocompletion, making maintenance of large projects easier. Type definitions also act as documentation, facilitating smoother team collaboration. Additionally, TypeScript integrates well with modern IDEs, offering refactoring tools and code navigation.
There are several ways to implement animations in Next.js: CSS transitions and animations, Framer Motion library, React Spring, etc. Framer Motion is a popular choice as it provides a declarative API supporting complex animation sequences, gesture recognition, and layout animations. For simple interactions, CSS transitions are usually sufficient, while Framer Motion offers more powerful features for complex animations.
Server Components render on the server and don't send JavaScript to the client, reducing client bundle size and improving performance. They can't use browser APIs or React state. Client Components render on the client, can use React state, event handling, and browser APIs, but increase JavaScript sent to the client. In Next.js, components are server components by default and can be made client components with the 'use client' directive.
If you have other questions, feel free to contact our support team
