简体   繁体   English

Rails 源代码中的哪个位置是内置变形列表?

[英]Where in Rails source is the list of built-in inflections?

Oddly, I searched through what I think is all of the source code for "geese" thinking I would locate it but I didn't.奇怪的是,我搜索了我认为是“鹅”的所有源代码,以为我会找到它,但我没有。 Does anyone know?有人知道吗?

If you're looking for the rails code that handles inflections, it's at https://github.com/rails/rails/tree/master/activesupport/lib/active_support/inflector如果您正在寻找处理变形的 rails 代码,请访问https://github.com/rails/rails/tree/master/activesupport/lib/active_support/inflector

If you're looking for custom pluralization in an application code, it's usually in config/initializers/inflections.rb如果您正在应用程序代码中寻找自定义复数形式,它通常位于config/initializers/inflections.rb

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM