remix README

The project's README from github.com/remix-run/remix. As one markdown file: README.md.



Remix



Welcome to Remix 3!

This is the source repository for Remix 3. It is under active development.

We published a blog post earlier this year with some of our thoughts around Remix 3. It explains our philosophy for web development and why we think the time is right for something new. When working on Remix 3, we follow these principles:

  1. Model-First Development. AI fundamentally shifts the human-computer interaction model for both user experience and developer workflows. Optimize the source code, documentation, tooling, and abstractions for LLMs. Additionally, develop abstractions for applications to use models in the product itself, not just as a tool to develop it.
  2. Build on Web APIs. Sharing abstractions across the stack greatly reduces the amount of context switching, both for humans and machines. Build on the foundation of Web APIs and JavaScript because it is the only full stack ecosystem.
  3. Religiously Runtime. Designing for bundlers/compilers/typegen (and any pre-runtime static analysis) leads to poor API design that eventually pollutes the entire system. All packages must be designed with no expectation of static analysis and all tests must run without bundling. Because browsers are involved, --import loaders for simple transformations like TypeScript and JSX are permissible.
  4. Avoid Dependencies. Dependencies lock you into somebody else's roadmap. Choose them wisely, wrap them completely, and expect to replace most of them with our own package eventually. The goal is zero.
  5. Demand Composition. Abstractions should be single-purpose and replaceable. A composable abstraction is easy to add and remove from an existing program. Every package must be useful and documented independent of any other context. New features should first be attempted as a new package. If impossible, attempt to break up the existing package to make it more composable. However, tightly coupled modules that almost always change together in both directions should be moved to the same package.
  6. Distribute Cohesively. Extremely composable ecosystems are difficult to learn and use. Remix will be distributed as a single remix package for both distribution and documentation.

Goals

Although we recommend the remix package for ease of use, all packages that make up Remix should be usable standalone as well. This forces us to consider package boundaries and helps us define public interfaces that are portable and interoperable.

Each package in Remix:

This means Remix code is portable by default. Remix packages work seamlessly across Node.js, Bun, Deno, Cloudflare Workers, and other environments.

We leverage server-side web APIs when they are available:

The benefit is code that's not just reusable, but future-proof.

Packages

Most packages in this repository are standalone JavaScript/TypeScript tools. The remix package composes them under one umbrella for distribution and documentation.

Installation

To try the current Remix beta, install the next dist-tag:

npm install remix@next

To create a new Remix app with the CLI, use npx remix@next new:

npx remix@next new my-remix-app

If you want to play around with the bleeding edge, we also build the latest main branch into a preview/main branch which can be installed directly with pnpm (version 9+):

pnpm install "remix-run/remix#preview/main&path:packages/remix"

Or, just install a single package:

pnpm install "remix-run/remix#preview/main&path:packages/fetch-router"

Agent Skills For Building Apps

Agents that are starting a Remix 3 app from this repository should use the remix app skill. The CLI prepack step copies this skill into the app template so generated apps can use the same guidance.

Contributing

We welcome contributions! If you'd like to contribute, please feel free to open an issue or submit a pull request. See CONTRIBUTING for more information.

License

See LICENSE

remix (remix-run/remix)

Searching Database…

33.4K ·GitHub
这是什么?Remix 3 是一个全栈 Web 框架,直接基于 Web API(Streams、Fetch、Web Crypto)构建,而不是依赖特定打包工具的抽象层。它以一个统一的 'remix' 包发布,该包由许多独立的 JS/TS 工具组成。
这是一个包,还是一组独立的工具?它是一个单一代码仓库(monorepo),其中包含许多功能单一、可独立使用的包(如 router、auth、session、cli、data-table、ui 等)。这些包会被打包在主 'remix' 包之下,便于分发。
我要怎么创建一个新的 Remix 应用?通过 CLI 运行 'npx remix@next new' 即可创建一个新的 Remix 3 应用;或者安装 'next' 分发标签,试用当前的测试版。main 分支的最新构建也会发布到 preview/main 分支,可以用 pnpm 9+ 安装。
它只能在 Node.js 上运行吗?不是。Remix 3 的包基于服务端可用的 Web API 构建,因此可以在 Node.js、Bun、Deno、Cloudflare Workers 以及其他 JS 运行时中无缝运行;但开发本仓库本身需要 Node >=24.3.0。
Remix 3 可以用于生产环境吗?目前还不是稳定版。它只能通过 'next' 分发标签以测试版形式获取,仍在积极开发中,因此 API 可能会发生变化。
这个框架所说的 Model-First Development 是什么意思?这是 Remix 3 的核心设计原则之一:让源代码、文档和工具链针对大语言模型(LLM)进行优化,并构建抽象层,使应用能够直接在产品中使用 AI 模型,而不仅仅将其作为开发工具。
Remix 3 有自己的 UI 库吗?有的。'ui' 包是 Remix 自有的视图层,包含协调器(reconciler)、组件模型和官方 UI 组件,并且独立于 React 构建。
README 里提到的 'remix app' Agent Skill 是什么?这是一个 Agent Skill,AI 编程代理在基于本仓库创建新的 Remix 3 应用时应当使用它。CLI 的 prepack 步骤会把它复制到生成的应用模板中,使通过脚手架创建的应用也能获得相同的指导。
Remix 为什么要避免使用打包工具和外部依赖?这由两条指导原则驱动:'Religiously Runtime' 意味着任何包都不应依赖打包工具、编译器或静态分析;'Avoid Dependencies' 则旨在实现零第三方依赖,并对无法避免的依赖进行封装。
Creator
remix-run
Size
132 MB
Stars
33.4K
Age
5y
Commits · 90 Days