Open boardend opened 4 years ago
Ahh, good catch. We can definitely get this fixed, I'm now working part-time on a windows machine so its easier to test. It looks like most of the path manipulation in that function needs to be normalized - likely to forward slashes, since they're URLs, but right now it's a mix.
On Windows 10 (CMD/PowerShell/Git Bash) the latest Critters version (1.3.5) is "Unable to locate stylesheet", but the same setup works without problems on a Unix-like system / WSL 2.
I think the problem is, that the path gets normalized in the "compilation.assets"-keys, but not in embedLinkedStylesheet. Here is the state in embedLinkedStylesheet on WSL2:
And the same commit, but with a clone on Windows in PowerShell:
so
compilation.assets[relativePath]
won't match, which will produce the following error: