Library: /vercel/next.js ### Next.js Overview and Core Concepts Source: https://github.com/vercel/next.js/blob/canary/docs/index.mdx The main documentation index page describing what Next.js is, its two routers (App Router and Pages Router), and key features like Server Components, Suspense, and Server Functions. It explains that Next.js is a React framework for building full-stack web applications that automatically configures lower-level tools like bundlers and compilers. ```markdown ## What is Next.js? Next.js is a React framework for building full-stack web applications. You use React Components to build user interfaces, and Next.js for additional features and optimizations. It also automatically configures lower-level tools like bundlers and compilers. You can instead focus on building your product and shipping quickly. Whether you're an individual developer or part of a larger team, Next.js can help you build interactive, dynamic, and fast React applications. ``` ### Next.js Docs > What is Next.js? Source: https://github.com/vercel/next.js/blob/canary/docs/index.mdx Next.js is a React framework for building full-stack web applications. You use React Components to build user interfaces, and Next.js for additional features and optimizations. It also automatically configures lower-level tools like bundlers and compilers. You can instead focus on building your product and shipping quickly. Whether you're an individual developer or part of a larger team, Next.js can help you build interactive, dynamic, and fast React applications. --- Library: /websites/nextjs ### next(options) Source: https://nextjs.org/docs/pages/guides/custom-server Initializes a Next.js server instance with custom configuration options. The returned app instance handles incoming HTTP requests as required. ```APIDOC ### next(options) ### Description Initializes a custom Next.js server instance. ### Parameters - **conf** (Object) - Optional. The same object you would use in `next.config.js`. Defaults to `{}`. - **dev** (Boolean) - Optional. Whether or not to launch Next.js in dev mode. Defaults to `false`. - **dir** (String) - Optional. Location of the Next.js project. Defaults to `'.'`. - **quiet** (Boolean) - Optional. Hide error messages containing server information. Defaults to `false`. - **hostname** (String) - Optional. The hostname the server is running behind. - **port** (Number) - Optional. The port the server is running behind. - **httpServer** (node:http#Server) - Optional. The HTTP Server that Next.js is running behind. - **turbopack** (Boolean) - Optional. Enable Turbopack (enabled by default). - **webpack** (Boolean) - Optional. Enable webpack. ### Returns - **app** - The Next.js application instance used to handle requests. ``` --- Library: /vercel/next.js ### Next.js Docs > Join our Community Source: https://github.com/vercel/next.js/blob/canary/docs/index.mdx If you have questions about anything related to Next.js, you're always welcome to ask our community on [GitHub Discussions](https://github.com/vercel/next.js/discussions), [Discord](https://discord.com/invite/bUG2bvbtHy), [X (Twitter)](https://x.com/nextjs), and [Reddit](https://www.reddit.com/r/nextjs). ### Next.js Docs > App Router and Pages Router Source: https://github.com/vercel/next.js/blob/canary/docs/index.mdx Next.js has two different routers: - **App Router**: The newer router that supports new React features like Server Components. - **Pages Router**: The original router, still supported and being improved. At the top of the sidebar, you'll notice a dropdown menu that allows you to switch between the [App Router](/docs/app) and the [Pages Router](/docs/pages) docs.