diff --git a/composer.json b/composer.json index 852ba1c..74e4fd0 100644 --- a/composer.json +++ b/composer.json @@ -113,6 +113,7 @@ "drupal/graphql": "^4.0", "drupal/image_delta_formatter": "^1.x-dev", "drupal/image_effects": "^3.x-dev@dev", + "drupal/js_cache_buster": "^1.0", "drupal/jsonapi_extras": "^3.7", "drupal/jsonrpc": "^2.0", "drupal/login_destination": "^2.x-dev@dev", diff --git a/composer.lock b/composer.lock index 8ee1f60..3f65f93 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "1bc43b3e9f2e1ead63a21f6ac9dd2a10", + "content-hash": "a6b8dde1a5b90c4bd198cd52684607d6", "packages": [ { "name": "alchemy/zippy", @@ -9614,6 +9614,50 @@ "irc": "irc://irc.freenode.org/drupal-contribute" } }, + { + "name": "drupal/js_cache_buster", + "version": "1.0.1", + "source": { + "type": "git", + "url": "https://git.drupalcode.org/project/js_cache_buster.git", + "reference": "1.0.1" + }, + "dist": { + "type": "zip", + "url": "https://ftp.drupal.org/files/projects/js_cache_buster-1.0.1.zip", + "reference": "1.0.1", + "shasum": "1b3e502400f3f50027c1af38fbc87f4bdf58f21b" + }, + "require": { + "drupal/core": "^8 || ^9" + }, + "type": "drupal-module", + "extra": { + "drupal": { + "version": "1.0.1", + "datestamp": "1632682358", + "security-coverage": { + "status": "not-covered", + "message": "Project has not opted into security advisory coverage!" + } + } + }, + "notification-url": "https://packages.drupal.org/8/downloads", + "license": [ + "GPL-2.0-or-later" + ], + "authors": [ + { + "name": "anrkaid", + "homepage": "https://www.drupal.org/user/911760" + } + ], + "description": "Adds cache buster parameter to javascript files.", + "homepage": "https://www.drupal.org/project/js_cache_buster", + "support": { + "source": "https://git.drupalcode.org/project/js_cache_buster" + } + }, { "name": "drupal/jsonapi_extras", "version": "3.20.0", diff --git a/config/sync/core.extension.yml b/config/sync/core.extension.yml index 18252e7..02789b6 100644 --- a/config/sync/core.extension.yml +++ b/config/sync/core.extension.yml @@ -116,6 +116,7 @@ module: jquery_ui_checkboxradio: 0 jquery_ui_controlgroup: 0 jquery_ui_slider: 0 + js_cache_buster: 0 jsonapi: 0 jsonapi_extras: 0 language: 0 diff --git a/web/themes/custom/materiotheme/materiotheme.libraries.yml b/web/themes/custom/materiotheme/materiotheme.libraries.yml index d8f5ea2..3f306c5 100644 --- a/web/themes/custom/materiotheme/materiotheme.libraries.yml +++ b/web/themes/custom/materiotheme/materiotheme.libraries.yml @@ -1,5 +1,5 @@ global-css: - version: 0.0.1 + version: VERSION css: theme: # assets/fonts/ubuntu/ubuntu.css: {} @@ -7,17 +7,19 @@ global-css: assets/dist/main.css: {} global-js: - version: 0.0.1 + version: VERSION js: assets/dist/main.js: type: file minified: true preprocess: false + enable_buster: true # assets/dist/vsa.js: { } assets/dist/vclb.js: type: file minified: true preprocess: false + enable_buster: true dependencies: - core/drupal # - core/drupal.ajax