Created by: Timer
Turns out that the path
module stubbed into a web environment does not support Windows, nor contains the posix
/ win32
variants of path (it's fixed posix
, so path.sep
returns /
in a win32 environment).
Effectively, what happened here is that the fileName
was C:\foo\bar
and upon normalizing, remained C:\foo\bar
(it should've switched to /
, or more specifically, path.sep
).
This aligns the behavior with the other path normalization process as seen here: https://github.com/facebookincubator/create-react-app/blob/b17fa4123e2d098d943f4b33ae9c5c2ac311fab6/packages/react-error-overlay/src/utils/unmapper.js#L67
Fixes #3078 (closed).