Skip to content

Completion fails when not in an object/array #114

@Duologic

Description

@Duologic

When I try to use completion outside an object/array, then if fails.

Does not work:

local hello = import 'hello.jsonnet';

hello.<tab>

Works:

local hello = import 'hello.jsonnet';
[
  hello.<tab>
]
local hello = import 'hello.jsonnet';
{
  a: hello.<tab>
}

Library:

// hello.jsonnet
local hello = {
  hello: {
    to: {
      the: 'world',
    },
  },
};

hello

Error log:

level=error msg="Completion: error finding ranges: could not find bind for hello"

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