Skip to content

fix(extension): only match tutorialkit content and meta files #242

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

Merged
merged 3 commits into from
Aug 14, 2024

Conversation

Nemikolh
Copy link
Member

This PR makes sure that the autocompletion and validation for the frontmatter applies primarily to files that should be within a tutorialkit project. The heuristic used is very simple and not perfect so there could still be false positive. However, after this PR it will become very unlikely as one would need to create a markdown file named meta.md or content.md(x) under a src/content/tutorial path.

Note that files under _files and _solution are ignored as this could be a common situation where the extension would incorrectly perform validation and provide autocompletions.

Closes #237

Copy link

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

@Nemikolh Nemikolh requested review from AriPerkkio and sulco August 13, 2024 15:05
Copy link
Member

@AriPerkkio AriPerkkio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested locally in VSCode workspaces - works really well! 💯

I think we should get this fix released soon as it improves DX a lot.

@Nemikolh Nemikolh changed the title fix: only match tutorialkit content and meta files fix(extension): only match tutorialkit content and meta files Aug 13, 2024
Copy link

cloudflare-workers-and-pages bot commented Aug 13, 2024

Deploying tutorialkit-demo-page with  Cloudflare Pages  Cloudflare Pages

Latest commit: e6e3a34
Status: ✅  Deploy successful!
Preview URL: https://eed19f1f.tutorialkit-demo-page.pages.dev
Branch Preview URL: https://joan-fix-extensions-frontmat.tutorialkit-demo-page.pages.dev

View logs

@Nemikolh Nemikolh merged commit 9c1b55a into main Aug 14, 2024
10 checks passed
@Nemikolh Nemikolh deleted the joan/fix-extensions-frontmatter-validation branch August 14, 2024 06:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TutorialKit extension's intellisense kicks off in non-tutorialkit projects
2 participants