A
A
Alexey Segodin2019-11-06 01:47:43
JavaScript
Alexey Segodin, 2019-11-06 01:47:43

What does the workflow look like when developing (website) in Node.JS with ES6 modules?

Hey!
I ran into this problem: I'm slowly starting to figure out how ES6 modules work, and it turned out that it's so slow that it's simply impossible to write code.
Here's what my process looks like now:

  1. noticed that I have an error in my code
  2. stop local server
  3. correcting a mistake
  4. I start building the project, for example, through Webpack
  5. start the server

... and so on in a circle: from point 5 to point 1. I just started and I already feel bad from such a process. The speed of writing code has decreased by 10 times.
Tell me, maybe I don’t know something and don’t understand some of the most basic principles of development?
I really hope I'm wrong or I don't know something. Because what I described above does not look like modern website development in the 21st century, where everyone is completely switching to ES6 modules.
Thanks in advance!
Update:
This is how long it takes to modify a JS file and save the changes. In general, everything that is described in paragraphs 1-5 above (about 25 seconds):
5dc20a16c3094470811564.gif

Answer the question

In order to leave comments, you need to log in

3 answer(s)
A
abberati, 2019-11-06
@Aleksei_Segodin

Webpack devserver does items 2,4,5 automatically.

M
McBernar, 2019-11-06
@McBernar

Well kamon. hot reload. If you don’t want to figure it out yourself, watch a couple of videos on YouTube on the initial setup of webpack.

V
Vladimir Golub, 2019-11-06
@RazerVG

nodemon, and here is webpack if you run the server on node.js

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question