Uploaded image for project: 'Sling'
  1. Sling
  2. SLING-5813

Allow a Resource to be used as a Sightly Use-Object with data-sly-use

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • Scripting Sightly Engine 1.0.18
    • Scripting
    • None

    Description

      At the moment, if we want to use a Resource (to invoke it's properties for example) we need a helper Use-Object to provide it. It would be more straightforward if we could just load it by path and bind it to a variable via data-sly-use:

      <sly data-sly-use.myRes="${'some/path'}">${myRes.title}</sly>
      

      Attachments

        Issue Links

          Activity

            People

              radu Radu Cotescu
              vladb Vlad Bailescu
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: