const walk = (q) => {
    const obj = {};
    for (const key in q) {
        if (key === 'schema') {
            obj[key] = q[key].type;
        }
        else {
            // if PROPDEF
            if (typeof q[key] === 'object') {
                obj[key] = walk(q[key]);
            }
            else {
                obj[key] = q[key];
            }
        }
    }
    return obj;
};
export const serialize = (q) => {
    const obj = walk(q);
    return JSON.stringify(obj);
};
export const parse = (str, parsedSchema) => {
    //
};
//# sourceMappingURL=serialize.js.map