Skip to content

Atom package to easily generate partials when working with rails files

License

Notifications You must be signed in to change notification settings

joseramonc/rails-partials

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

85 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

rails-partials package

An Atom package to easily create partials for your ruby on rails application.

Features

  • Support for .erb, .haml and .slim files.
  • Support for .scss and .sass files.
  • Support for partials in other directories, when a partial is created with a name with slashes for example 'shared/footer', the partial is going to be created at app/views/shared/_footer.html.yourext
  • Support to send parameters into partials, shared/footer user:@user var:@var generates <%= render 'shared/footer', user: @user, var: @var %> and refactors the variables inside the partial.
  • Configuration to show or not show the generated partial in a new tab (defaults to true)
  • Configuration to use ' or " quotes

Installation

In Atom, open Preferences > Packages, search for rails-partials package. Once it found, click Install button to install package.

Demo Refactor

You can trigger the extension by:

  • Right clicking with a selection and selecting the command (.gif)

  • ctrl + alt + P: The default keybinding (darwin), can be changed with your favorite.

  • shift + alt + P: The default keybinding (linux / windows), can be changed with your favorite.

Please report any problems or suggestions at issue tracker.

About

Atom package to easily generate partials when working with rails files

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •