수준 1
수준 2
커뮤니티 로그인
자세한 정보
로그인하여 배지 모두 보기
내 커뮤니티 업적 표시줄을 확대합니다.
활동이 없어 이 대화는 잠겼습니다. 새 게시물을 작성해 주세요.
Is there any way we can pass a variable from component to another.
tried
<sly data-sly-resource="${resourceType='my/components/embeddedComponent', myParam='myValue'}></sly>
can I read the myParam in embeddedComponent ?
해결되었습니다! 솔루션으로 이동.
토픽은 커뮤니티 콘텐츠를 분류하여 관련성 있는 콘텐츠를 찾는 데 도움이 됩니다.
Not sure if you can do that. But you can try to pass variable as selectors
<article data-sly-resource="${'path/to/resource' @ selectors='selector'}"></article> <article data-sly-resource="${'path/to/resource' @ selectors=['s1', 's2']}"></article>
원본 게시물의 솔루션 보기
@ebin_Aby
You can try data-sly-template;
<template data-sly-template.component="${ @ title, pageLevel}"><h1>${title}: ${pageLevel}</h1></template> <div data-sly-call="${component @ title=properties.jcr:title, pageLevel='5'}"></div> // ouput <h1>Home Page: 5</h1>
Adobe's documentation for data-sly-template can be found here: https://docs.adobe.com/content/help/en/experience-manager-htl/using/htl/block-statements.html#templa...
조회 수
Likes
답글