Skip to content

Support for bracket-accessed object property autocompletion. #14

@a3kov

Description

@a3kov

Recently bracket syntax fix was added in #13. Now would be nice to have full autocomplete support for this type of object access, when we type some.objects[0]. in the following example

{{ some.objects[0].name }}

We must be able to distinguish array access from property access - probably using numeric key would be enough.

There is also map-like access pattern, which can be used for function calling without creating custom filters (very useful because I think it supports variable keys).

{{ some.objects["foo"].name }}

When used with literal key it is possible to infer the resulting object type and to suggest properties, when we type some.objects["foo"].
Now, if the key was a variable instead of a literal I guess that would be impossible ? But if we could get the literal working that would be awesome.
I think map-like literal access should be distinguishable from dot property access, because they are not the same thing, but I'm open to hear other people's opinions on this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions