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

Cant call validate() #54

Open
WWUMasoudRamuz opened this issue Jan 25, 2022 · 1 comment
Open

Cant call validate() #54

WWUMasoudRamuz opened this issue Jan 25, 2022 · 1 comment

Comments

@WWUMasoudRamuz
Copy link

<v-jsoneditor ref='vje' id="ved" v-model="row.value" :options="options" :plus="false" @error="onError"/>

public validator() { return (this.$refs.vje as VJsoneditor).validate(); }

[Vue warn]: Error in v-on handler (Promise/async): "TypeError: this.$refs.vje.validate is not a function"

How do I check if JSON is valid?

@nNoctuam
Copy link

To future readers: as author replied there, you should call not .validate(), but .editor.validate()

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

2 participants