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

Regression loading array data with v 2.7.0 #426

Open
kottle opened this issue Jan 12, 2022 · 0 comments
Open

Regression loading array data with v 2.7.0 #426

kottle opened this issue Jan 12, 2022 · 0 comments

Comments

@kottle
Copy link

kottle commented Jan 12, 2022

After version: 2.5.9 has been introduced a bug so the library cannot load data from array, the scenario is very simple and reproducible running ngx-schema-form-demo with:
sampleschema.json:

{
    "$schema": "http://json-schema.org/draft-04/hyper-schema#",
    "type": "object",
    "properties": {
        "contributors": {
            "description": "Contributors",
            "type": "array",
            "items": {
                "type": "string",
                "widget": {
                    "id": "string"
                }
            }
        }
    }
}

samplemodel.json:

{
    "contributors": [
        "first",
        "second"
    ]
}

The result is an empty array
Schermata del 2022-01-12 23-08-16

As suggested in #318 by aderman I locally fixed uncommenting reset in form.component

` if (this.model) {
        // this.rootProperty.reset(this.model, false);
} 

`

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

1 participant