cyrusfirheir / twee3-language-tools

[ VSCode extension ] Syntax highlighting and programmatic language tools for Twee 3, and Twine 2 storyformats.
https://marketplace.visualstudio.com/items?itemName=cyrusfirheir.twee3-language-tools
MIT License
47 stars 16 forks source link

Missing passages quickfix #32

Open cyrusfirheir opened 3 years ago

cyrusfirheir commented 3 years ago

From the Discord:

suggestion! when someone types [[]] and only inputs a name, without | or -> or <- then create a new story .tw file with that passage if that passage does not already exists. and if there is a | or -> or <- then wait till it's done and then create it if it didn't exist prior with the appropriate passage part :3 probably best to have it optional tho so you can turn it on/off ^^ maybe also with the option to either insert it into the same file or add a new file for it.

Why not make this one of those fancy lightbulb options? Like how an undefined macro can be added to the config, make it so undefined passages (in link markup or elsewhere) can be added.

a Quick fix would be the besht, yus the extension already detects missing passages so i could allow for a quickfix which promts the user to enter a (relative) filepath to append the new passage to. Leaving blank could append to the current file... If file dun exist, shall be created >.<