From a591770a989bdada471c461778cb790a7bc9a7bb Mon Sep 17 00:00:00 2001 From: Muhsin Keloth Date: Thu, 18 Aug 2022 13:24:19 +0530 Subject: [PATCH] Upgrade Vuex to 4 --- app/javascript/packs/application.js | 2 +- package.json | 7 ++++--- yarn.lock | 28 ++++++++++++++++++++++++---- 3 files changed, 29 insertions(+), 8 deletions(-) diff --git a/app/javascript/packs/application.js b/app/javascript/packs/application.js index 184c7c6df..57e0247dd 100644 --- a/app/javascript/packs/application.js +++ b/app/javascript/packs/application.js @@ -2,7 +2,7 @@ /* eslint-env browser */ /* eslint-disable no-new */ /* Vue Core */ - +import '@babel/polyfill'; import Vue from 'vue'; import VueI18n from 'vue-i18n'; import VueRouter from 'vue-router'; diff --git a/package.json b/package.json index ad59a1986..cac1b1145 100644 --- a/package.json +++ b/package.json @@ -26,6 +26,8 @@ "@rails/webpacker": "5.3.0", "@sentry/tracing": "^6.19.7", "@sentry/vue": "^6.19.7", + "@vue/compat": "^3.1.0", + "@vue/compiler-sfc": "^3.1.0", "activestorage": "^5.2.6", "axios": "^0.21.2", "babel-plugin-syntax-jsx": "^6.18.0", @@ -54,7 +56,6 @@ "v-tooltip": "~2.1.3", "videojs-record": "^4.5.0", "vue": "^3.1.0", - "@vue/compat": "^3.1.0", "vue-chartjs": "3.5.1", "vue-clickaway": "~2.1.0", "vue-color": "2.8.1", @@ -65,18 +66,18 @@ "vue-loader": "16.0.0", "vue-multiselect": "~2.1.6", "vue-router": "~3.5.2", - "@vue/compiler-sfc": "^3.1.0", "vue-upload-component": "2.8.22", "vue2-datepicker": "^3.9.1", "vuedraggable": "^2.24.3", "vuelidate": "0.7.7", - "vuex": "~2.1.1", + "vuex": "^4.0.2", "vuex-router-sync": "~4.1.2", "wavesurfer.js": "^6.0.4" }, "devDependencies": { "@babel/core": "7.13.16", "@babel/plugin-proposal-class-properties": "7.13.0", + "@babel/polyfill": "^7.12.1", "@babel/preset-env": "7.13.15", "@storybook/addon-actions": "6.5.9", "@storybook/addon-docs": "^6.5.9", diff --git a/yarn.lock b/yarn.lock index 10eaab322..0be61d854 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1125,6 +1125,14 @@ "@babel/helper-create-regexp-features-plugin" "^7.12.13" "@babel/helper-plugin-utils" "^7.12.13" +"@babel/polyfill@^7.12.1": + version "7.12.1" + resolved "https://registry.npmjs.org/@babel/polyfill/-/polyfill-7.12.1.tgz#1f2d6371d1261bbd961f3c5d5909150e12d0bd96" + integrity sha512-X0pi0V6gxLi6lFZpGmeNa4zxtwEmCs42isWLNjZZDE0Y8yVfgu0T2OAHlzBbdYlqbW/YXVvoBHpATEM+goCj8g== + dependencies: + core-js "^2.6.5" + regenerator-runtime "^0.13.4" + "@babel/preset-env@7.13.15", "@babel/preset-env@^7.1.6", "@babel/preset-env@^7.12.11", "@babel/preset-env@^7.13.15": version "7.13.15" resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.13.15.tgz#c8a6eb584f96ecba183d3d414a83553a599f478f" @@ -3307,6 +3315,11 @@ optionalDependencies: prettier "^1.18.2" +"@vue/devtools-api@^6.0.0-beta.11": + version "6.2.1" + resolved "https://registry.npmjs.org/@vue/devtools-api/-/devtools-api-6.2.1.tgz#6f2948ff002ec46df01420dfeff91de16c5b4092" + integrity sha512-OEgAMeQXvCoJ+1x8WyQuVZzFo0wcyCmUR3baRVLmKBo1LmYZWMlRiXlux5jd0fqVJu6PfDbOrZItVqUEzLobeQ== + "@vue/reactivity-transform@3.2.37": version "3.2.37" resolved "https://registry.yarnpkg.com/@vue/reactivity-transform/-/reactivity-transform-3.2.37.tgz#0caa47c4344df4ae59f5a05dde2a8758829f8eca" @@ -5551,6 +5564,11 @@ core-js@3.11.0, core-js@^3.0.4, core-js@^3.11.0, core-js@^3.6.5, core-js@^3.8.2: resolved "https://registry.yarnpkg.com/core-js/-/core-js-3.11.0.tgz#05dac6aa70c0a4ad842261f8957b961d36eb8926" integrity sha512-bd79DPpx+1Ilh9+30aT5O1sgpQd4Ttg8oqkqi51ZzhedMM1omD2e6IOF48Z/DzDCZ2svp49tN/3vneTK6ZBkXw== +core-js@^2.6.5: + version "2.6.12" + resolved "https://registry.npmjs.org/core-js/-/core-js-2.6.12.tgz#d9333dfa7b065e347cc5682219d6f690859cc2ec" + integrity sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ== + core-util-is@1.0.2, core-util-is@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" @@ -15847,10 +15865,12 @@ vuex-router-sync@~4.1.2: resolved "https://registry.yarnpkg.com/vuex-router-sync/-/vuex-router-sync-4.1.3.tgz#f209ec3174de04179bfadd7994437e4c5a81c975" integrity sha1-8gnsMXTeBBeb+t15lEN+TFqByXU= -vuex@~2.1.1: - version "2.1.3" - resolved "https://registry.yarnpkg.com/vuex/-/vuex-2.1.3.tgz#4f613f8425a274b85b79a83cd28b960938bf1670" - integrity sha1-T2E/hCWidLhbeag80ouWCTi/FnA= +vuex@^4.0.2: + version "4.0.2" + resolved "https://registry.npmjs.org/vuex/-/vuex-4.0.2.tgz#f896dbd5bf2a0e963f00c67e9b610de749ccacc9" + integrity sha512-M6r8uxELjZIK8kTKDGgZTYX/ahzblnzC4isU1tpmEuOIIKmV+TRdc+H4s8ds2NuZ7wpUTdGRzJRtoj+lI+pc0Q== + dependencies: + "@vue/devtools-api" "^6.0.0-beta.11" w3c-hr-time@^1.0.2: version "1.0.2"