Sha256: e525d5a364614c3d7777dcab832970ad14176244a0c3b390f997820b50a86cd0

Contents?: true

Size: 309 Bytes

Versions: 5

Compression:

Stored size: 309 Bytes

Contents

# frozen_string_literal: true

# We extract all the Document's links, not just the links to other webpages.
Wgit::Document.define_extension(
  :all_links,
  '//*/@href | //*/@src', # Any element with a href or src attribute.
  singleton: false,
  text_content_only: true
) do |links|
  links.uniq.to_urls
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
broken_link_finder-0.10.0 lib/broken_link_finder/wgit_extensions.rb
broken_link_finder-0.9.5 lib/broken_link_finder/wgit_extensions.rb
broken_link_finder-0.9.4 lib/broken_link_finder/wgit_extensions.rb
broken_link_finder-0.9.3 lib/broken_link_finder/wgit_extensions.rb
broken_link_finder-0.9.2 lib/broken_link_finder/wgit_extensions.rb