fix: Override props with injections

If you have a prop and an injection with the same name (perhaps you defined it in a static propTypes class property) then the injection will take precedence and override any props with the same name.

Signed-off-by: Andrew J Daniel <adaniel@uk.ibm.com>
This commit is contained in:
Andrew J Daniel
2018-02-20 14:11:26 +00:00
parent d0b8c336b2
commit 5bc1810407
4 changed files with 2663 additions and 620 deletions
+2
View File
@@ -90,6 +90,8 @@ angular
.component('myComponent', react2angular(MyComponent, [], ['$http', 'FOO']))
```
Note: If you have an injection that matches the name of a prop, then the value will be resolved with the injection, not the prop.
## Tests
```sh