Annotation Interface ModelItem


Deprecated.
There is no any replacement in Lit template since template model is not supported for lit template, but you may still use @EventData("some_data") to receive data from the client side or @Id mapping and the component API or the element API with property synchronization instead. TPolymer template support is deprecated - we recommend you to use LitTemplate instead. Read more details from the Vaadin blog.
Allows to receive Model class item from the client side instead of a index of an element in dom-repeat Polymer template section, or string representation.

Can be applied on parameters with classes found in the TemplateModel.

This is by default a shorthand for @EventData("event.model.item") that works with List type model items. For other Model items define the value to be the methodName e.g. for setSubItem(...) use @ModelItem("subItem").

Since:
1.0
Author:
Vaadin Ltd
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    Deprecated.
    Path value for ModelItem.
  • Element Details

    • value

      String value
      Deprecated.
      Path value for ModelItem.
      Returns:
      Given Path or default value
      Default:
      "event.model.item"