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

A bunch of minor changes to the json schema snippets. #20

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

vineshtv
Copy link

@vineshtv vineshtv commented Feb 3, 2023

  1. Fixed some prefixes which were named incorrectly.
  2. Fixed the description for some fields which were incorrect.
  3. Added a description field to all properties.
  4. Added the prefix 'Snowboard: ' to the snippet name so that it shows up in dropdown.
  5. Added more prefixes for nullable parameters.
  6. Updated some tabstops.

1. Fixed some shortcuts which were named incorrectly.
2. Fixed the description for some fields which were incorrect.
3. Added a description field to all properties.
4. Added the prefix 'Snowboard: ' to the snippet name so that it shows up in
   dropdown.
5. Added more prefixes for nullable parameters.
6. Updated some tabstops.
@vineshtv vineshtv requested review from miike and jethron February 3, 2023 00:18
Copy link
Contributor

@jethron jethron left a comment

Choose a reason for hiding this comment

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

Great changes! Should be a good improvement.

  • Should we both with filling title with the value of ${1}?
  • Is it worth including an "Add enum property" and "Add const property" for completion?

snippets/json-schema.code-snippets Outdated Show resolved Hide resolved
snippets/json-schema.code-snippets Show resolved Hide resolved
snippets/json-schema.code-snippets Outdated Show resolved Hide resolved
snippets/json-schema.code-snippets Outdated Show resolved Hide resolved
snippets/json-schema.code-snippets Outdated Show resolved Hide resolved
snippets/json-schema.code-snippets Outdated Show resolved Hide resolved
snippets/json-schema.code-snippets Outdated Show resolved Hide resolved
snippets/json-schema.code-snippets Outdated Show resolved Hide resolved
snippets/json-schema.code-snippets Outdated Show resolved Hide resolved
snippets/json-schema.code-snippets Show resolved Hide resolved
"description": "An array of booleans"
"Snowboard: Array of arrays property": {
"prefix": ["array of arrays"],
"body": ["\"${1:property_name}\": {", "\t\"type\": \"array\",", "\t\"description\": \"${2:Description of ${1} goes here}\",", "\t\"items\": {", "\t\t\"type\": \"array\",", "\t\t\"description\": \"${3:Description goes here}\",", "\t\t\"items\": {", "\t\t\t\"type\": \"${4|number,integer,string,boolean,array,object|}\",", "\t\t\t\"description\": \"${5:Description goes here}\"", "\t\t}", "\t}", "}${0}"],
Copy link
Author

Choose a reason for hiding this comment

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

So now it adds the snippet like so -

        "property_name": {
            "type": "array",
            "description": "Description of property_name goes here",
            "items": {
                "type": "array",
                "description": "Description goes here",
                "items": {
                    "type": "number",
                    "description": "Description goes here"
                }
            }
        }

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.

2 participants