download
raw
700 Bytes
'use strict'
const { test } = require('node:test')
const build = require('..')
test('use enum without type', (t) => {
t.plan(1)
const stringify = build({
title: 'Example Schema',
type: 'object',
properties: {
order: {
type: 'string',
enum: ['asc', 'desc']
}
}
})
const obj = { order: 'asc' }
t.assert.equal('{"order":"asc"}', stringify(obj))
})
test('use enum without type', (t) => {
t.plan(1)
const stringify = build({
title: 'Example Schema',
type: 'object',
properties: {
order: {
enum: ['asc', 'desc']
}
}
})
const obj = { order: 'asc' }
t.assert.equal('{"order":"asc"}', stringify(obj))
})

Xet Storage Details

Size:
700 Bytes
·
Xet hash:
cb2c19865be6fbd69d1c5998756d013fdb2e2298b5dda42d840df3b1ff0f5e7b

Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.