parent
843351d8b7
commit
e87772f5d5
|
@ -238,7 +238,7 @@ figure.image-display
|
|||
|
||||
Did you remember to add the directive to the the `declarations` attribute of `@NgModule`? It is easy to forget!
|
||||
|
||||
你记着设置`@Component`的`directives`数组了吗?它很容易被忘掉。
|
||||
你记着设置`@NgModule`的`declarations`数组了吗?它很容易被忘掉。
|
||||
|
||||
Open the console in the browser tools and look for an error like this:
|
||||
|
||||
|
|
|
@ -473,7 +473,7 @@ block unless-intro
|
|||
Now we add it to the `declarations` array of the AppModule and try it.
|
||||
First we add some test HTML to the template:
|
||||
|
||||
现在,我们就来把它加到宿主组件的`directives`数组中,试一试。
|
||||
现在,我们就来把它加到AppModule的`declarations`数组中,试一试。
|
||||
我们首先把一些测试用的HTML添加到模板中:
|
||||
|
||||
+makeExample('structural-directives/ts/app/structural-directives.component.html', 'myUnless')(format=".")
|
||||
|
|
Loading…
Reference in New Issue