Skip to content

Commit

Permalink
fix: Fix install instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
julianrubisch committed Oct 15, 2024
1 parent 9862e15 commit 199bc69
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app/markdown/application_markdown.rb
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ def block_code(code, language)
(tag.button class: "code-clipboard-button", data: {action: "clipboard#copy", clipboard_target: "button", title: "Copy to clipboard"} do
heroicon "clipboard-document-check"
end) + (tag.div class: "hidden", data: {clipboard_target: "source"} do
code
language != "html" ? raw(code) : code
end) + (tag.pre class: language do
raw FORMATTER.format(lexer.lex(code))
end)
Expand Down
2 changes: 1 addition & 1 deletion app/views/cookbook/_install_instructions.html.erb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<% markdown = ApplicationMarkdown.new %>

<% fenced_code = "```sh\nbin/rails app:template LOCATION='#{url}'```" %>
<% fenced_code = "```sh\nbin/rails app:template LOCATION=#{url}\n```" %>

<p>
To install this controller, run this command in your Rails app directory in the terminal:
Expand Down
2 changes: 1 addition & 1 deletion app/views/layouts/cookbook.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
<% end %>

<% if current_page.data["category"] %>
<%= render "cookbook/install_instructions", url: template_url(current_page.data["category"], "auto-sort") %>
<%= render "cookbook/install_instructions", url: template_url(current_page.data["category"], current_page.request_path.split("/").last) %>
<% end %>

<% if current_page.data["stackblitz_url"] %>
Expand Down

0 comments on commit 199bc69

Please sign in to comment.