UNPKG

423 BJavaScriptView Raw
1'use strict';
2
3exports.type = 'perItem';
4
5exports.active = false;
6
7exports.description = 'removes <script> elements (disabled by default)';
8
9/**
10 * Remove <script>.
11 *
12 * https://www.w3.org/TR/SVG/script.html
13 *
14 * @param {Object} item current iteration item
15 * @return {Boolean} if false, item will be filtered out
16 *
17 * @author Patrick Klingemann
18 */
19exports.fn = function(item) {
20
21 return !item.isElem('script');
22
23};