Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Any Of , One OF Array Or Object Does Not Work #751

Closed
vincentsixty opened this issue Nov 1, 2017 · 3 comments
Closed

Any Of , One OF Array Or Object Does Not Work #751

vincentsixty opened this issue Nov 1, 2017 · 3 comments

Comments

@vincentsixty
Copy link

    const schema =
   {
        "oneOf": [
            {"$ref": "#/definitions/singleObject"}, // plain object
            {
                "type": "array", // array of plain objects
                "items": {"$ref": "#/definitions/singleObject"}
            }
        ],
        "definitions": {
            "singleObject": {
                "type": 'object',
                "additionalProperties": false,
                "properties": {
                    "author": {
                        "type": 'number',
                        "required": true
                    }

                }
            }
        }
    };


    const formData = [{author: 2}];
@vincentsixty
Copy link
Author

any one ?

@joshgagnon
Copy link

As per the docs, oneOf etc is not supported. This is deal breaker for me.

@glasserc
Copy link
Contributor

glasserc commented Jan 5, 2018

Duplicate of #52.

@glasserc glasserc closed this as completed Jan 5, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants