Sha256: 9076a5ff50df0a5952444ac2cc65993a3525ddf104aa67e1d6ca0e956f5a7f49

Contents?: true

Size: 677 Bytes

Versions: 102

Compression:

Stored size: 677 Bytes

Contents

{{# def.definitions }}
{{# def.errors }}
{{# def.setupKeyword }}

{{
  var $key = 'key' + $lvl
    , $matched = 'patternMatched' + $lvl
    , $closingBraces = ''
    , $ownProperties = it.opts.ownProperties;
}}

var {{=$valid}} = true;
{{~ $schema:$pProperty }}
  var {{=$matched}} = false;
  for (var {{=$key}} in {{=$data}}) {
    {{# def.checkOwnProperty }}
    {{=$matched}} = {{= it.usePattern($pProperty) }}.test({{=$key}});
    if ({{=$matched}}) break;
  }

  {{ var $missingPattern = it.util.escapeQuotes($pProperty); }}
  if (!{{=$matched}}) {
    {{=$valid}} = false;
    {{# def.addError:'patternRequired' }}
  } {{# def.elseIfValid }}
{{~}}

{{= $closingBraces }}

Version data entries

102 entries across 53 versions & 7 rubygems

Version Path
ilog-0.4.1 node_modules/ajv/lib/dot/v5/patternRequired.jst
ilog-0.4.1 node_modules/ajv-keywords/keywords/dot/patternRequired.jst
ilog-0.4.0 node_modules/ajv-keywords/keywords/dot/patternRequired.jst
ilog-0.4.0 node_modules/ajv/lib/dot/v5/patternRequired.jst
ilog-0.3.3 node_modules/ajv-keywords/keywords/dot/patternRequired.jst
ilog-0.3.3 node_modules/ajv/lib/dot/v5/patternRequired.jst
govuk_publishing_components-18.0.0 node_modules/ajv-keywords/keywords/dot/patternRequired.jst
govuk_publishing_components-18.0.0 node_modules/ajv/lib/dot/v5/patternRequired.jst
govuk_publishing_components-17.21.0 node_modules/ajv-keywords/keywords/dot/patternRequired.jst
govuk_publishing_components-17.21.0 node_modules/ajv/lib/dot/v5/patternRequired.jst
govuk_publishing_components-17.20.0 node_modules/ajv-keywords/keywords/dot/patternRequired.jst
govuk_publishing_components-17.20.0 node_modules/ajv/lib/dot/v5/patternRequired.jst
govuk_publishing_components-17.19.1 node_modules/ajv-keywords/keywords/dot/patternRequired.jst
govuk_publishing_components-17.19.1 node_modules/ajv/lib/dot/v5/patternRequired.jst
govuk_publishing_components-17.19.0 node_modules/ajv-keywords/keywords/dot/patternRequired.jst
govuk_publishing_components-17.19.0 node_modules/ajv/lib/dot/v5/patternRequired.jst
govuk_publishing_components-17.18.0 node_modules/ajv-keywords/keywords/dot/patternRequired.jst
govuk_publishing_components-17.18.0 node_modules/ajv/lib/dot/v5/patternRequired.jst
govuk_publishing_components-17.17.0 node_modules/ajv-keywords/keywords/dot/patternRequired.jst
govuk_publishing_components-17.17.0 node_modules/ajv/lib/dot/v5/patternRequired.jst