ngData
We use ngData
to modify element's dataset
Syntax
<el data-ng-data="expression => datasetKey:string, expression => datasetValue:string" />
// Can be applied multiple times on element
<el data-ng-data-0="..." data-ng-data-9="..." />
Examples
(new NgTemplate( document.body , `<div data-ng-data="'dateOfBirth', value"></div>` ))
.sync({ value: "1960-10-03" });
console.log( document.body.innerHTML ); // <div data-date-of-birth="1960-10-03"></div>