Is there a way to prevent layer installation in test config ?
Hello, as the title says, i'm looking to skip one layer installation only for tests, it's a layer meant to handle some middlewares and we would like to speed up (even if only by a tiny bit) the tests
3 Replies
Hi @Numil. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave:
----------------------
I'm sorry, but the knowledge sources do not contain explicit information about preventing or skipping the installation of a specific Nuxt layer only for tests. There are references to improvements in layer handling, such as named layer aliases and fixes for layer resolution, but nothing directly addresses conditional layer inclusion or exclusion based on the environment (like tests) feat(kit): add named layer aliases, fix(kit): do not skip layer with defined
srcDir.
If you need this functionality, you may need to look for more recent documentation or consider a custom solution, such as conditionally modifying your Nuxt configuration based on the environment, but this approach is not covered in the provided sources.
----------------------
Note: you can ask me a follow up question by @ mentioning me again :speech_balloon:
----------------------<@108292831583440896> Kapa.ai is still learning and improving, please let me know how I did by reacting below.
I'll need to look into the hook that initializes the layers then, thank you