Skip to content
This repository was archived by the owner on Dec 4, 2017. It is now read-only.

Commit 2492ea6

Browse files
committed
docs(upgrade): restrict component directive to elements
The `heroDetail` directive is shown as an example of a component directive, such as those built using the `.component()` helper in v1.5+. In order for the directive to be functionaly equivalent with the component directive created with `.component`, it needs to be restricted to elements only. (If the `restrict` is omitted, it defaults to `'AE'`, which would also match attributes.) /cc @teropa
1 parent 885aa04 commit 2492ea6

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

public/docs/_examples/upgrade-adapter/ts/app/hero-detail.directive.ts

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
// #docregion
22
export function heroDetailDirective() {
33
return {
4+
restrict: 'E',
45
scope: {},
56
bindToController: {
67
hero: '=',

0 commit comments

Comments
 (0)