qunit.rb 854 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. # frozen_string_literal: true
  2. module Docs
  3. class Qunit < UrlScraper
  4. self.name = 'QUnit'
  5. self.type = 'qunit'
  6. self.release = '2.19.3'
  7. self.base_url = 'https://api.qunitjs.com/'
  8. self.root_path = '/'
  9. self.links = {
  10. home: 'https://qunitjs.com/',
  11. code: 'https://github.com/qunitjs/qunit'
  12. }
  13. html_filters.push 'qunit/entries', 'qunit/clean_html'
  14. options[:trailing_slash] = false
  15. options[:container] = '.main'
  16. options[:skip_patterns] = [
  17. /deprecated/,
  18. /^QUnit$/,
  19. /^assert$/,
  20. /^callbacks$/,
  21. /^async$/,
  22. /^config$/,
  23. /^extension$/,
  24. ]
  25. options[:attribution] = <<-HTML
  26. &copy; OpenJS Foundation and contributors.<br>
  27. Licensed under the MIT license.
  28. HTML
  29. def get_latest_version(opts)
  30. get_npm_version('qunit', opts)
  31. end
  32. end
  33. end