File tree 1 file changed +8
-0
lines changed
1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -265,6 +265,14 @@ function shallowClearAndCopy(src, dst) {
265
265
* - `$cancelRequest`: If there is a cancellable, pending request related to the instance or
266
266
* collection, calling this method will abort the request.
267
267
*
268
+ * The Resource instances have these additional methods:
269
+ *
270
+ * - `toJSON`: It returns a simple object without any of the extra properties added as part of
271
+ * the Resource API. This object can be serialized through {@link angular.toJson} safely
272
+ * without attaching Angular-specific fields. Notice that `JSON.stringify` (and
273
+ * `angular.toJson`) automatically use this method when serializing a Resource instance
274
+ * (see [MDN](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/stringify#toJSON()_behavior)).
275
+ *
268
276
* @example
269
277
*
270
278
* # Credit card resource
You can’t perform that action at this time.
0 commit comments