A
A
Artem2017-09-21 02:29:10
Python
Artem, 2017-09-21 02:29:10

How to set up a dev environment for a python application using reactjs?

The server part is based on python.
For development, flask raises its own web server, which I connect to for testing.
Python collects the html page and sends it to the client.
On the client side, I plan to use reactjs.
I use the gulp + babel + webpack bundle for assembly.
Namely: gulp tracks changes in jsx files, launches babel to get es5 code, after which webpack is launched to collect all modules and spit out the finished js file, which I include in html.
The problem is that webpack builds this file for a critically long time (5-8 seconds), which is a lot for testing, especially when changes are made often and little by little. If you make changes when webpack is running, that everything will break altogether
I understand that somehow it can be configured, but I do not understand how.
Perhaps someone faced a similar problem?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Artem Kislenko, 2017-09-21
@Cruper

And why don't you track changes by webpack itself - as far as I know, in this case, the build speed increases several times.

E
Evgeny Kalibrov, 2017-09-21
@rework

gulp + babel + webpack - why did you mix everything together, babel, at least I would throw it out of this chain.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question