- Notifications
You must be signed in to change notification settings - Fork5k
feat: setup twoslash for codeblocks#2668
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
base:main
Are you sure you want to change the base?
Uh oh!
There was an error while loading.Please reload this page.
Conversation
netlifybot commentedJan 15, 2024 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
✅ Deploy Preview forvuejs ready!
To edit notification comments on pull requests, go to yourNetlify site configuration. |
antfu commentedFeb 6, 2024
I think it's ready now. The only thing is that if we should bring Options API or wait for Floating Vue to adopt to Composition API only |
NataliaTepluhina commentedFeb 17, 2024
@antfu thank you for working on this! Looks great ✨ Could you please resolve the conflicts? I'll merge the PR and add |
brc-dd commentedFeb 17, 2024 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
I'll release vitepress by tomorrow. It will have shiki@v1. We can remove resolutions from package.json here. Also, is it possible to use the older code background with twoslash? github-dark's default background doesn't look nice with other stuff. |
yyx990803 commentedMar 5, 2024
Let's enable Options API then, it's ok for now until we have a version of |
antfu commentedMar 5, 2024
Should be good to go now |
yyx990803 commentedMar 5, 2024
I think we need to be a bit selective on where to use these, let me take a pass on the rest of the docs so it doesn't become distractive. |
Uh oh!
There was an error while loading.Please reload this page.
This is working now, but with a few caveats:
Preview
Short-term
twoslashis not stable yet:https://github.com/twoslashes/twoslashUsingshikiji's betahttps://shikiji.netlify.app/packages/twoslash, which is wait fortwoslashOnceshikijiv0.10 released and VitePress upgrade to it, the pnpm overrides can be removedLong-term
__VUE_OPTIONS_API__: trueis required at this moment becausefloating-vueis still using Options APIshamefully-hoist=trueis required at this moment fortwoslashto resolve the types correctlyAnd later we need to revise code blocks across the docs to add the
twoslashflag.