json.js 586 B

12345678910111213141516171819202122232425
  1. // Standard YAML's JSON schema.
  2. // http://www.yaml.org/spec/1.2/spec.html#id2803231
  3. //
  4. // NOTE: JS-YAML does not support schema-specific tag resolution restrictions.
  5. // So, this schema is not such strict as defined in the YAML specification.
  6. // It allows numbers in binary notaion, use `Null` and `NULL` as `null`, etc.
  7. 'use strict';
  8. var Schema = require('../schema');
  9. module.exports = new Schema({
  10. include: [
  11. require('./failsafe')
  12. ],
  13. implicit: [
  14. require('../type/null'),
  15. require('../type/bool'),
  16. require('../type/int'),
  17. require('../type/float')
  18. ]
  19. });