Skip to content

Rewatch allows two different package specs with the same suffix #8177

@cknitt

Description

@cknitt

This works fine in rewatch - for an input file A.res, both A.cjs and A.mjs are produced:

{
  "name": "x",
  "sources": ".",
  "package-specs": [
    {
      "module": "commonjs",
      "in-source": true,
      "suffix": ".cjs"
    },
    {
      "module": "esmodule",
      "in-source": true,
      "suffix": ".mjs"
    }
  ]
}

However, it is possible to specify the same suffix twice (or omit it for both, defaulting to .js), leading to undefined/unexpected behavior.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions