removeTitle.js 497 B

123456789101112131415161718192021222324
  1. 'use strict';
  2. exports.type = 'perItem';
  3. exports.active = false;
  4. exports.description = 'removes <title> (disabled by default)';
  5. /**
  6. * Remove <title>.
  7. * Disabled by default cause it may be used for accessibility.
  8. *
  9. * https://developer.mozilla.org/en-US/docs/Web/SVG/Element/title
  10. *
  11. * @param {Object} item current iteration item
  12. * @return {Boolean} if false, item will be filtered out
  13. *
  14. * @author Igor Kalashnikov
  15. */
  16. exports.fn = function(item) {
  17. return !item.isElem('title');
  18. };