Skip to content

Commit 4b80129

Browse files
committed
chore(release): 2.3.2
1 parent f872dad commit 4b80129

8 files changed

+242
-74
lines changed

Diff for: CHANGELOG.md

+7
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,13 @@
22

33
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
44

5+
### [2.3.2](https://github.com/nuxt/vue-meta/compare/v2.3.1...v2.3.2) (2020-01-12)
6+
7+
8+
### Bug Fixes
9+
10+
* call afterNavigation after nextTick ([#478](https://github.com/nuxt/vue-meta/issues/478)) ([fa12530](https://github.com/nuxt/vue-meta/commit/fa12530b3ec450338c52dea2873f6913ee3abaf0))
11+
512
### [2.3.1](https://github.com/nuxt/vue-meta/compare/v2.3.0...v2.3.1) (2019-10-09)
613

714

Diff for: dist/vue-meta.common.js

+75-16
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
2-
* vue-meta v2.3.1
3-
* (c) 2019
2+
* vue-meta v2.3.2
3+
* (c) 2020
44
* - Declan de Wet
55
* - Sébastien Chopin (@Atinux)
66
* - Pim (@pimlie)
@@ -14,7 +14,7 @@ function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'defau
1414

1515
var deepmerge = _interopDefault(require('deepmerge'));
1616

17-
var version = "2.3.1";
17+
var version = "2.3.2";
1818

1919
function _typeof(obj) {
2020
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
@@ -45,6 +45,40 @@ function _defineProperty(obj, key, value) {
4545
return obj;
4646
}
4747

48+
function ownKeys(object, enumerableOnly) {
49+
var keys = Object.keys(object);
50+
51+
if (Object.getOwnPropertySymbols) {
52+
var symbols = Object.getOwnPropertySymbols(object);
53+
if (enumerableOnly) symbols = symbols.filter(function (sym) {
54+
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
55+
});
56+
keys.push.apply(keys, symbols);
57+
}
58+
59+
return keys;
60+
}
61+
62+
function _objectSpread2(target) {
63+
for (var i = 1; i < arguments.length; i++) {
64+
var source = arguments[i] != null ? arguments[i] : {};
65+
66+
if (i % 2) {
67+
ownKeys(Object(source), true).forEach(function (key) {
68+
_defineProperty(target, key, source[key]);
69+
});
70+
} else if (Object.getOwnPropertyDescriptors) {
71+
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
72+
} else {
73+
ownKeys(Object(source)).forEach(function (key) {
74+
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
75+
});
76+
}
77+
}
78+
79+
return target;
80+
}
81+
4882
function _toConsumableArray(arr) {
4983
return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _nonIterableSpread();
5084
}
@@ -205,6 +239,7 @@ function triggerUpdate(_ref, rootVm, hookName) {
205239

206240
if (rootVm[rootConfigKey].initialized && !rootVm[rootConfigKey].pausing) {
207241
// batch potential DOM updates to prevent extraneous re-rendering
242+
// eslint-disable-next-line no-void
208243
batchUpdate(function () {
209244
return void rootVm.$meta().refresh();
210245
}, debounceWait);
@@ -344,12 +379,14 @@ function addNavGuards(rootVm) {
344379
next();
345380
});
346381
router.afterEach(function () {
347-
var _resume = resume(rootVm),
348-
metaInfo = _resume.metaInfo;
382+
rootVm.$nextTick(function () {
383+
var _resume = resume(rootVm),
384+
metaInfo = _resume.metaInfo;
349385

350-
if (metaInfo && isFunction(metaInfo.afterNavigation)) {
351-
metaInfo.afterNavigation(metaInfo);
352-
}
386+
if (metaInfo && isFunction(metaInfo.afterNavigation)) {
387+
metaInfo.afterNavigation(metaInfo);
388+
}
389+
});
353390
});
354391
}
355392

@@ -1613,7 +1650,7 @@ function tagGenerator(options, type, tags, generatorOptions) {
16131650
}
16141651

16151652
if (attr === 'callback') {
1616-
attrs += " onload=\"this.__vm_l=1\"";
1653+
attrs += ' onload="this.__vm_l=1"';
16171654
continue;
16181655
} // these form the attribute list for this tag
16191656

@@ -1714,11 +1751,33 @@ function generateServerInjector(options, metaInfo) {
17141751
}
17151752
}
17161753

1754+
if (serverInjector.extraData) {
1755+
for (var appId in serverInjector.extraData) {
1756+
var _data = serverInjector.extraData[appId][type];
1757+
1758+
if (_data) {
1759+
for (var _attr in _data) {
1760+
attributeData[_attr] = _objectSpread2({}, attributeData[_attr], _defineProperty({}, appId, _data[_attr]));
1761+
}
1762+
}
1763+
}
1764+
}
1765+
17171766
return attributeGenerator(options, type, attributeData, arg);
17181767
}
17191768

17201769
var str = tagGenerator(options, type, serverInjector.data[type], arg);
17211770

1771+
if (serverInjector.extraData) {
1772+
for (var _appId in serverInjector.extraData) {
1773+
var _data2 = serverInjector.extraData[_appId][type];
1774+
var extraStr = tagGenerator(options, type, _data2, _objectSpread2({
1775+
appId: _appId
1776+
}, arg));
1777+
str = "".concat(str).concat(extraStr);
1778+
}
1779+
}
1780+
17221781
return str;
17231782
}
17241783
};
@@ -1778,10 +1837,10 @@ function $meta(options) {
17781837

17791838
var $root = this.$root;
17801839
return {
1781-
'getOptions': function getOptions$1() {
1840+
getOptions: function getOptions$1() {
17821841
return getOptions(options);
17831842
},
1784-
'setOptions': function setOptions(newOptions) {
1843+
setOptions: function setOptions(newOptions) {
17851844
var refreshNavKey = 'refreshOnceOnNavigation';
17861845

17871846
if (newOptions && newOptions[refreshNavKey]) {
@@ -1805,19 +1864,19 @@ function $meta(options) {
18051864
options.waitOnDestroyed = !!newOptions[waitOnDestroyedKey];
18061865
}
18071866
},
1808-
'refresh': function refresh$1() {
1867+
refresh: function refresh$1() {
18091868
return refresh($root, options);
18101869
},
1811-
'inject': function inject$1() {
1870+
inject: function inject$1() {
18121871
return inject($root, options) ;
18131872
},
1814-
'pause': function pause$1() {
1873+
pause: function pause$1() {
18151874
return pause($root);
18161875
},
1817-
'resume': function resume$1() {
1876+
resume: function resume$1() {
18181877
return resume($root);
18191878
},
1820-
'addApp': function addApp$1(appId) {
1879+
addApp: function addApp$1(appId) {
18211880
return addApp($root, appId, options);
18221881
}
18231882
};

Diff for: dist/vue-meta.esm.browser.js

+18-15
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
2-
* vue-meta v2.3.1
3-
* (c) 2019
2+
* vue-meta v2.3.2
3+
* (c) 2020
44
* - Declan de Wet
55
* - Sébastien Chopin (@Atinux)
66
* - Pim (@pimlie)
@@ -10,7 +10,7 @@
1010

1111
import deepmerge from 'deepmerge';
1212

13-
var version = "2.3.1";
13+
var version = "2.3.2";
1414

1515
function _typeof(obj) {
1616
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
@@ -162,6 +162,7 @@ function triggerUpdate(_ref, rootVm, hookName) {
162162

163163
if (rootVm[rootConfigKey].initialized && !rootVm[rootConfigKey].pausing) {
164164
// batch potential DOM updates to prevent extraneous re-rendering
165+
// eslint-disable-next-line no-void
165166
batchUpdate(function () {
166167
return void rootVm.$meta().refresh();
167168
}, debounceWait);
@@ -301,12 +302,14 @@ function addNavGuards(rootVm) {
301302
next();
302303
});
303304
router.afterEach(function () {
304-
var _resume = resume(rootVm),
305-
metaInfo = _resume.metaInfo;
305+
rootVm.$nextTick(function () {
306+
var _resume = resume(rootVm),
307+
metaInfo = _resume.metaInfo;
306308

307-
if (metaInfo && isFunction(metaInfo.afterNavigation)) {
308-
metaInfo.afterNavigation(metaInfo);
309-
}
309+
if (metaInfo && isFunction(metaInfo.afterNavigation)) {
310+
metaInfo.afterNavigation(metaInfo);
311+
}
312+
});
310313
});
311314
}
312315

@@ -1467,10 +1470,10 @@ function $meta(options) {
14671470

14681471
var $root = this.$root;
14691472
return {
1470-
'getOptions': function getOptions$1() {
1473+
getOptions: function getOptions$1() {
14711474
return getOptions(options);
14721475
},
1473-
'setOptions': function setOptions(newOptions) {
1476+
setOptions: function setOptions(newOptions) {
14741477
var refreshNavKey = 'refreshOnceOnNavigation';
14751478

14761479
if (newOptions && newOptions[refreshNavKey]) {
@@ -1494,19 +1497,19 @@ function $meta(options) {
14941497
options.waitOnDestroyed = !!newOptions[waitOnDestroyedKey];
14951498
}
14961499
},
1497-
'refresh': function refresh$1() {
1500+
refresh: function refresh$1() {
14981501
return refresh($root, options);
14991502
},
1500-
'inject': function inject() {
1503+
inject: function inject() {
15011504
return showWarningNotSupportedInBrowserBundle('inject');
15021505
},
1503-
'pause': function pause$1() {
1506+
pause: function pause$1() {
15041507
return pause($root);
15051508
},
1506-
'resume': function resume$1() {
1509+
resume: function resume$1() {
15071510
return resume($root);
15081511
},
1509-
'addApp': function addApp$1(appId) {
1512+
addApp: function addApp$1(appId) {
15101513
return addApp($root, appId, options);
15111514
}
15121515
};

0 commit comments

Comments
 (0)