maroo
Is it safe to use useFetch() inside a function?
Is it unsafe to use
useFetch()
inside a function? After making a POST request, the request repeats every time the reactive variable ref()
is changed within the page. Could this be a bug?
Please refer to the minimal example: https://codesandbox.io/p/devbox/h4cqq2?file=%2Fapp.vue%3A28%2C96 replies
How can I use defineModel in modules?
I am writing a module that supplies a number of components to help with input and output.
I want to simplify the implementation by using
defineModel
, but it doesn't work as expected.
I can avoid the error by specifying nuxt.options.vite.vue.script['defineModel'] = true
in the module's setup()
.
But substituting a .value
does not change the value
Where should I refer to change the vite option when compiling a module?1 replies
Big cache file for yaml in nuxt/content module
When I tried to serve hundreds of yaml files in a static build using nuxt content, I found that it created a very big
.output/public/cache.XXXXX.json
file.
Unlike a markdown file, where only the frontmatter is indexed, having all fields cached and growing to several megabytes is not the desired effect.
Is there any way to prevent certain fields from being cached?
BTW, the tag has no content
.1 replies