@Retention(value=RUNTIME) @Target(value=TYPE) @Documented @Repeatable(value=InternalContainerAnnotationForHtml.class) public @interface HtmlImport
ClientConnector
class, the
framework ensures the referenced HTML imports are loaded before the init
method for the corresponding client-side connector is invoked.
Note that not all browsers yet support HTML imports. If a polyfill is needed to load HTML imports, it must be loaded before HTML Imports can be loaded. There is no automatic loading of any polyfill.
HTML imports are added to the page after any @JavaScript
dependencies
added at the same time.
Example:
@HtmlImport("frontend://paper-slider/paper-slider.html")
on the
class com.example.MyConnector would load the file
http://host.com/VAADIN/frontend/es[56]/paper-slider/paper-slider.html
before the init()
method of the client side connector is invoked.
Modifier and Type | Required Element and Description |
---|---|
String[] |
value
HTML file URL(s) to load before using the annotated
ClientConnector in the browser. |
public abstract String[] value
ClientConnector
in the browser.Copyright © 2018 Vaadin Ltd. All rights reserved.