Skip to content

Support publishConfig.directory #414

@Janpot

Description

@Janpot

Clear and concise description of the problem

Currently publishing packages with pnpm publishConfig.directory. This setting causes the specified folder to be published instead of the package root folder. We generate a ./dist/package.json file with exports translated from exports in the ./package.json (those point to our sources). This feature would avoid us from having exports.devExports rewriting the package.json constantly between production and development.

Suggested solution

When publishConfig.directory is set in package.json, copy the package.json to the output folder and rewrite the exports field

Alternative

No response

Additional context

Reflecting on this, I presume the current solution has superior "transpilePackages" support

Validations

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions