adobe / htlengine

An HTL (Sightly) Interpreter/Compiler for Node.js
Apache License 2.0
47 stars 20 forks source link

Use class file reference should be relative to source file #106

Closed tripodsan closed 4 years ago

tripodsan commented 4 years ago

Problem

the use class file reference in data-sly-use is not relative to the .htl file.

eg, with a baseDir of myProject:

myProject/
└── src/
    ├── html.htl
    └── helper.js

the following use class can't be loaded:

src/html.htl

<div data-sly-use.help="${'./helper.js'}"></div>

Suggest

follow the same rule as node with require. i.e. ./ is relative to the source file. with no ./, it will be loaded as node_module. also see #105

adobe-bot commented 4 years ago

:tada: This issue has been resolved in version 3.2.8 :tada:

The release is available on:

Your semantic-release bot :package::rocket: