Skip to content

Commit

Permalink
Merge pull request #60 from magma-labs/chore/specify-which-railties-w…
Browse files Browse the repository at this point in the history
…e-want-to-require

Specify which railties we want to require
  • Loading branch information
Ilyeo authored Jun 28, 2024
2 parents fa34402 + 2eb5902 commit a6a4aa7
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 6 deletions.
2 changes: 1 addition & 1 deletion app/helpers/markdown_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@ def markdown
end

def markdown_render(md)
sanitize markdown.render md
sanitize find_and_preserve markdown.render md
end
end
4 changes: 2 additions & 2 deletions app/serializers/schema_blogpost_serializer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ def base
'datePublished': entry.created_at.strftime('%Y-%m-%d'),
'dateModified': entry.updated_at.strftime('%Y-%m-%d'),
'articleBody': entry.body,
'image': context.image_url('logo'),
'image': context.image_url('logo.png'),
'inLanguage': 'en-US',
'copyrightYear': entry.created_at.year,
'keywords': [entry.channel_name, 'MagmaLabs TIL', 'BlogPost', 'Today I Learned'],
Expand Down Expand Up @@ -56,7 +56,7 @@ def publisher
'url': 'https://www.magmalabs.io',
'logo': {
'@type': 'ImageObject',
'url': context.image_url('magma-logo')
'url': context.image_url('magma-logo.svg')
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion app/serializers/schema_organization_serializer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ def to_jsonld_data
'@context': 'http://schema.org',
'@type': 'Organization',
'url': context.root_url,
'logo': context.image_url('magma-logo')
'logo': context.image_url('magma-logo.svg')
}.merge(same_as).to_json
end

Expand Down
2 changes: 1 addition & 1 deletion app/views/posts/_post.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
.post__content.copy
%h1= link_to post.title, post

= find_and_preserve markdown_render post.body
= markdown_render post.body
%div.footer
- if content_for?(:social)
%p.post__social= content_for :social
Expand Down
12 changes: 11 additions & 1 deletion config/application.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,17 @@

require_relative 'boot'

require 'rails/all'
%w(
active_record/railtie
action_controller/railtie
action_view/railtie
action_mailer/railtie
).each do |railtie|
begin # rubocop:disable Style/RedundantBegin
require railtie
rescue LoadError
end
end

Bundler.require(*Rails.groups)

Expand Down

0 comments on commit a6a4aa7

Please sign in to comment.