Skip to content

Loading .vue Component from Server #46

Answered by huang-julien
Sazzels asked this question in Q&A
Discussion options

You must be logged in to vote

Hi 👋 thanks for your kind words 🙂 .
As stated in the playground, importing or defining a full component definition from an API is highly not recommanded since we must use new Function to eval the code.
I don't think that importing as a module from remote sources is possible 🤔 you would need to eval the code when receiving it.
For your information there's a future feature that might suit your needs instead of this module which is server component rendering from external sources (see nuxt/nuxt#12343).
For now i would suggest you (if i understood well) to use a wrapper component with a dynamic template. What do you think ?

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@Sazzels
Comment options

@huang-julien
Comment options

@Sazzels
Comment options

Answer selected by Sazzels
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants