-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Filetype list as config option #7
Comments
As much as I would like to there are a few problems. The main problem will be the
Which is going to stop the entire plugin. But if you change the filetype then plugins(& other functionalities) may break. Sometimes you won't even notice that something isn't working properly. Another issue would be clashing with other(similar plugins), a lot of people tend to already use some sort of plugin(and people don't like to stop using the tools they are familiar with) for these filetypes. And frankly it's impossible for me to ensure everything works everywhere. The third issue would be |
Thanks for the quick reply :) For the treesitter parser, if I had the Quarto parser installed, for example, would it give me the same error? Is the issue that users would need to install the parsers for the filetypes they use? I'm currently using |
Also, since the plugin is already broken down into individual features in the config (e.g., lists, headers, code-blocks...), maybe each of these rendering features could be enabled/disabled in the config. In this way, if e.g., code-blocks are rendered wrong because some other plugin is interfering, users can decide to individually disable that feature to make all their plugins co-exist. I'm not sure if implementing this would be hard as I haven't dived deep into your code. Just throwing some ideas. |
It completely depends on the parser. For example you can use something like And not all
If you look at the source code for Which basically means that I will have to rewrite the entire thing(or some parts of the plugin) every time I want to add support to a new filetype. I will also need to handle edge cases(e.g. something at the start/end of the buffer, stuff near the edge of the screen etc.) which are very hard to track. So, it's not on my bucket list for now since learning new treesitter parser's nodes takes a bit of time and I am a bit busy now. I will probably check it out later but no promises. |
Yes, this is planned. I will add it in the next update. |
Ok, I see! It's unfortunate the parsers don't follow the same conventions. |
Update on your request: It appears that this is quite a bit tricky. As you can see I have a link in a table Here's how it's meant to look like. The problem is If I add |
Feature enable/disable was added to the main branch. You can test them out now. |
I will be closing this as there's currently no good way to add support for other filetypes. |
Hello again @OXY2DEV ! I forked the repo to try how the plugin would perform out of the box with Quarto. I've been trying it and so far no issues. I simply created an |
Example: Screen.Recording.2024-07-13.at.15.11.19.mov |
even though I find this plugin really great, the lack of possibility to enable it for different filetypes is a game changer to me :( |
From what I understand, the plugin only works with
md
files. Could there be afiletypes
list in the config where users could add other filetypes to use the renderer? For example, Quarto (qmd
), Jupyter Notebooks (ipynb
) or R-markdown (rmd
) files.Thanks for the plugin! :)
The text was updated successfully, but these errors were encountered: