ruby-resource-map
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseRuby Knowledge
Ruby 开发知识库
Authoritative resource map for Ruby development. Use these sources rather than searching broadly.
Never use these sources:
- ruby-doc.org
- apidock.com
Ruby开发的权威资源指南。请优先使用以下资源,而非广泛搜索。
请勿使用以下资源:
- ruby-doc.org
- apidock.com
Official Documentation
官方文档
Primary source: https://docs.ruby-lang.org/en/
Other Useful Resources
其他实用资源
- https://rubyreferences.github.io/rubychanges/ - Version-by-version changelog with examples
- https://railsatscale.com/ - Shopify engineering blog (Latest updates on Ruby and its toolings)
- https://rubyreferences.github.io/rubychanges/ - 带示例的分版本更新日志
- https://railsatscale.com/ - Shopify 技术博客(Ruby及其工具链的最新动态)
Core & Standard Library
核心库与标准库
| Term | Meaning |
|---|---|
| Default gem | Ships with Ruby, cannot uninstall |
| Bundled gem | Ships with Ruby, can uninstall/replace |
| Standard library | Part of Ruby itself, not a gem |
| 术语 | 含义 |
|---|---|
| Default gem | 随Ruby预装,无法卸载 |
| Bundled gem | 随Ruby预装,可卸载/替换 |
| Standard library | Ruby核心组成部分,非gem |
Typing Ecosystem
类型检查生态
Two type definition formats exist in Ruby:
- RBI - Sorbet's format. Uses Ruby DSL syntax () in
sig { ... }and.rbfiles..rbi - RBS - Official Ruby format (Ruby 3.0+). Dedicated syntax in files or inline as comments.
.rbs
Ruby中存在两种类型定义格式:
- RBI - Sorbet的格式。在和
.rb文件中使用Ruby DSL语法(.rbi)。sig { ... } - RBS - Ruby官方格式(Ruby 3.0及以上版本支持)。在文件中使用专用语法,或以内联注释形式存在。
.rbs
Sorbet Ecosystem
Sorbet 生态
Sorbet is a static and runtime type checker for Ruby, maintained by Stripe. Key companion tools:
RBS Ecosystem
RBS 生态
RBS Inline Comments
RBS 内联注释
Sorbet supports RBS-style inline type annotations using comment syntax. This eliminates the need for separate files or verbose blocks.
#:.rbisigSorbet支持使用注释语法的RBS风格内联类型注解。这无需单独的文件或冗长的代码块。
#:.rbisig