You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
575 B
TypeScript
22 lines
575 B
TypeScript
import { setDiagnosticsOptions } from 'monaco-yaml';
|
|
import problemConfigSchema from '../schema/problemconfig';
|
|
|
|
setDiagnosticsOptions({
|
|
validate: true,
|
|
enableSchemaRequest: true,
|
|
hover: true,
|
|
completion: true,
|
|
format: false,
|
|
schemas: [
|
|
{
|
|
uri: 'https://hydro.js.org/schema/problemConfig.json',
|
|
fileMatch: ['hydro://problem/file/config.yaml'],
|
|
schema: problemConfigSchema as any,
|
|
},
|
|
{
|
|
uri: new URL('/manage/config/schema.json', window.location.href).toString(),
|
|
fileMatch: ['hydro://system/setting.yaml'],
|
|
},
|
|
],
|
|
});
|