vulcan-sql icon indicating copy to clipboard operation
vulcan-sql copied to clipboard

Wrong types of TagRunnerOptions.args

Open oscar60310 opened this issue 3 years ago • 0 comments

Environment

  • Version:
    cli version: 0.3.0
    core version: 0.2.1
    build version: 0.2.1
    serve version: 0.2.1
    

What's wrong?

The args property of TagRunnerOptions was constianted to be string, number, or boolean.

export declare type TagExtensionArgTypes = string | number | boolean;
export interface TagRunnerOptions {
    context: nunjucks.Context;
    args: TagExtensionArgTypes[];
    contentArgs: TagExtensionContentArgGetter[];
    metadata: NunjucksExecutionMetadata;
}

But it can be object if inputs are keyword arguments.

{% tagname foo="bar" %}

What's the correct behavior?

It should be allowed to be Record too.

Reproducing steps

oscar60310 avatar Oct 18 '22 03:10 oscar60310