code: function noncifyAttrs(element, getValue, attrs) {
        if (nonceValueExpression) {
          if (element === 'script' || element === 'style' ||
              (element === 'link' && (getValue('rel') || '').toLowerCase() === 'stylesheet')) {
            if (attrs.findIndex(({ name }) => name === 'nonce') < 0) {
              attrs[attrs.length] = {
                name: 'nonce',
                val: nonceValueExpression,
                mustEscape: true,
              };
            }
          }
        }
      }
docs: Add nonce attributes to attribute sets as needed.