Nested template in external script

2 posts, 0 answers
  1. Steve
    Steve avatar
    1851 posts
    Member since:
    Dec 2008

    Posted 24 Sep 2013 Link to this post

    If this is my template defined in my script
    var coreTemplate: "<div id='favouritesTooltipContent'>\
                       <h2>Favourites</h2>\
                       <ul data-bind='source: items' data-template=''>\
                       </ul>\
                    </div>",
    ...is there a way that the "data-template" for that URL could also live in the script instead of in the page??
  2. Alexander Valchev
    Admin
    Alexander Valchev avatar
    2875 posts

    Posted 26 Sep 2013 Link to this post

    Hello Steve,

    I am afraid that what you would like to achieve is not supported. The data-template attribute accepts only string that represents the name (id) of the template. It is not possible to define an in-line template using this attribute.

    Regards,
    Alexander Valchev
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. Kendo UI is VS 2017 Ready
Back to Top