nuxt-file-storage icon indicating copy to clipboard operation
nuxt-file-storage copied to clipboard

ERROR Please provide a mount path for the file storage module in your nuxt.config.js

Open andrzejkupczyk opened this issue 8 months ago • 2 comments

I’ve bumped the package from 0.2.9 to 0.3.0 and started getting the following error:

[!CAUTION] ERROR Please provide a mount path for the file storage module in your nuxt.config.js

Here’s how I’ve configured the module in my nuxt.config.ts file:

export default defineNuxtConfig({
  // ...
  modules: [
    // ...
    'nuxt-file-storage',
  ],
  fileStorage: {
    mount: process.env.mount,
  },
}

I see a few issues with this:

  • First (and most obviously), the error is being printed. As far as I understand, it shouldn’t be logged at all—and even if it were, I’d consider it more of a warning than an error.
  • Second, my use case involves storing files on S3, so I shouldn’t be required to provide a mount path.
  • And finally, if mount: process.env.mount is the recommended setup, maybe it could be set as the default?

For now, I’ve reverted to the older version, but just a heads-up—it might be something worth looking into. Cheers!

andrzejkupczyk avatar Apr 06 '25 11:04 andrzejkupczyk

I might've overlooked this use case, I have built this library mainly to store files directly in the project. I will remove this warning but please let me know if you find any other issues while using this module to store files on S3

NyllRE avatar Apr 06 '25 12:04 NyllRE

~~I mean, I tried configuring this setting just to satisfy the package requirements, but I must have missed something—because it didn’t work for me.~~

Sure thing—I’ll let you know. Thanks in advance!

andrzejkupczyk avatar Apr 06 '25 15:04 andrzejkupczyk