@@ -143,34 +143,37 @@ In addition to the settings, schemas associations can also be provided through a
143143
144144Notification:
145145- method: 'json/schemaAssociations'
146- - params: ` ISchemaAssociations | SchemaConfiguration [] ` defined as follows
146+ - params: ` ISchemaAssociations ` or ` ISchemaAssociation []` defined as follows
147147
148148``` ts
149- /**
150- * An object where:
151- * - keys are file names or file paths (separated by `/`). `*` can be used as a wildcard.
152- * - values ar an arrays of schema URLs
153- */
154- type ISchemaAssociations = Record <string , string []>
155-
156- interface SchemaConfiguration {
157- /**
158- * The URI of the schema, which is also the identifier of the schema.
159- */
160- uri: string ;
161- /**
162- * A list of file path patterns that are associated to the schema. The '*' wildcard can be used. Exclusion patterns starting with '!'.
163- * For example '*.schema.json', 'package.json', '!foo*.schema.json'.
164- * A match succeeds when there is at least one pattern matching and last matching pattern does not start with '!'.
165- */
166- fileMatch? : string [];
167- /**
168- * The schema for the given URI.
169- * If no schema is provided, the schema will be fetched with the schema request service (if available).
170- */
171- schema? : JSONSchema ;
149+ interface ISchemaAssociations {
150+ /**
151+ * An object where:
152+ * - keys are file names or file paths (using `/` as path separator). `*` can be used as a wildcard.
153+ * - values are an arrays of schema URIs
154+ */
155+ [pattern : string ]: string [];
172156}
157+
158+ interface ISchemaAssociation {
159+ /**
160+ * The URI of the schema, which is also the identifier of the schema.
161+ */
162+ uri: string ;
163+
164+ /**
165+ * A list of file path patterns that are associated to the schema. The '*' wildcard can be used. Exclusion patterns starting with '!'.
166+ * For example '*.schema.json', 'package.json', '!foo*.schema.json'.
167+ * A match succeeds when there is at least one pattern matching and last matching pattern does not start with '!'.
168+ */
169+ fileMatch: string [];
170+
171+ }
172+
173173```
174+ ` ISchemaAssociations `
175+ - keys: a file names or file path (separated by ` / ` ). ` * ` can be used as a wildcard.
176+ - values: An array of schema URLs
174177
175178Notification:
176179- method: 'json/schemaContent'
0 commit comments