title: Sanitize HTML with HtmlEscape, only < and >
body: <p>I'm having trouble with escaping HTML using <code>HtmlEscape</code> in <code>dart:convert</code>.</p>
  
  <pre><code>import 'dart:convert';
  
  var sanitizer = new HtmlEscape(HtmlEscapeMode.ELEMENT);
  var text = 'http://woven.co/';
  
  print(text);
  text = sanitizer.convert(text);
  print(text); // http:&amp;#x2F;&amp;#x2F;woven.co&amp;#x2F;
  </code></pre>
  
  <p>Try it at: <a href="https://dartpad.dartlang.org/6036b7f888128b310a78" rel="nofollow">https://dartpad.dartlang.org/6036b7f888128b310a78</a></p>
  
  <p>I expected the string not to change, given the <code>HtmlEscapeMode.ELEMENT</code> definition:
  <a href="https://api.dartlang.org/apidocs/channels/stable/dartdoc-viewer/dart:convert.HtmlEscapeMode#id_ELEMENT" rel="nofollow">https://api.dartlang.org/apidocs/channels/stable/dartdoc-viewer/dart:convert.HtmlEscapeMode#id_ELEMENT</a></p>
  
  <p>As well, for the life of me I can't figure out how to pass my own <code>HtmlEscapeMode</code> in.</p>