D
D
Dmitry Gusev2015-09-23 17:05:46
Node.js
Dmitry Gusev, 2015-09-23 17:05:46

Jade renderFile run in parallel with async.parallel?

Hello!
Task: you need to render 5-10 .jade files, and pass the resulting html in the callback.
Consistently rendering takes a lot of time.
I tried to drive all renders in async.parallel, but nothing changed. The files are also re-rendered sequentially.
Actually the question is:
Who faced this, and how to parallelize the rendering of templates?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
I
Igor Makarov, 2015-09-23
@illi

Greetings.
That's right, it won't be faster. JS is asynchronous but not multi-threaded. Use child_process . Give child processes tasks.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question