aboutsummaryrefslogtreecommitdiff
path: root/dev/dictionary-validate.js
diff options
context:
space:
mode:
Diffstat (limited to 'dev/dictionary-validate.js')
-rw-r--r--dev/dictionary-validate.js13
1 files changed, 8 insertions, 5 deletions
diff --git a/dev/dictionary-validate.js b/dev/dictionary-validate.js
index a6948bfe..6778f2ea 100644
--- a/dev/dictionary-validate.js
+++ b/dev/dictionary-validate.js
@@ -71,9 +71,10 @@ async function validateDictionaryBanks(mode, zip, fileNameFormat, schema) {
}
/**
- * @param {import('dev/schema-validate').ValidateMode} mode
- * @param {import('jszip')} archive
- * @param {import('dev/dictionary-validate').Schemas} schemas
+ * Validates a dictionary.
+ * @param {import('dev/schema-validate').ValidateMode} mode Mode of validation.
+ * @param {import('jszip')} archive Zip archive of the dictionary.
+ * @param {import('dev/dictionary-validate').Schemas} schemas Schema to use for validation.
*/
export async function validateDictionary(mode, archive, schemas) {
const fileName = 'index.json';
@@ -102,6 +103,7 @@ export async function validateDictionary(mode, archive, schemas) {
}
/**
+ * Returns a Schemas object from ext/data/schemas/*.
* @returns {import('dev/dictionary-validate').Schemas}
*/
export function getSchemas() {
@@ -118,8 +120,9 @@ export function getSchemas() {
}
/**
- * @param {import('dev/schema-validate').ValidateMode} mode
- * @param {string[]} dictionaryFileNames
+ * Validates dictionary files and logs the results to the console.
+ * @param {import('dev/schema-validate').ValidateMode} mode Mode of validation.
+ * @param {string[]} dictionaryFileNames Dictionary file names.
*/
export async function testDictionaryFiles(mode, dictionaryFileNames) {
const schemas = getSchemas();