Skip to content

Commit

Permalink
build: 2.1.2
Browse files Browse the repository at this point in the history
  • Loading branch information
LinusBorg committed Apr 24, 2019
1 parent 1b49954 commit 9cc2dca
Show file tree
Hide file tree
Showing 7 changed files with 29 additions and 11 deletions.
10 changes: 8 additions & 2 deletions dist/portal-vue.common.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/portal-vue.common.js.map

Large diffs are not rendered by default.

10 changes: 8 additions & 2 deletions dist/portal-vue.esm.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/portal-vue.esm.js.map

Large diffs are not rendered by default.

10 changes: 8 additions & 2 deletions dist/portal-vue.umd.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
/*!
* portal-vue © Thorsten Lünborg, 2019
*
* Version: 2.1.1
* Version: 2.1.2
*
* LICENCE: MIT
*
Expand Down Expand Up @@ -52,6 +52,7 @@
throw new TypeError("Invalid attempt to spread non-iterable instance");
}

var inBrowser = typeof window !== 'undefined';
function freeze(item) {
if (Array.isArray(item) || _typeof(item) === 'object') {
return Object.freeze(item);
Expand Down Expand Up @@ -95,11 +96,12 @@
transports: transports,
targets: targets,
sources: sources,
trackInstances: true
trackInstances: inBrowser
};
},
methods: {
open: function open(transport) {
if (!inBrowser) return;
var to = transport.to,
from = transport.from,
passengers = transport.passengers,
Expand Down Expand Up @@ -156,6 +158,8 @@
}
},
registerTarget: function registerTarget(target, vm, force) {
if (!inBrowser) return;

if (this.trackInstances && !force && this.targets[target]) {
console.warn("[portal-vue]: Target ".concat(target, " already exists"));
}
Expand All @@ -166,6 +170,8 @@
this.$delete(this.targets, target);
},
registerSource: function registerSource(source, vm, force) {
if (!inBrowser) return;

if (this.trackInstances && !force && this.sources[source]) {
console.warn("[portal-vue]: source ".concat(source, " already exists"));
}
Expand Down
Loading

0 comments on commit 9cc2dca

Please sign in to comment.