Skip to content

Support for serving static files from a specific folder #746

Open
@fabiospampinato

Description

@fabiospampinato

Is your feature request related to a problem? Please describe.

My app's structure looks like this:

- app
  - src // Root of the app logic
    - index.tsx  
    - index.html
  - public // Root for the static assets
    - favicon.ico

I can't figure out how to make that work with WMR.

Describe the solution you'd like

I'd like to tell WMR: "try to find a static asset that matches the current query here (/public), otherwise find an entrypoint to serve here (/src)".

Describe alternatives you've considered

Putting a reverse proxy in front of WMR, but having that requirement would be super annoying during development.

Additional context

I'm try to migrate from Next.js, where you can just tell it where to serve static assets from easily.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions