Tabnine Logo For Javascript
LoDashStatic.has
Code IndexAdd Tabnine to your IDE (free)

How to use
has
function
in
LoDashStatic

Best JavaScript code snippets using lodash.LoDashStatic.has(Showing top 15 results out of 405)

origin: lando/lando

// Merge in process.env as relevant
 _.forEach(_.keys(config), key => {
  if (_.has(process.env, key)) {
   config[key] = process.env[key];
  }
 });
origin: lando/lando

// If we have an app with a tooling section let's do this
 app.events.on('post-init', () => {
  if (!_.isEmpty(_.get(app, 'config.tooling', {}))) {
   app.log.verbose('additional tooling detected');
   // Add the tasks after we init the app
   _.forEach(utils.getToolingTasks(app.config.tooling, app), task => {
    app.log.debug('adding app cli task %s', task.name);
    const injectable = _.has(app, 'engine') ? app : lando;
    app.tasks.push(buildTask(task, injectable));
   });
  }
 });
origin: lando/lando

/*
 * Helper to load in all app plugins
 */
const loadPlugins = (app, lando) => Promise.resolve(app.plugins.registry)
 // Filter out
 .filter(plugin => _.has(plugin, 'app'))
 // LOADEM!
 .map(plugin => app.plugins.load(plugin, plugin.app, app, lando))
 // Remove any naughty shit
 .map(plugin => _.pick(plugin.data, ['config', 'composeData', 'env', 'labels']))
 // Merge minotaur
 .each(result => _.merge(app, result))
origin: lando/lando

/*
 * Parse docker-compose options
 */
const parseOptions = (opts = {}) => {
 const flags = _.map(composeFlags, (value, key) => _.get(opts, key, false) ? value : '');
 const environment = _.flatMap(opts.environment, (value, key) => ['--env', `${key}=${value}`]);
 const user = (_.has(opts, 'user')) ? ['--user', opts.user] : [];
 const workdir = (_.has(opts, 'workdir')) ? ['--workdir', opts.workdir] : [];
 const entrypoint = _.map(opts.entrypoint, entrypoint => ['--entrypoint', entrypoint]);
 return _.compact(_.flatten([flags, environment, user, workdir, entrypoint]));
}
origin: lando/lando

/*
 * Helper to determine bootstrap level
 */
const getBsLevel = (config, command) => {
 if (_.has(config, `tooling.${command}.level`)) return config.tooling[command].level;
 else return (!fs.existsSync(config.composeCache)) ? 'app' : 'engine';
}
origin: FormidableLabs/nodejs-dashboard

const getSize = function (parentSize, itemPosition) {
 const position = normalizePosition(itemPosition.position);
 if (_.has(position, "size")) {
  return position.size;
 }

 // Prevent last growing view from overflowing screen
 const round = itemPosition.offset.grow + position.grow === itemPosition.summary.grow
  ? Math.floor : Math.ceil;

 return round(
  (parentSize - itemPosition.summary.size) * position.grow / itemPosition.summary.grow
 );
}
origin: lando/lando

_.forEach(all, one => {
  if (_.has(one, 'options')) {
   _.forEach(one.options(lando), (option, key) => {
    // @TODO: get auto conflict assignment to work properly
    // @NOTE: maybe it doesn't and we should just do this manually?
    // _.set(options, `${key}.conflicts`, getConflicts(one.name, all, lando));
   });
   options = _.merge({}, one.options(lando), options);
  }
 });
origin: lando/lando

// Helper to run our build tasks
const runBuild = (lando, options = {}, steps = []) => lando.Promise.each(steps, step => {
 if (_.has(step, 'func')) {
  return step.func(options, lando);
 } else {
  step.cmd = (_.isFunction(step.cmd)) ? step.cmd(options) : step.cmd;
  return build.run(lando, build.buildRun(_.merge({}, build.runDefaults(lando, options), step)));
 };
})
origin: lando/lando

// If we don't have a builtAgainst already then we must be spinning up for the first time and its safe to set this
 app.events.on('post-start', () => {
  if (!_.has(app.meta, 'builtAgainst')) {
   lando.cache.set(app.metaCache, updateBuiltAgainst(app, app._config.version), {persist: true});
  }
  if (app.meta.builtAgainst !== app._config.version) {
   app.addWarning(warnings.rebuildWarning());
  }
 });
origin: lando/lando

// Add in local variable overrides as needed
  _.forEach(app.platformsh.config.applications, application => {
   if (_.has(app, `config.config.variables.${application.name}`)) {
    const overrides = _.get(app, `config.config.variables.${application.name}`, {});
    application.variables = _.merge({}, application.variables, overrides);
   }
  });
origin: lando/lando

// Categorize and colorize URLS if and as appropriate
 _.forEach(app.info, info => {
  if (_.has(info, 'urls') && !_.isEmpty(info.urls)) {
   urls[info.service] = _.filter(app.urls, item => {
    item.theme = chalk[item.color](item.url);
    return _.includes(info.urls, item.url);
   });
  }
 });
origin: lando/lando

_.forEach(types, type => {
  if (_.has(options, `config.${type}`)) {
   config[type] = options.config[type];
  } else if (!_.has(options, `config.${type}`) && _.has(options, `defaultFiles.${type}`)) {
   if (_.has(options, 'confDest')) {
    config[type] = path.join(options.confDest, options.defaultFiles[type]);
   }
  }
 });
origin: lando/lando

// Merge in process.env as relevant
 _.forEach(_.keys(config), key => {
  if (_.has(process.env, key)) {
   config[key] = process.env[key];
  }
 });
origin: lando/lando

// Merge in process.env as relevant
 _.forEach(_.keys(config), key => {
  if (_.has(process.env, key)) {
   config[key] = process.env[key];
  }
 });
origin: lando/lando

// Merge in process.env as relevant
 _.forEach(_.keys(config), key => {
  if (_.has(process.env, key)) {
   config[key] = process.env[key];
  }
 });
lodash(npm)LoDashStatichas

JSDoc

Checks if `path` is a direct property of `object`.

Most used lodash functions

  • LoDashStatic.map
    Creates an array of values by running each element in collection through iteratee. The iteratee is
  • LoDashStatic.isEmpty
    Checks if value is empty. A value is considered empty unless it’s an arguments object, array, string
  • LoDashStatic.forEach
    Iterates over elements of collection invoking iteratee for each element. The iteratee is invoked wit
  • LoDashStatic.find
    Iterates over elements of collection, returning the first element predicate returns truthy for.
  • LoDashStatic.pick
    Creates an object composed of the picked `object` properties.
  • LoDashStatic.get,
  • LoDashStatic.isArray,
  • LoDashStatic.filter,
  • LoDashStatic.merge,
  • LoDashStatic.isString,
  • LoDashStatic.isFunction,
  • LoDashStatic.assign,
  • LoDashStatic.extend,
  • LoDashStatic.includes,
  • LoDashStatic.keys,
  • LoDashStatic.cloneDeep,
  • LoDashStatic.uniq,
  • LoDashStatic.isObject,
  • LoDashStatic.omit

Popular in JavaScript

  • colors
    get colors in your node.js console
  • semver
    The semantic version parser used by npm.
  • moment
    Parse, validate, manipulate, and display dates
  • crypto
  • ws
    Simple to use, blazing fast and thoroughly tested websocket client and server for Node.js
  • commander
    the complete solution for node.js command-line programs
  • mongodb
    The official MongoDB driver for Node.js
  • js-yaml
    YAML 1.2 parser and serializer
  • fs
  • Best plugins for Eclipse
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJavascript Code Index
Get Tabnine for your IDE now