@nolwenture/formik-jsonschema-form 0.20.0 → 0.20.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -123,10 +123,11 @@ export function createValidationSchema(schema, definitions = {}, condition) {
|
|
|
123
123
|
const schemaDefinitions = Object.assign(Object.assign({}, definitions), ((_a = schema.definitions) !== null && _a !== void 0 ? _a : {}));
|
|
124
124
|
const requiredFields = schema.required;
|
|
125
125
|
function getValue(schema, key) {
|
|
126
|
-
|
|
126
|
+
let type = schema.type;
|
|
127
127
|
let yupSchema;
|
|
128
128
|
if (schema.properties) {
|
|
129
129
|
yupSchema = createValidationSchema(schema, schemaDefinitions);
|
|
130
|
+
type = type !== null && type !== void 0 ? type : "object";
|
|
130
131
|
}
|
|
131
132
|
else {
|
|
132
133
|
yupSchema = getYupType(type);
|