Skip to content

Commit

Permalink
hot-fix: resolve saving error and cleaning changes.
Browse files Browse the repository at this point in the history
  • Loading branch information
Jenesius committed Aug 19, 2023
1 parent 5089194 commit 60483a9
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions examples/input-select/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
import {Form, InputField, useFormValues} from "../../src";
const form = new Form();
// @ts-ignore
window.form = form
const values = useFormValues(form);
/*JUST ENUMS*/
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "jenesius-vue-form",
"version": "3.0.0-rc.2",
"version": "3.0.0-rc.4",
"description": "Heavy form system for Vue.js",
"type": "module",
"author": "Jenesius",
Expand Down
2 changes: 1 addition & 1 deletion src/classes/Form.ts
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,7 @@ export default class Form extends EventEmitter implements FormDependence {
return acc;
}, []))

if (this.#saveData) {
if (this.#saveData || !this.parent) {
array.push(() => this.#saveData?.())
array.push((data: any) => this.emit(Form.EVENT_SAVE, data));
/**
Expand Down

0 comments on commit 60483a9

Please sign in to comment.