Skip to content
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

feat: ajv validation errors markers #182

Merged
merged 5 commits into from
Nov 8, 2023
Merged

feat: ajv validation errors markers #182

merged 5 commits into from
Nov 8, 2023

Conversation

roshan-gh
Copy link
Contributor

No description provided.

@roshan-gh roshan-gh self-assigned this Nov 7, 2023
Copy link

vercel bot commented Nov 7, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
otelbin ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 8, 2023 11:19am

const value = editorValue;
const parsedYaml = Array.from(new Parser().parse(value));
const doc = parsedYaml.find((token) => token.type === "document") as Document;
const docElements: IItem[] = doc?.value?.items ?? [];
return docElements;
};

export function parseYaml(yamlItems: IItem[]) {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

parseYaml function is more efficient and accessible function to make the big yaml Document smaller, through the cleanups, will adjust other parsing functions with this one. @bripkens

Copy link

sonarcloud bot commented Nov 8, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 2 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@bripkens bripkens merged commit 46f3191 into main Nov 8, 2023
29 checks passed
@bripkens bripkens deleted the ajv-error-line-number branch November 8, 2023 12:33
@github-actions github-actions bot locked and limited conversation to collaborators Nov 8, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants