SAFE-Stack / SAFE-BookStore

Working sample of a SAFE-Stack project with hot reloading
https://safebookstore.azurewebsites.net/
The Unlicense
492 stars 149 forks source link

if you hit enter on "webpack: Compiled successfully." it ends the process #73

Closed geraldodev closed 7 years ago

geraldodev commented 7 years ago

Description

./build.sh run

if you hit enter on "webpack: Compiled successfully." it says Process terminated, it really ends the app serving on localhost:8080 but it does not end the process. It keeps working until you Control-C which causes an exception to be shown.

1) The enter key is a usability problem imho, because you want the window open because you want to see the http traffic arriving on the server. I accidentaly press enter and have to start over.

2) There are times that the "Compiled successsfully" is not shown. It stucks at 95%, but odily if you refresh the browser it is working. (some terminal buffering issue I suppose)

Related information

alfonsogarciacaro commented 7 years ago

Hi @geraldodev! There are two things happening here: Fable watch mode (frontend) and dotnet watch run (for Suave backend server). I think the enter key just finishes the Fable watch mode (though this is going to change in Fable's next version). What's the behaviour you're expecing?

geraldodev commented 7 years ago

@alfonsogarciacaro I prefer to hit Ctrl C to stop the process, because I use tmux with many subwindows and alt tab a lot so I ll hit the enter eventually disrupting the development flow. Off course the Ctrl C which at the moment shows an exception might deceive some users, but it's better than Enter imo.

Let me spoil this opportunity to thank you and all ppl involved on the F# ecosystem. The sound rooted language + JS world seems to be a powerfull combination. ReasonML opened my eyes to OCaml which drove me to F# (dotnetcore) which drove me to Suave + Fable. I'm learning the language ATM. Today I've discovered elmish. What a nice surprise! elm ideas with react components.

alfonsogarciacaro commented 7 years ago

@geraldodev Thanks a lot for the nice words. Yes, there are many FP languages moving to the JS ecosystem at the moment, and we are all trying to find our niche ;) In Fable we try to make it possible to use already existing technologies: F#, React, Elm without having to reinvent the wheel all the time.

Thanks also for your usability comments, I'm going to update this repo soon to Fable 1.0 which won't use the Enter key to stop watching anymore so hopefully that will solve the issue :)

LuisGuillerm0 commented 6 years ago

✌️