Skip to content

bug: Wrong sourcemap emitting #6207

Closed
Closed

Description

@Tallyb

Prerequisites

Stencil Version

4.28.1/2 (maybe 0, but I cannot build in 0)

Current Behavior

In version 4.27.2 building dist output:

  • Setting sourcemap to false will not generate .js.map files and no reference is added to the js file (both esm and cjs).
  • Setting sourcemap to true will generate js.map files and a single reference is added to the js file.

In version 4.28.1

  • setting sourcemap to false will generate an empty js.map file that contains:
    {"sourcesContent":[]} and a reference is added to the js file
  • Setting sourcemap to true generates js map files and adding 2 references in the js file

Expected Behavior

The 4.27.2 behaviour is the correct one.

System Info

System: node 22.13.1
    Platform: darwin (24.3.0)
   CPU Model: Apple M4 Max (16 cpus)
    Compiler: /Users/tally/yoobic/yoobic-ng-6/node_modules/@stencil/core/compiler/stencil.js
       Build: 1741825324
     Stencil: 4.28.1 🐵
  TypeScript: 5.5.4
      Rollup: 4.34.9
      Parse5: 7.2.1
      jQuery: 4.0.0-pre
      Terser: 5.37.0

Steps to Reproduce

Build as described above and check the links

Code Reproduction URL

not needed. any build will do.

Additional Information

Rollup upstream issue, most likely. or this: https://github.com/stenciljs/core/pull/6187/files#diff-7ae45ad102eab3b6d7e7896acd08c427a9b25b346470d7bc6507b6481575d519R131

Activity

  1. changed the title [-]bug: sourcemap link is emitted twice[/-] [+]bug: Wrong sourcemap emitting[/+] on Mar 18, 2025
  2. added
    Bug: Validated
    on Mar 18, 2025
  3. johnjenkins commented on Dec 11, 2025

    @johnjenkins
    Contributor

    hey @Tallyb - I've just checked this out with latest Stencil and everything seems to work as described in 4.27.2 again 🥳

    I'm going to close this one out - lemme know if I've missed something and I'll re-open

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Bug: ValidatedHelp Wanted

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions