Last active
May 7, 2018 17:19
-
-
Save spalenza/1aba79d47e2039f60048f1bb1c4be51c to your computer and use it in GitHub Desktop.
render specific partial
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
before_filter :set_view_paths | |
def index | |
end | |
private | |
def set_view_paths | |
prepend_view_path 'projects/override' | |
end | |
# "/Users/rodolfo/Desktop/calendar_room/projects/override/shared/_flash_message{.en,}{.html,}{}{.erb,.builder,.raw,.ruby,.jbuilder,}" | |
# https://github.com/rails/rails/issues/12973 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# config/initializers/view_paths.rb | |
# EXTENSIONS = { :locale => ".", :formats => ".", :variants => "+", :handlers => "." } | |
# DEFAULT_PATTERN = ":prefix/:action{.:locale,}{.:formats,}{+:variants,}{.:handlers,}" | |
ActionController::Base.view_paths = ActionView::FileSystemResolver.new( | |
Rails.root.join('app/views'), | |
":prefix/{#{ENV[CORE_PATH]}/,}:action{.:locale,}{.:formats,}{+:variants,}{.:handlers,}" | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment