Index: lib/safe_html.dart |
diff --git a/lib/safe_html.dart b/lib/safe_html.dart |
index 33854719453ffd7c485816e85359ad11b956cbd4..a80b28a81beed854fbbf32e7b7611bbc0a5367bb 100644 |
--- a/lib/safe_html.dart |
+++ b/lib/safe_html.dart |
@@ -6,13 +6,20 @@ |
// dart:html? |
library safe_html; |
+import 'package:meta/meta.dart'; |
+ |
/** Declares a string that is a well-formed HTML fragment. */ |
+// TODO(sigmund): delete this type now that Element.html is safe by default. |
class SafeHtml { |
/** Underlying html string. */ |
String _html; |
- // TODO(sigmund): provide a constructor that does html validation |
+ /** |
+ * dart:html now supports sanitizing elements. You can add any node |
+ * directly in your bindings instead of creating instances of SafeHtml. |
+ */ |
+ @deprecated |
SafeHtml.unsafe(this._html); |
String toString() => _html; |