patternlab-node-cli
patternlab-node-cli copied to clipboard
Watching with serve doesn't work on Windows
General information
- NodeJS version: 9.4.0
- NPM version: 6.4.1
Problem description
On Windows 10 the use of path
often returns \
as the path separator. As described in paulmillr/chokidar#777 this causes watched paths with globs to fail.
(Edited) The (temporary?) solution is to use replace(/\\/g, '/')
on the path strings to ensure /
is used instead.
I could open a PR if that's helpful.
Reproduction steps
With an initialized patternlab: ./node_modules/.bin/patternlab serve --watch