hdoc-tools 0.17.26 → 0.17.27
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/hdoc-build.js +1416 -1026
- package/hdoc-validate.js +4 -4
- package/package.json +1 -1
package/hdoc-validate.js
CHANGED
@@ -421,7 +421,7 @@
|
|
421
421
|
|
422
422
|
const dreeOptions = {
|
423
423
|
descendants: true,
|
424
|
-
|
424
|
+
excludeEmptyDirectories: true,
|
425
425
|
extensions: ['htm', 'html', 'md'],
|
426
426
|
hash: false,
|
427
427
|
normalize: true,
|
@@ -431,8 +431,8 @@
|
|
431
431
|
symbolicLinks: false
|
432
432
|
};
|
433
433
|
|
434
|
-
// File scan callback
|
435
|
-
const
|
434
|
+
// File scan callback for content type files
|
435
|
+
const fileContentCallback = function (element) {
|
436
436
|
if (element.extension.toLowerCase() === 'md') {
|
437
437
|
md_to_validate.push(element);
|
438
438
|
} else {
|
@@ -531,7 +531,7 @@
|
|
531
531
|
redirects = gen_redirects;
|
532
532
|
|
533
533
|
// Get a list of HTML files in source_path
|
534
|
-
dree.scan(source_path, dreeOptions,
|
534
|
+
dree.scan(source_path, dreeOptions, fileContentCallback);
|
535
535
|
|
536
536
|
// Check product family
|
537
537
|
let valid_product = false;
|