Skip to content

Default source maps generated for DEV builds seem invalid? #11204

Closed
@bvaughn

Description

@bvaughn

Source maps generated for a create-react-app project in DEV mode seem slightly broken. Specifically, translating from a position in the (compiled) source to the original source returns a valid line number but it always returns an invalid column number of 0. (Production source maps are fine.)

Source map translation is being done with the source-map package.

This breaks an upcoming React DevTools feature ("named hooks") so I've filed an issue in the React repo with more details:
facebook/react#21868


create-react-app version: 4.0.3

Repro project: https://github.com/bvaughn/test-named-hooks


(Potentially related to older issues #6296 or #4683.)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions