inject-manifest-schema.js 595 B

1234567891011121314151617181920212223
  1. "use strict";
  2. /*
  3. Copyright 2018 Google LLC
  4. Use of this source code is governed by an MIT-style
  5. license that can be found in the LICENSE file or at
  6. https://opensource.org/licenses/MIT.
  7. */
  8. const joi = require('@hapi/joi');
  9. const baseSchema = require('./base-schema');
  10. const defaults = require('./defaults');
  11. const regExpObject = require('./reg-exp-object');
  12. module.exports = baseSchema.keys({
  13. globDirectory: joi.string().required(),
  14. injectionPointRegexp: regExpObject.default(defaults.injectionPointRegexp),
  15. swSrc: joi.string().required(),
  16. swDest: joi.string().required()
  17. });