sapphi-red / vite-plugin-static-copy

rollup-plugin-copy with dev server support.
MIT License
299 stars 32 forks source link

It doesn't copy any files #113

Closed thany closed 7 months ago

thany commented 7 months ago

In the log it says:

[vite-plugin-static-copy] Collected 5 items.

So I'm like "great..... and where are they?" because I then go to the specified target directory, and they're not there. So the question becomes two-fold in my mind:

  1. Where are the files copied to, if not the directory specified?
  2. How to enable verbose logging, e.g. to see which file is being copied where?

This greatly helps in setting things up, as opposed to "blindly" having to trust that the plugin and I both have the same idea of what both directories are relative to, and how they are expected to be formatted.

Here's my config:

    viteStaticCopy({
      targets: [
        {
          src: 'public/assets/images/*',
          dest: 'assets/Platform3/images',
        },
      ],
    }),

The outDir is set to 'dist'. So while it has collected 5 items (or claims to have), the dist folder remains empty. I've checked, and the target folder definitely has the correct permissions set. So is dest not formatted correctly or something? If only it would verbosely show what's going on.