-
-
Notifications
You must be signed in to change notification settings - Fork 32
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
Upgrade to use Torchlight? #74
Comments
I strongly oppose "upgrading" to Torchlight with their current licensing model and the fact that their clients interact with an API. This might be okay to integrate as an optional feature with big warning signs (or even better, a seperate plugin), but switching over completely would make this plugin inaccessible to many projects and 11ty users. Although Tochlight definetly has some really nice features. |
Ah yeah, show up super late here to say that Torchlight can absolutely live as a separate plugin! All of the hooks should be available! |
Noted! Hadn't thought of any issues facing the licensing model. Most (just assuming) are using for a personal/open source project, but that's fair to point out. @zachleat Out of interest and off the top of my head, and example of implementing this would be to use
|
I would personally do this as a shortcode instead of an after, because with If I were to implement it, I'd probably keep it close to this plugin. |
I guess the only reason I mentioned the eleventy.after is that one of Torchlights build processes is from standalone CLI, so thought that would be an easy route to use the CLI to process the html after 11ty has built it. I'm unaware of any Torchlight integration directly into a js/11ty pipeline that would work, but I'm not very experienced with Torchlight. Thanks for the direction though, will try to learn and take a look into it. :) |
Ahh, looking at the docs, I see what you mean. You could use their API directly, as you just need to post an object to https://api.torchlight.dev/highlight, but if you do that for each code block, you might hit rate limits fairly soon. In general I would personally right now avoid this tool (except for experimentation), because rate limits are really low (for the commercial option) or unknown and the docs seem nice, but lack some information or are outdated (like the link to the remark plugin). |
Comes with a wide array of functionality (seems to come up alot in the issues, i.e. line numbers, diffs) baked in.
Also comes with focusing, collapsible sections and much more.
Would probably need to use the CLI version of Torchlight, but should work well.
Torchlight.dev
The text was updated successfully, but these errors were encountered: