D
D
Dmitry Sviridov2020-02-06 00:47:28
Django
Dmitry Sviridov, 2020-02-06 00:47:28

How to properly set up frontend build for Django?

In general, I would like to understand how to do this in Django:

  1. When collectstatic is launched, the js files are merged into one, the code is also obfuscated
  2. Converting SCSS to css and merging css files into one with obfuscation
  3. It is desirable that you can install js-libs via npm, if necessary

What are ready-made proven solutions for such a task? Maybe somehow the webpack is screwed? The truth is not crutches at all, but how it is done in the right way in the case of Django. Found this https://github.com/valerymelou/cookiecutter-django... but maybe there is a more recent approach?

Ps The proposal to make a front on React / Angular / Vue (collect it with webpack) and API using DRF in my case, unfortunately, does not work.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vadim Shatalov, 2020-02-06
@dimuska139

https://djangopackages.org/grids/g/static-builders/

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question