Sha256: d1d91a376cb3383e4c595a34b596fdff9cc0fd6187879b6a86e2ea7846d2b7d3

Contents?: true

Size: 1.12 KB

Versions: 210

Compression:

Stored size: 1.12 KB

Contents

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

{{
  var $currentBaseId = $it.baseId
    , $prevValid = 'prevValid' + $lvl
    , $passingSchemas = 'passingSchemas' + $lvl;
}}

var {{=$errs}} = errors
  , {{=$prevValid}} = false
  , {{=$valid}} = false
  , {{=$passingSchemas}} = null;

{{# def.setCompositeRule }}

{{~ $schema:$sch:$i }}
  {{? {{# def.nonEmptySchema:$sch }} }}
    {{
      $it.schema = $sch;
      $it.schemaPath = $schemaPath + '[' + $i + ']';
      $it.errSchemaPath = $errSchemaPath + '/' + $i;
    }}

    {{# def.insertSubschemaCode }}
  {{??}}
    var {{=$nextValid}} = true;
  {{?}}

  {{? $i }}
    if ({{=$nextValid}} && {{=$prevValid}}) {
      {{=$valid}} = false;
      {{=$passingSchemas}} = [{{=$passingSchemas}}, {{=$i}}];
    } else {
    {{ $closingBraces += '}'; }}
  {{?}}

    if ({{=$nextValid}}) {
      {{=$valid}} = {{=$prevValid}} = true;
      {{=$passingSchemas}} = {{=$i}};
    }
{{~}}

{{# def.resetCompositeRule }}

{{= $closingBraces }}

if (!{{=$valid}}) {
  {{# def.extraError:'oneOf' }}
} else {
  {{# def.resetErrors }}
{{? it.opts.allErrors }} } {{?}}

Version data entries

210 entries across 153 versions & 17 rubygems

Version Path
disco_app-0.18.4 test/dummy/node_modules/css-loader/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.18.4 test/dummy/node_modules/sass-loader/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.18.4 test/dummy/node_modules/@rails/webpacker/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.18.4 test/dummy/node_modules/file-loader/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.18.4 test/dummy/node_modules/style-loader/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.18.1 test/dummy/node_modules/sass-loader/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.18.1 test/dummy/node_modules/css-loader/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.18.1 test/dummy/node_modules/file-loader/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.18.1 test/dummy/node_modules/babel-loader/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.18.1 test/dummy/node_modules/compression-webpack-plugin/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.18.1 test/dummy/node_modules/@rails/webpacker/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.18.1 test/dummy/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.18.1 test/dummy/node_modules/style-loader/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.12.7.pre.puma.pre.3 test/dummy/node_modules/babel-loader/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.12.7.pre.puma.pre.3 test/dummy/node_modules/compression-webpack-plugin/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.12.7.pre.puma.pre.3 test/dummy/node_modules/css-loader/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.12.7.pre.puma.pre.3 test/dummy/node_modules/style-loader/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.12.7.pre.puma.pre.3 test/dummy/node_modules/sass-loader/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.12.7.pre.puma.pre.3 test/dummy/node_modules/file-loader/node_modules/ajv/lib/dot/oneOf.jst
disco_app-0.12.7.pre.puma.pre.3 test/dummy/node_modules/@rails/webpacker/node_modules/ajv/lib/dot/oneOf.jst