Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
set (key, value) {
if (2 === arguments.length) {
// Create param object and call recursively
var obj = {};
obj[key] = value;
return this.set(obj);
}
// key is an object
merge(this.$_filters, key);
// notify change of filters
this.ready(onready.bind(this));
function onready() {
this.emit('change', this.get());
}
// reload items with updated filters
this.reload();
// save current state
return this.save();
}
// If it does then retrieve the value of it here or return false
configMerge = configMergeExists ? config.options['merge-default-rules'] : false;
// check to see if inline options contains an options property and whether property has a property called merge-default-rules
optionsMergeExists = (options.options && typeof options.options['merge-default-rules'] !== 'undefined');
// If it does then retrieve the value of it here or return false
optionsMerge = optionsMergeExists ? options.options['merge-default-rules'] : false;
// order of preference is inline options > user config > default config
// merge-default-rules defaults to true so each step above should merge with the previous. If at any step merge-default-rules is set to
// false it should skip that steps merge.
defaults = confHelpers.loadDefaults();
finalConfig = merge.recursive(defaults, config, options);
// if merge-default-rules is set to false in user config file then we essentially skip the merging with default rules by overwriting our
// final rules with the content of our user config otherwise we don't take action here as the default merging has already happened
if (configMergeExists && !configMerge) {
finalConfig.rules = config.rules;
}
// if merge-default-rules is set to false in inline options we essentially skip the merging with our current rules by overwriting our
// final rules with the content of our user config otherwise we check to see if merge-default-rules is true OR that we have any inline
// rules, if we do then we want to merge these into our final ruleset.
if (optionsMergeExists && !optionsMerge) {
finalConfig.rules = options.rules;
}
else if ((optionsMergeExists && optionsMerge) || options.rules && Object.keys(options.rules).length > 0) {
finalConfig.rules = merge.recursive(finalConfig.rules, options.rules);
}
if (config.preset === undefined) {
presetFile = require.resolve('liferay-npm-bundler-preset-standard');
} else if (config.preset === '' || config.preset === false) {
// don't load preset
} else {
presetFile = resolveModule.sync(config.preset, {
basedir: '.',
});
}
if (presetFile) {
const originalConfig = Object.assign({}, config);
Object.assign(
config,
merge.recursive(readJsonSync(presetFile), originalConfig)
);
config.pluginsBaseDir = getPackageDir(presetFile);
}
// Normalize
config['/'] = config['/'] || {};
config['config'] = config['config'] || {};
config.packages = config.packages || {};
}
return tapeFn(testName, function (t) {
var end = t.end.bind(t)
// Call all beforeEach fns and set return as context
// to pass to test methods
var beforeEachReturns = beforeEach.map(function (be) {
return be()
})
t.context = merge.apply(null, beforeEachReturns)
t.end = function () {
afterEach.forEach(function (ae) {
ae({
context: t.context
})
})
end()
}
//
var ret = fn({
equal: t.equal,
deepEqual: t.deepEqual,
pass: t.pass,
(function webpackUniversalModuleDefinition(root, factory) {
if(typeof exports === 'object' && typeof module === 'object')
module.exports = factory(require("lodash/lang"));
else if(typeof define === 'function' && define.amd)
define(["lodash/lang"], factory);
else if(typeof exports === 'object')
exports["merge.js"] = factory(require("lodash/lang"));
else
root["merge.js"] = factory(root["lodash/lang"]);
})(this, function(__WEBPACK_EXTERNAL_MODULE_12__) {
return /******/ (function(modules) { // webpackBootstrap
(function webpackUniversalModuleDefinition(root, factory) {
if(typeof exports === 'object' && typeof module === 'object')
module.exports = factory(require("lodash/lang"));
else if(typeof define === 'function' && define.amd)
define(["lodash/lang"], factory);
else if(typeof exports === 'object')
exports["merge.js"] = factory(require("lodash/lang"));
else
root["merge.js"] = factory(root["lodash/lang"]);
})(this, function(__WEBPACK_EXTERNAL_MODULE_12__) {
return /******/ (function(modules) { // webpackBootstrap
module.exports = function() {
return merge.recursive(Field(), {
props: {
placeholder: {
type:String,
required:false,
default:''
},
disabled: {
type: Boolean
},
tinymce:{
default: false
},
debounce:{
type:Number,
default:300
},
data: function() {
return {
globalOptions: globalOptions ? globalOptions : {},
templates: merge.recursive(fields, customFields),
isForm: true,
vffields: [],
additionalValues: [],
vferrors: [],
relatedFields: {},
triggeredFields: {},
sending: false
};
},
computed: {
module.exports = function() {
return merge.recursive(Field(), {
data: function() {
return {
fieldType: "buttons",
allSelected: false,
filteringField: null,
allSelected: false,
clearText: "Clear",
toggleTexts: {
select: "Select All",
unselect: "Unselect All"
}
};
},
props: {
items: {
type: Array,
_merge(object1, object2) {
return merge.recursive(true, object1, object2)
}