Angular2 代码的 Plunker 出现 404 错误?
404 error on Plunker for Angular2 code?
Please check this plunk link
I am 404 error, I am unable to find it , please anyone can solve it, and update my plunk
1) 您的 base href
是对 plunker
无效的路径
A live coding environment like Plunker sets the application base
address dynamically so you can't specify a fixed address. That's why
the example code replaces the with a script that writes
the tag on the fly.
<script>document.write('<base href="' + document.location + '" />');</script>
You should only need this trick for the live example, not production
code.
https://angular.io/docs/ts/latest/guide/router.html#!#set-the-lt-base-href-
2) 如果您想在 AppComponent
模板中使用 DynamicDetail
组件,您必须从 yBusinessModule
导出它
3) 您需要在 DynamicDetail
模板中添加 router-outlet
Please check this plunk link
I am 404 error, I am unable to find it , please anyone can solve it, and update my plunk
1) 您的 base href
是对 plunker
A live coding environment like Plunker sets the application base address dynamically so you can't specify a fixed address. That's why the example code replaces the with a script that writes the tag on the fly.
<script>document.write('<base href="' + document.location + '" />');</script>
You should only need this trick for the live example, not production code.
https://angular.io/docs/ts/latest/guide/router.html#!#set-the-lt-base-href-
2) 如果您想在 AppComponent
模板中使用 DynamicDetail
组件,您必须从 yBusinessModule
3) 您需要在 DynamicDetail
模板中添加 router-outlet