Angular 2如何使用Applets

时间:2017-03-10 11:05:41

标签: html angular

我目前在将Applet .jar文件嵌入Angular 2项目时遇到问题。

大部分解决方案都提到使用<applet></applet>标记,但在尝试时出现以下错误:

Unhandled Promise rejection: Template parse errors:

'applet' is not a known element:
1. If 'applet' is an Angular component, then verify that it is part of this module.
2. If 'applet' is a Web Component then add "CUSTOM_ELEMENTS_SCHEMA" to the '@NgModule.schemas' of this component to suppress this message.

我该如何解决这个问题?

1 个答案:

答案 0 :(得分:0)

好的,HTML5将protocol Prot1: AnyObject { } protocol Prot2 { associatedtype T: AnyObject } class TheClass: Prot2 { typealias U = Prot1 typealias T = AnyObject } 替换为<applet></applet>。 试过它,现在它起作用了

相关问题