[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-553":3},{"id":4,"name":5,"fullName":6,"owner":5,"repo":5,"description":7,"homepage":8,"htmlUrl":9,"language":10,"languages":9,"totalLinesOfCode":9,"stars":11,"forks":12,"watchers":13,"openIssues":14,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":15,"stars7d":16,"stars30d":17,"stars90d":15,"forks30d":15,"starsTrendScore":18,"compositeScore":19,"rankGlobal":9,"rankLanguage":9,"license":20,"archived":21,"fork":21,"defaultBranch":22,"hasWiki":21,"hasPages":21,"topics":23,"createdAt":9,"pushedAt":9,"updatedAt":30,"readmeContent":31,"aiSummary":32,"trendingCount":15,"starSnapshotCount":15,"syncStatus":33,"lastSyncTime":34,"discoverSource":35},553,"rails","rails\u002Frails","Ruby on Rails","https:\u002F\u002Frubyonrails.org",null,"Ruby",58657,22166,2369,471,0,185,264,22,100,"MIT License",false,"main",[24,25,26,27,28,5,29],"activejob","activerecord","framework","html","mvc","ruby","2026-06-12 04:00:04","# Welcome to Rails\n\n## What's Rails?\n\nRails is a web application framework that includes everything needed to\ncreate database-backed web applications according to the\n[Model-View-Controller (MVC)](https:\u002F\u002Fen.wikipedia.org\u002Fwiki\u002FModel-view-controller)\npattern.\n\nUnderstanding the MVC pattern is key to understanding Rails. MVC divides your\napplication into three layers: Model, View, and Controller, each with a specific responsibility.\n\n## Model layer\n\nThe _**Model layer**_ represents the domain model (such as Account, Product,\nPerson, Post, etc.) and encapsulates the business logic specific to\nyour application. In Rails, database-backed model classes are derived from\n`ActiveRecord::Base`. [Active Record](activerecord\u002FREADME.rdoc) allows you to present the data from\ndatabase rows as objects and embellish these data objects with business logic\nmethods.\nAlthough most Rails models are backed by a database, models can also be ordinary\nRuby classes, or Ruby classes that implement a set of interfaces as provided by\nthe [Active Model](activemodel\u002FREADME.rdoc) module.\n\n## View layer\n\nThe _**View layer**_ is composed of \"templates\" that are responsible for providing\nappropriate representations of your application's resources. Templates can\ncome in a variety of formats, but most view templates are HTML with embedded\nRuby code (ERB files). Views are typically rendered to generate a controller response\nor to generate the body of an email. In Rails, View generation is handled by [Action View](actionview\u002FREADME.rdoc).\n\n## Controller layer\n\nThe _**Controller layer**_ is responsible for handling incoming HTTP requests and\nproviding a suitable response. Usually, this means returning HTML, but Rails controllers\ncan also generate XML, JSON, PDFs, mobile-specific views, and more. Controllers load and\nmanipulate models, and render view templates in order to generate the appropriate HTTP response.\nIn Rails, incoming requests are routed by Action Dispatch to an appropriate controller, and\ncontroller classes are derived from `ActionController::Base`. Action Dispatch and Action Controller\nare bundled together in [Action Pack](actionpack\u002FREADME.rdoc).\n\n## Frameworks and libraries\n\n[Active Record](activerecord\u002FREADME.rdoc), [Active Model](activemodel\u002FREADME.rdoc), [Action Pack](actionpack\u002FREADME.rdoc), and [Action View](actionview\u002FREADME.rdoc) can each be used independently outside Rails.\n\nIn addition to that, Rails also comes with:\n\n- [Action Mailer](actionmailer\u002FREADME.rdoc), a library to generate and send emails\n- [Action Mailbox](actionmailbox\u002FREADME.md), a library to receive emails within a Rails application\n- [Active Job](activejob\u002FREADME.md), a framework for declaring jobs and making them run on a variety of queuing backends\n- [Action Cable](actioncable\u002FREADME.md), a framework to integrate WebSockets with a Rails application\n- [Active Storage](activestorage\u002FREADME.md), a library to attach cloud and local files to Rails applications\n- [Action Text](actiontext\u002FREADME.md), a library to handle rich text content\n- [Active Support](activesupport\u002FREADME.rdoc), a collection of utility classes and standard library extensions that are useful for Rails, and may also be used independently outside Rails\n\n## Getting Started\n\n1. Install Rails at the command prompt if you haven't yet:\n\n\t```bash\n\t$ gem install rails\n\t```\n\n2. At the command prompt, create a new Rails application:\n\n\t```bash\n\t$ rails new myapp\n\t```\n\n   where \"myapp\" is the application name.\n\n3. Change directory to `myapp` and start the web server:\n\n\t```bash\n\t$ cd myapp\n\t$ bin\u002Frails server\n\t```\n   Run with `--help` or `-h` for options.\n\n4. Go to `http:\u002F\u002Flocalhost:3000` and you'll see the Rails bootscreen with your Rails and Ruby versions.\n\n5. Follow the guidelines to start developing your application. You may find\n   the following resources handy:\n    * [Getting Started with Rails](https:\u002F\u002Fguides.rubyonrails.org\u002Fgetting_started.html)\n    * [Ruby on Rails Guides](https:\u002F\u002Fguides.rubyonrails.org)\n    * [The API Documentation](https:\u002F\u002Fapi.rubyonrails.org)\n\n## Contributing\n\nWe encourage you to contribute to Ruby on Rails! Please check out the\n[Contributing to Ruby on Rails guide](https:\u002F\u002Fedgeguides.rubyonrails.org\u002Fcontributing_to_ruby_on_rails.html) for guidelines about how to proceed. [Join us!](https:\u002F\u002Fcontributors.rubyonrails.org)\n\nTrying to report a possible security vulnerability in Rails? Please\ncheck out our [security policy](https:\u002F\u002Frubyonrails.org\u002Fsecurity) for\nguidelines about how to proceed.\n\nEveryone interacting in Rails and its sub-projects' codebases, issue trackers, chat rooms, and mailing lists is expected to follow the Rails [code of conduct](https:\u002F\u002Frubyonrails.org\u002Fconduct).\n\n## License\n\nRuby on Rails is released under the [MIT License](https:\u002F\u002Fopensource.org\u002Flicenses\u002FMIT).\n","Ruby on Rails 是一个基于 Model-View-Controller (MVC) 模式的 Web 应用框架，提供了创建数据库支持的 Web 应用所需的所有工具。其核心功能包括 ActiveRecord 用于数据持久化，Action Pack 用于处理 HTTP 请求和生成响应，以及 Action View 用于模板渲染。此外，Rails 还集成了邮件发送、作业调度、WebSocket 支持、文件存储等多种实用库。该框架适合需要快速开发并维护高质量 Web 应用的场景，尤其适用于企业级应用和个人项目中对开发效率有较高要求的情况。",2,"2026-06-11 02:37:29","top_all"]