Skip to content

vercel target: function named index shadows a static index.html at / #687

Closed

Description

@blove

Problem

The vercel target names its function index (.vercel/output/functions/index.func). In the Build Output API a function named index is also served at /, so it shadows a static index.html. Any app that ships a frontend beside the runtime has to rename the function (hashbrown's assembler copies it as agent.func) — see liveloveapp/hashbrown@cf3f94f.

Proposal

Default the function to a non-root name (e.g. b4.func or agent.func) with matching routes, and/or expose build.vercel.functionName.

Related: #679.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions