Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
mounted() {
const id = this.$route.params.id;
const memo = isNaN(id) === true ? Memo.createNew() : this.$store.getters['memo/getMemo'](id);
this.memo = memo;
this.snackbar = MDCSnackbar.attachTo(document.querySelector('.mdc-snackbar'));
MDCRipple.attachTo(document.querySelector('.mdc-button'));
},
destroyed() {
mounted () {
this.mdcSnackbar = MDCSnackbar.attachTo(this.$el)
this.mdcSnackbar.timeoutMs = this.timeoutMs
this.mdcSnackbar.closeOnEscape = this.closeOnEscape
if (this.labelText && this.labelText !== '') this.mdcSnackbar.labelText = this.labelText
if (this.actionButtonText && this.actionButtonText !== '') this.mdcSnackbar.actionButtonText = this.actionButtonText
},
beforeDestroy () {