admin管理员组文章数量:1332352
I'm trying to get a div element with ID="calendarJS" and pass it to a constructor.
import elemental2.dom.Document;
import elemental2.dom.Element;
.
.
.
Element calendarEl = new Document().getElementById("calendarJS");
After loading the page the GWT compiler shows this error:
.
.
.
[ERROR] Line 133: No source code is available for type elemental2.dom.Element; did you fet to inherit a required module?
[ERROR] Line 133: No source code is available for type elemental2.dom.Document; did you fet to inherit a required module?
.
.
.
What do I miss?
I have the elemental2-promise, elemental2-dom and elemental2-core in my pom.xml
I'm trying to get a div element with ID="calendarJS" and pass it to a constructor.
import elemental2.dom.Document;
import elemental2.dom.Element;
.
.
.
Element calendarEl = new Document().getElementById("calendarJS");
After loading the page the GWT compiler shows this error:
.
.
.
[ERROR] Line 133: No source code is available for type elemental2.dom.Element; did you fet to inherit a required module?
[ERROR] Line 133: No source code is available for type elemental2.dom.Document; did you fet to inherit a required module?
.
.
.
What do I miss?
I have the elemental2-promise, elemental2-dom and elemental2-core in my pom.xml
Share Improve this question asked Nov 20, 2024 at 23:55 RicardoRicardo 33 bronze badges1 Answer
Reset to default 1As the error says, did you fet to inherit the module in your .gwt.xml
file? Adding it to the pom isn't enough.
You need to have
<inherits name="elemental2.dom.Dom"/>
in your .gwt.xml file to specify that you will use those sources.
本文标签:
版权声明:本文标题:gwt elemental - GWT No source code is available for type elemental2.dom.Element; did you forget to inherit a required module? - 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1742321674a2452914.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论