Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

nepster's avatar

how can i use several static sources? (Laravel + vite)?

I use docker and local domain with custom port: ppasta.loc:7070. my laravel app is working fine.

my vite config:

    server: {
        host: '0.0.0.0',
        port: 7071,
    },

vite server works.

But, I faced the problem of statistics from my public. I have some images in my public, and if I use it into my scss, i can't see it on vite live mode.

file from public:

background-image: url('/path/my.img');

doesn't see vite on live mode.

yes, I understand, if I copy images from public to resources, everything will work. But still how to teach vite see files from public and resources together?

0 likes
0 replies

Please or to participate in this conversation.