[READ-ONLY] Mirror of https://github.com/danielroe/nuxt3-playground. Playground for Nuxt3
779 B
26 lines
1import { defineNuxtConfig } from 'nuxt'
2import { execaCommand } from 'execa'
3
4// https://v3.nuxtjs.org/api/configuration/nuxt.config
5export default defineNuxtConfig({
6 hooks: {
7 'vite:extendConfig': async (config, { isServer }) => {
8 if (isServer) {
9 config.build.rollupOptions.inlineDynamicImports = true
10 }
11 console.log({
12 plugin: config.plugins.find(p => p.name === 'nuxt:composable-keys'),
13 })
14 config.plugins = config.plugins.filter(
15 p => p.name !== 'nuxt:composable-keys'
16 )
17 },
18 'nitro:init'(nitro) {
19 nitro.hooks.hook('compiled', async () => {
20 await execaCommand(
21 'tar -cvzf dist/app.tgz --exclude node_modules --exclude .git --exclude dist/app.tgz .'
22 )
23 })
24 },
25 },
26})