Skip to content

Using double curly brackets {{$example}} echo syntax in x-data attribute creates strange IDE warnings (phpstorm) #70

@samcoupland

Description

@samcoupland

Issue:
When using the double curly brackets in x-data attributes, I often get IDE warnings.

Scenario
x-data="{clicked{{ $model->getKey() }}: false}"
or
alpinejs1

IDE warning - comer expected
alpinejs2

IDE warning - curly bracket expected
alpinejs4

I am using the brackets to build unique x-data based on table element's model counterpart. I assume quite a common pattern.
Not sure why it's flagging these issues.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions