redhat-developer / redhat-developer/yaml-language-server

Different schema for specific field

Open
#800 0 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
TypeScript
Stars
1.5k
Forks
352
Avg merge
2d 7h
Merged PRs (30d)
11

Description

Is your enhancement related to a problem? Please describe.

Flux's HelmRelease has a schema which has an object type field .spec.values which cannot be schema'd using the main schema as this field is different for each helm chart. Therefore this has no schema, no completion, no validation, ... .

Describe the solution you would like

It would be awesome if we could do something like the modeline but on a specific field.
The yaml-language-server would then use this fields content as the whole object to use for validation, completion, ...

Describe alternatives you have considered

Somehow proxy the root schema with the specific schema injected, but that seems extremely difficult and error-prone

Additional context

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No files, tests, or entry points are named in the issue. Start by tracing the existing modeline schema handling and the validation/completion path, then determine how a schema could be scoped to a specific field. Done means a field-level schema can drive validation, completion, and related language-service behavior without breaking the root schema.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript, yaml
Domain
tooling
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.