Class: Enjoy::Goto::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/enjoy/goto/configuration.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



26
27
28
29
30
31
32
33
34
35
36
# File 'lib/enjoy/goto/configuration.rb', line 26

def initialize
  @css_selector = "a[href]"
  @href_regex = /^(https?:)?\/\//i
  @excluded_hosts = []

  @add_nofollow = true
  @add_noindex = true
  @add_noreferrer = true
  @add_noopener = true
  @del_attrs = true
end

Instance Attribute Details

#add_nofollowObject

Returns the value of attribute add_nofollow.



20
21
22
# File 'lib/enjoy/goto/configuration.rb', line 20

def add_nofollow
  @add_nofollow
end

#add_noindexObject

Returns the value of attribute add_noindex.



21
22
23
# File 'lib/enjoy/goto/configuration.rb', line 21

def add_noindex
  @add_noindex
end

#add_noopenerObject

Returns the value of attribute add_noopener.



23
24
25
# File 'lib/enjoy/goto/configuration.rb', line 23

def add_noopener
  @add_noopener
end

#add_noreferrerObject

Returns the value of attribute add_noreferrer.



22
23
24
# File 'lib/enjoy/goto/configuration.rb', line 22

def add_noreferrer
  @add_noreferrer
end

#css_selectorObject

Returns the value of attribute css_selector.



16
17
18
# File 'lib/enjoy/goto/configuration.rb', line 16

def css_selector
  @css_selector
end

#del_attrsObject

Returns the value of attribute del_attrs.



24
25
26
# File 'lib/enjoy/goto/configuration.rb', line 24

def del_attrs
  @del_attrs
end

#excluded_hostsObject

Returns the value of attribute excluded_hosts.



18
19
20
# File 'lib/enjoy/goto/configuration.rb', line 18

def excluded_hosts
  @excluded_hosts
end

#href_regexObject

Returns the value of attribute href_regex.



17
18
19
# File 'lib/enjoy/goto/configuration.rb', line 17

def href_regex
  @href_regex
end