Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
} else if (isVueComponent(options.component)) {
props = options.props
component = options.component
} else {
if (debug) { console.error('[vue-modal-dialogs] No Vue component specified') }
return
}
// Dialog component and props
var dialogConfig = {
props: props,
// Inject a `$close` function and pre-defined props into dialog component
component: Vue.extend({
extends: component,
props: diff(['dialogId', 'arguments' ].concat( props), Object.keys(component.props || [])),
methods: {
$close: function $close (data) {
this.$emit('vue-modal-dialogs:close', data)
}
}
})
}
// Return dialog function
return function dialogFunction () {
var args = [], len = arguments.length;
while ( len-- ) args[ len ] = arguments[ len ];
if (dialogsWrapper) {
// Add dialog component into dialogsWrapper component
return dialogsWrapper.add(dialogConfig, args)
module.exports = function difference_(arr) {
if (!Array.isArray(arr)) {
throw new TypeError('utils#array.difference() expects an array.');
}
return diff.apply(diff, arguments);
};