Skip to content

[Feature request] Option to include CLI arguments (esp --input) #110

@kescobo

Description

@kescobo

In typst code, I can include #input.sys.some_key, and then build the document with typst build main.typ --input some_key="some value" so that this is replace with the included value (see here). It could be useful to have the ability in nvim to do something like `:TypstPreview input="some_key='some_value'" (I don't know what syntax makes sense) to be able to preview this.

The workaround right now, because input.sys is a dictionary, is just to include a default value. Eg #input.sys.at("some_key", default:"placeholder"). Counterpoint to this request is that this feature would add unnecessary complexity when this workaround is available (and probably something should be added to tinymist as well so that the editor isn't littered with errors).

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