Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support ? in parameter let section #904

Closed
angelozerr opened this issue Jul 20, 2023 · 3 comments · Fixed by #905
Closed

Support ? in parameter let section #904

angelozerr opened this issue Jul 20, 2023 · 3 comments · Fixed by #905
Assignees
Labels
bug Something isn't working qute validation
Milestone

Comments

@angelozerr
Copy link
Contributor

angelozerr commented Jul 20, 2023

If you open https://github.com/ia3andy/quarkus-blast/blob/aa969f34616ec63be0268fee20a40097d2ec1ba4/src/main/resources/templates/layout/page.html#L7 you will have an error which says that name is required.

image

It is because the user tag defines name https://github.com/quarkiverse/quarkus-web-bundler/blob/3603361f4db3f6d45f90de8b6667505afc4218af/runtime/src/main/resources/templates/tags/bundleStyle.html#L2

But name is defined here https://github.com/quarkiverse/quarkus-web-bundler/blob/3603361f4db3f6d45f90de8b6667505afc4218af/runtime/src/main/resources/templates/tags/bundleStyle.html#L1 and uses ?. As we don't support ? the let parameter is name? instead of name and in this case we consider that name is a required parameter instead of an optional parameter.

@angelozerr angelozerr added bug Something isn't working validation qute labels Jul 20, 2023
@angelozerr angelozerr added this to the 0.16.0 milestone Jul 20, 2023
@angelozerr angelozerr self-assigned this Jul 20, 2023
angelozerr added a commit to angelozerr/quarkus-ls that referenced this issue Jul 20, 2023
Fixes redhat-developer#904

Signed-off-by: azerr <azerr@redhat.com>
angelozerr added a commit to angelozerr/quarkus-ls that referenced this issue Jul 20, 2023
Fixes redhat-developer#904

Signed-off-by: azerr <azerr@redhat.com>
@datho7561
Copy link
Contributor

If I create a custom tag:

{#let title?="my cool flexbox"}
<div style="display: flex; gap: 8px; flex-direction: column-reverse;">
    <div>
    1. Qui amet tempor do occaecat elit ullamco ex enim.
    </div>
    <div>
    2. Nisi consequat do occaecat minim proident pariatur qui magna non.
    </div>
    <div>
    3. Proident amet excepteur minim nostrud Lorem enim quis dolore tempor quis.
    </div>
    <div>
        {title}
    </div>
</div>
{/let}

then include it in one of the pages, it still complains about title being missing.

@angelozerr
Copy link
Contributor Author

Have you tested quarkus blast sample?

angelozerr added a commit to angelozerr/quarkus-ls that referenced this issue Jul 20, 2023
Fixes redhat-developer#904

Signed-off-by: azerr <azerr@redhat.com>
angelozerr added a commit to angelozerr/quarkus-ls that referenced this issue Jul 20, 2023
Fixes redhat-developer#904

Signed-off-by: azerr <azerr@redhat.com>
@angelozerr
Copy link
Contributor Author

@datho7561 please retry.

angelozerr added a commit that referenced this issue Jul 20, 2023
Fixes #904

Signed-off-by: azerr <azerr@redhat.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working qute validation
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants