Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit 48b34dd

Browse files
jsdevelpetebacondarwin
authored andcommitted
docs($resource): clarify the meaning of @ in paramDefaults
Closes #8457
1 parent 477626d commit 48b34dd

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/ngResource/resource.js

+4-2
Original file line numberDiff line numberDiff line change
@@ -106,8 +106,10 @@ function shallowClearAndCopy(src, dst) {
106106
* Given a template `/path/:verb` and parameter `{verb:'greet', salutation:'Hello'}` results in
107107
* URL `/path/greet?salutation=Hello`.
108108
*
109-
* If the parameter value is prefixed with `@` then the value of that parameter will be taken
110-
* from the corresponding key on the data object (useful for non-GET operations).
109+
* If the parameter value is prefixed with `@` then the value for that parameter will be extracted
110+
* from the corresponding property on the `data` object (provided when calling an action method). For
111+
* example, if the `defaultParam` object is `{someParam: '@someProp'}` then the value of `someParam`
112+
* will be `data.someProp`.
111113
*
112114
* @param {Object.<Object>=} actions Hash with declaration of custom action that should extend
113115
* the default set of resource actions. The declaration should be created in the format of {@link

0 commit comments

Comments
 (0)