Skip to content

Commit

Permalink
experimental: add meta info for intlify tools (#1139)
Browse files Browse the repository at this point in the history
  • Loading branch information
kazupon committed Mar 8, 2021
1 parent 400ceab commit 649ea8e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/mixin.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,12 @@ export default {
}
},

mounted (): void {
if (this !== this.$root && this.$options.__INTLIFY_META__ && this.$el) {
this.$el.setAttribute('data-intlify', this.$options.__INTLIFY_META__)
}
},

beforeDestroy (): void {
if (!this._i18n) { return }

Expand Down

0 comments on commit 649ea8e

Please sign in to comment.