Here is a snippet of my Vue component code highlighting a specific issue:
<template>
<span splitpanes-default="70">
Details Pane
<uploader v-if="isUpload" class="uploader-example">
<uploader-unsupport></uploader-unsupport>
<uploader-drop>
<p>Drop files here to upload or</p>
<uploader-btn>select files</uploader-btn>
<uploader-btn :directory="true">select folder</uploader-btn>
</uploader-drop>
<uploader-list></uploader-list>
</uploader>
</span>
</template>
<script lang="ts">
import { Component, Vue } from 'vue-property-decorator';
import uploader from 'vue-simple-uploader';
Vue.use(uploader);
@Component()
export default class In extends Vue {
public isUpload: boolean = false;
public upload() {
this.isUpload = true;
}
}
</script>
After calling the upload method (for example, on a button click), the "isUpload" property is correctly set to true, but the uploader component does not display.
It appears that the property is not reactive. What steps should I take to ensure reactivity?