Skip to content

Commit

Permalink
Fix createArrayCoreHandler in vue3
Browse files Browse the repository at this point in the history
  • Loading branch information
dk981234 committed Aug 22, 2023
1 parent c0303ec commit 8edbe4b
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions packages/survey-vue3-ui/src/base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,10 @@ Base.createPropertiesHash = () => {
function makeReactive(surveyElement: Base) {
if (!surveyElement || (surveyElement as any).__vueImplemented) return false;
surveyElement.createArrayCoreHandler = (hash, key: string): Array<any> => {
const arrayRef = shallowRef(hash[key]);
hash[key]["onArrayChanged"] = () => {
const arr: any = [];
const arrayRef = shallowRef(arr);

arr.onArrayChanged = () => {
triggerRef(arrayRef);
};
hash[key] = arrayRef;
Expand Down

0 comments on commit 8edbe4b

Please sign in to comment.