Skip to content

json-schema-plus

An extension for vscode that provides multilingual dynamic schema matching for JSON Schema.

How to Use

TIP

Take scoop-manifest.*.json in abgox/schema as an example.

  1. Install json-schema-plus.

  2. Add the following configuration to your workspace settings.json file, refer to abgox/abyss.

    json
    "json-schema-plus.schemas": [
     {
       "fileMatch": ["bucket/**/*.json"],
       "urls": [
         {
           "language": "zh",
           "url": "https://schema.abgox.com/scoop-manifest.zh-CN.json"
         },
       ],
       "url": "https://schema.abgox.com/scoop-manifest.en-US.json"
     }
    ]
  3. It will automatically load the corresponding Schema structure according to the current language environment.

    • If it is zh-CN.
      • It will match zh in urls.
      • Then it will load https://schema.abgox.com/scoop-manifest.zh-CN.json.
    • If it is en-US.
      • There is no relevant definition in urls.
      • Then it will load "https://schema.abgox.com/scoop-manifest.en-US.json".

Star ⭐️ or Donate 💰 if you like it!

Released under the MIT.