diff options
author | XhmikosR <xhmikosr@gmail.com> | 2020-10-20 10:46:04 +0300 |
---|---|---|
committer | XhmikosR <xhmikosr@gmail.com> | 2021-12-02 17:14:03 +0300 |
commit | 97ed344fbc49a78ee0e86a3a7867489b9602667a (patch) | |
tree | 3e0e3a9dc98847387deea07fdbf0c7406c8c5e42 | |
parent | e3486447d87a7d6e64b15d50bf7a5e9fa0812d1f (diff) |
Adapt to the recent main changes
* remove `bs-custom-file-input.min.js`
* switch to errorf
* change error message
-rw-r--r-- | config.yml | 2 | ||||
-rw-r--r-- | site/layouts/partials/func/get-js-assets.html | 8 |
2 files changed, 4 insertions, 6 deletions
diff --git a/config.yml b/config.yml index 7077c9e7dc..95607c8f85 100644 --- a/config.yml +++ b/config.yml @@ -48,8 +48,6 @@ module: ## The following vendor files will be bundled together on top of local js files as /docs.js - source: node_modules/anchor-js/anchor.min.js target: assets/js/vendor/anchor.min.js - - source: node_modules/bs-custom-file-input/dist/bs-custom-file-input.min.js - target: assets/js/vendor/bs-custom-file-input.min.js - source: node_modules/clipboard/dist/clipboard.min.js target: assets/js/vendor/clipboard.min.js diff --git a/site/layouts/partials/func/get-js-assets.html b/site/layouts/partials/func/get-js-assets.html index 5c56b03e6f..f2eb1a913c 100644 --- a/site/layouts/partials/func/get-js-assets.html +++ b/site/layouts/partials/func/get-js-assets.html @@ -18,7 +18,7 @@ {{ $jsAssets := slice }} {{/* Storing the reused mount warning message */}} -{{ $missing_file_warning := "%s not found. Check your mounts settings." }} +{{ $missing_file_warning := "%s not found. Check your mounts settings and/or run `npm i`." }} {{ $doc_version := site.Params.docs_version }} {{/* Doc Search */}} {{ if eq .Page.Layout "docs" -}} @@ -31,7 +31,7 @@ */}} {{ $jsAssets = $jsAssets | append . }} {{ else }} - {{ warnf $missing_file_warning "docsearch.min.js" }} + {{ errorf $missing_file_warning "docsearch.min.js" }} {{ end }} {{- end }} @@ -44,12 +44,12 @@ 1. Check for missing mounts and throw an error 2. Control order if need be 3. Exclude docsearch (though there would be other ways) */}} -{{ $vendor_filenames := slice "clipboard.min.js" "anchor.min.js" "bs-custom-file-input.min.js" }} +{{ $vendor_filenames := slice "clipboard.min.js" "anchor.min.js" }} {{ range $filename := $vendor_filenames }} {{ with resources.GetMatch (print "js/vendor/" .) }} {{ $vendor_assets = $vendor_assets | append . }} {{ else }} - {{ warnf $missing_file_warning $filename }} + {{ errorf $missing_file_warning $filename }} {{ end }} {{ end }} {{ with $vendor_assets }} |