module Jekyll::SeoTag::UrlHelper
Mixin to share common URL-related methods between class
Private Instance Methods
absolute_url?(string)
click to toggle source
Determines if the given string is an absolute URL
Returns true if an absolute URL Returns false if it’s a relative URL Returns nil if it is not a string or can’t be parsed as a URL
# File lib/jekyll-seo-tag/url_helper.rb, line 14 def absolute_url?(string) return unless string Addressable::URI.parse(string).absolute? rescue Addressable::URI::InvalidURIError nil end