Open scamden opened 3 years ago
You're running these in two different console windows in the same CWD, right?
Webpack probably keeps on detecting writes to the lib
folder. The simplest solution would be to include a start+test mode that both runs the Webpack server and the test watcher. That shouldn't be too hard. Maybe a test --serve
command? Thoughts?
ya i think that's exactly right. i was thinking start --tests
, but actually i think the ideal is start --no-tests
and have tests run with server by default. (at least that's the workflow i've always used). aside from being how i like to develop. there's the benefit of having a universal start
command that let's us run test watch for node library packages and test watch and server for node and web endpoints. that makes all heft commands meaningful for all packages and simply picks up whatver server-y sorts of things they have configured (basically jest and webpack but structurally could be an express server or other)
Repro (in a project that has both jest and webpack dev configured):
heft test --watch
heft start
Expected both servers start and watch compiled output
Result webpack server starts looping infinitely
(Perhaps this is due to having two different heft build watches going, i think the ideal fix here would be to have an option for heft start to also run a test watch so there is only one ts build going)