-
-
Notifications
You must be signed in to change notification settings - Fork 662
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Vuetify components are not fully rendered in markdown files (.md) #700
Comments
After perform some proofs of concept I think the problem is adding the class attribute in Vue components. If I replace the previous class attributes with style attributes containing the equivalent css rules all works fine. It seems that adding classes in vue components inside markdown files avoid that attribute to be modified by javascript of Vuetify components. So internally are executed but the style are not loaded as some css classes are missing. Is this a @nuxt/content bug that converts the class attribute into a permanent one? Or is this a known issue and I cannot use the class attribute in markdown files for custom vue components? Thank you so much. |
Hi again! By the moment I am using a workaround that doesn't require style attribute. As the code Is very tedious adding true expression for every custom class, but you can use all UI framework given classes by this way. Hope this way be useful for more users with the same issue like me. |
For me, this doesn't occur in the dev build but occurs after nuxt generate |
Meet the same problem when tried to use Vuetify components inside markdown. @jualoppaz in my case (nuxt 2.14.12 & content 1.11.1) there is no partial rendering. Vuetify components doesn't rendered at all while generating. <button data-v-f58a9f50="" type="button" class="v-btn v-btn--contained theme--dark v-size--default">
<span class="v-btn__content">
Button
</span>
</button> But when I run |
@magpiedigital look here dialog about that: #221 (comment) Shortly: I tried to do what was described, got failed and asked how-to (cause I'm newbie). As result to make working import Vue from 'vue' // needed to use Vue.component() function
import { VAlert } from 'vuetify/lib' // component which I need to work in markdown
// import as many component as you need to use in markdown files and add them all
Vue.component('VAlert', VAlert) // adding component globally In that case But another problem appears - the code above raise error |
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 30 days. |
Version
@nuxt/content: 1.11.1
nuxt: 2.14.12
Steps to reproduce
What is Expected?
What is actually happening?
Using v-card component outside the markdown file
As you can see, the main card styles are loaded, but tags are not fully rendered. Main v-card component is right rendered but v-card-title default classes are overwritten by the given ones.
Using v-card componente in the markdown file
In this case, no compontent is fully rendered. In this case you cannot see any card style around the text.
After reading the issue #221 I tried to import the used components in my vue page and adding the vuetify transpile option in nuxt.config.js file, but I didn't experiment any difference.
I could do this task in the past with other UI frameworks like Element UI, but I can't guess the reason this is not working with Vuetify framework. Does Vuetify require any custom config or do I must write my markdown code in another way?
Thank you so much.
The text was updated successfully, but these errors were encountered: