Open mrleblanc101 opened 1 year ago
@ktquez Had any chance to look into this ?
I think you need to change Vue.prototype
to app.config.globalPropriety
in Vue 3: https://v3-migration.vuejs.org/breaking-changes/global-api.html#vue-prototype-replaced-by-config-globalproperties
Found an alternative, just use a dynamic key
with the colorMode as the value which reload the component completely on change forcing the init
function to rerun.
<ClientOnly>
<Disqus class="mt-8" :key="colorMode.value" />
</ClientOnly>
Hello @mrleblanc101, how are you?
I'll take a look and as soon as I publish a new version, I'll let you know here.
@ktquez It's all good, I think we could simply document my solution in the README for Vue 3, don't need to change anything
@mrleblanc101 you are a godsend my man. :key
still fixes reload issue.
I see you provide
app.provide(Symbol('disqus'), disqusConfig)
, but since you don't export the symbol, we cannot import it to use for theinject
. See the documentation here: https://vuejs.org/guide/components/provide-inject.html#working-with-symbol-keys