This repository has been archived by the owner on Nov 7, 2024. It is now read-only.
Convert launching preview commands to a single unified command #224
Labels
enhancement
New feature or request
Background: In my project, I can provide
sys.inputs.at("target")
to control the target of a document. When a target is set to "webpage", it is compiled and suitable for viewing in website. When a target is set to "ebook", it is compiled as a e-book PDF and suitable for viewing in online or offline pdf viewer.To edit styles for document targeting to "webpage", I want to launch preview with
sys.inputs
arguments.Currently there are four commands to launch preview.
As feature increased (e.g.
sys.inputs
), the matrix becomes larger and unmaintainable. So I want to convert the "open/launch" action into a single command. And create four corresponding auto-detected tasks to replace these commands. The final effect should look like this:We will have these auto detected tasks (also as a start-up task template):
And we can invoke a
typst-preview.launch
command in task:All of arguments in
typst-preview.launch
are optional so we can also have a default command to launch without configuration or interactively.And we can disable auto detected tasks as user preferences.
https://github.com/microsoft/vscode/blob/c7ea84b4f5e779a98e93bd1f48502d83403f16c3/extensions/gulp/src/main.ts#L140-L150
The text was updated successfully, but these errors were encountered: