Skip to content
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

Suppress warning during rendering chunks #9196

Closed
7 tasks done
mrtronje opened this issue Jul 18, 2022 · 0 comments · Fixed by #9210
Closed
7 tasks done

Suppress warning during rendering chunks #9196

mrtronje opened this issue Jul 18, 2022 · 0 comments · Fixed by #9210
Assignees
Labels
feat: css p2-nice-to-have Not breaking anything but nice to have (priority)

Comments

@mrtronje
Copy link

mrtronje commented Jul 18, 2022

Describe the bug

Since the update from vite v2 to v3 I get the following warning when I run yarn build:

image

Is there a way to suppress such warnings? I can't correct "overflow-X" because this comes from an external node module.

my configuration:

import { defineConfig } from 'vite';
import { svelte } from '@sveltejs/vite-plugin-svelte';

// https://vitejs.dev/config/
export default defineConfig({
    build: {
        chunkSizeWarningLimit: 4000,
        outDir: 'public',
        sourcemap: true,
    },
    plugins: [
        svelte({
            onwarn(warning, defaultHandler) {
                if (warning.code === 'a11y-invalid-attribute') return;
                defaultHandler(warning);
            },
        }),
    ],
    publicDir: 'public_vite',
    server: {
        proxy: {
            '/api': {
                target: 'https://app.lndo.site',
                changeOrigin: true,
                secure: false,
            },
        },
    },
});

Reproduction

https://stackblitz.com/edit/vitejs-vite-anx6q5?file=main.js to reproduce use npm install && npm run build

System Info

I don't have npx. However, since the warning also appears in the reproduction link, this information should not be necessary

Used Package Manager

yarn

Logs

No response

Validations

@sapphi-red sapphi-red added feat: css p2-nice-to-have Not breaking anything but nice to have (priority) labels Jul 19, 2022
@sapphi-red sapphi-red self-assigned this Jul 19, 2022
@github-actions github-actions bot locked and limited conversation to collaborators Aug 3, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feat: css p2-nice-to-have Not breaking anything but nice to have (priority)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants