Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
module ApplicationHelper
def keywords
# List of keywords relevent to SEO.
keywords = ['magic the gathering','deck building']
# Join the keywords so they're in a string.
keywords.join(', ')
end
# Method for printing the page title.
def title
# The base page title.
base = "DeckTap"
# Check to see if title is nil.
if @title.nil?
# If the title is nil, then just show the base.
base
else
# However if the title isn't nil, show base + title.
base + " | " + @title
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.