https://github.com/smridge/vscode_rails_syntax
Rails Syntax Highlighting for Visual Studio Code
https://github.com/smridge/vscode_rails_syntax
rails ruby ruby-on-rails syntax-highlighting vscode vscode-extension
Last synced: 2 months ago
JSON representation
Rails Syntax Highlighting for Visual Studio Code
- Host: GitHub
- URL: https://github.com/smridge/vscode_rails_syntax
- Owner: smridge
- License: mit
- Created: 2020-03-07T08:18:51.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2023-02-17T21:55:29.000Z (almost 3 years ago)
- Last Synced: 2025-04-22T10:45:04.816Z (8 months ago)
- Topics: rails, ruby, ruby-on-rails, syntax-highlighting, vscode, vscode-extension
- Homepage:
- Size: 1.09 MB
- Stars: 13
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Rails Syntax Highlighting for Visual Studio Code
[](https://marketplace.visualstudio.com/items?itemName=SarahRidge.vscode-rails-syntax)
[](https://marketplace.visualstudio.com/items?itemName=SarahRidge.vscode-rails-syntax)
[](https://marketplace.visualstudio.com/items?itemName=SarahRidge.vscode-rails-syntax)
[](https://github.com/smridge/vscode_rails_syntax/blob/master/LICENSE)
Extends Visual Studio Code's Ruby Language Grammars with the Rails Library.
Support methods are identified such as:
- `belongs_to`
- `has_many`
- `has_rich_text`
- `validates`
- `scope`
- `before_action`
- `link_to`
This extension is certainly not inclusive of every method Rails and Turbo Rails offers. Rails is a massive library! Added methods from various classes/modules listed below.
Pull Requests are more than welcome!
## Install
- Run: `code --install-extension SarahRidge.vscode-rails-syntax`
- Alternatively, extension can be installed via [VScode marketplace](https://marketplace.visualstudio.com/items?itemName=SarahRidge.vscode-rails-syntax).
- Reload VSCode.
## Known Methods Added From
### AbstractController
- `AbstractController::Callbacks`
### ActionController
- `ActionController::Flash::ClassMethods`
- `ActionController::Redirecting`
- `ActionController::RequestForgeryProtection::ClassMethods`
### ActionDispatch
- `Routing::Mapper::Base`
- `Routing::Mapper::Concerns`
- `Routing::Mapper::CustomUrls`
- `Routing::Mapper::HttpHelpers`
- `Routing::Mapper::Resources`
- `Routing::Mapper::Scoping`
### ActionView
- `ActionView::Helpers::CacheHelper`
- `ActionView::Helpers::FormTagHelper`
- `ActionView::Helpers::TagHelper`
- `ActionView::Helpers::TextHelper`
- `ActionView::Helpers::TranslationHelper`
- `ActionView::Helpers::UrlHelper`
### ActionText
- `ActionText::Attribute`
### ActiveModel
- `ActiveModel::Validations::ClassMethods`
### ActiveRecord
- `ActiveRecord::Associations::ClassMethods`
- `ActiveRecord::Callbacks`
- `ActiveRecord::Enum`
- `ActiveRecord::Migration < Object`
- `ActiveRecord::NestedAttributes::ClassMethods`
- `ActiveRecord::QueryMethods`
- `ActiveRecord::Relation < Object`
- `ActiveRecord::Scoping::Named::ClassMethods`
### ActiveStorage
- `ActiveStorage::Attached::Model`
### ActiveSupport
- `ActiveSupport::Rescuable::ClassMethods`
### Module
- `Module < Object`
### Turbo Rails
- `Turbo::FramesHelper`
- `Turbo::Streams::ActionHelper`
- `Turbo::Streams::TagBuilder`
- `Turbo::StreamsHelper`
## References
- [Syntax Highlight Guide](https://code.visualstudio.com/api/language-extensions/syntax-highlight-guide)
- [Language Grammar Rules](https://macromates.com/manual/en/language_grammars)
- [Rails API](https://api.rubyonrails.org)
- [Turbo Rails API](https://github.com/hotwired/turbo-rails)
## Related Extensions
- [Ruby Syntax Highlighting](https://github.com/smridge/vscode-ruby-syntax)
---
Logo © David Heinemeier Hansson: https://rubyonrails.org/trademarks/