Skip to content

Commit e9a6e7e

Browse files
committed
AC-2627: Migrate from jquery/storageapi to js-storage/js.storage
1 parent 96faea7 commit e9a6e7e

File tree

8 files changed

+700
-31
lines changed

8 files changed

+700
-31
lines changed

app/code/Magento/Checkout/view/frontend/requirejs-config.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,10 @@ var config = {
1515
proceedToCheckout: 'Magento_Checkout/js/proceed-to-checkout',
1616
catalogAddToCart: 'Magento_Catalog/js/catalog-add-to-cart'
1717
}
18+
},
19+
shim: {
20+
'Magento_Checkout/js/model/totals' : {
21+
deps: ['Magento_Customer/js/customer-data']
22+
}
1823
}
1924
};

app/code/Magento/Cookie/view/base/requirejs-config.js

Lines changed: 0 additions & 10 deletions
This file was deleted.

app/code/Magento/Theme/view/base/requirejs-config.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,7 @@ var config = {
4747
'jquery-ui-modules/widget': 'jquery/ui-modules/widget',
4848
'jquery-ui-modules/timepicker': 'jquery/timepicker',
4949
'vimeo': 'vimeo/player',
50-
'vimeoWrapper': 'vimeo/vimeo-wrapper',
51-
'jquery/jquery.cookie': 'js-cookie/cookie-wrapper'
50+
'vimeoWrapper': 'vimeo/vimeo-wrapper'
5251
}
5352
},
5453
shim: {
@@ -69,7 +68,8 @@ var config = {
6968
'jquery/validate': 'jquery/jquery.validate',
7069
'jquery/file-uploader': 'jquery/fileUploader/jquery.fileuploader',
7170
'prototype': 'legacy-build.min',
72-
'jquery/jquery-storageapi': 'jquery/jquery.storageapi.min',
71+
'jquery/jquery.cookie': 'js-cookie/cookie-wrapper',
72+
'jquery/jquery-storageapi': 'js-storage/storage-wrapper',
7373
'text': 'mage/requirejs/text',
7474
'domReady': 'requirejs/domReady',
7575
'spectrum': 'jquery/spectrum/spectrum',

lib/web/jquery/jquery.storageapi.min.js

Lines changed: 0 additions & 2 deletions
This file was deleted.

lib/web/js-cookie/cookie-wrapper.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ define([
99
], function ($, cookie) {
1010
'use strict';
1111

12+
window.Cookies = window.Cookies || cookie;
13+
1214
var config = $.cookie = function (key, value, options) {
1315
if (value !== undefined) {
1416
options = $.extend({}, config.defaults, options);
@@ -36,7 +38,7 @@ define([
3638
}
3739

3840
return result;
39-
}
41+
};
4042

4143
config.defaults = {};
4244

lib/web/js-cookie/js.cookie.min.js

Lines changed: 0 additions & 2 deletions
This file was deleted.

0 commit comments

Comments
 (0)