Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2189)

Unified Diff: third_party/pkg/angular/lib/filter/json.dart

Issue 124053002: Adding Angular and dependent packages for testing (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 12 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/pkg/angular/lib/filter/json.dart
diff --git a/third_party/pkg/angular/lib/filter/json.dart b/third_party/pkg/angular/lib/filter/json.dart
new file mode 100644
index 0000000000000000000000000000000000000000..f2c0efa80dfcf2c1c93dbf09fd12b6d27c6366f2
--- /dev/null
+++ b/third_party/pkg/angular/lib/filter/json.dart
@@ -0,0 +1,14 @@
+part of angular.filter;
+
+/**
+ * Allows you to convert a JavaScript object into JSON string. This filter is
+ * mostly useful for debugging.
+ *
+ * Usage:
+ *
+ * {{ json_expression | json }}
+ */
+@NgFilter(name:'json')
+class JsonFilter {
+ call(text) => JSON.encode(text);
+}

Powered by Google App Engine
This is Rietveld 408576698