Razzle: Question around performance on build times.

Created on 18 Jun 2020  ·  4Comments  ·  Source: jaredpalmer/razzle

❓Question

Hey there,

My team has been using Razzle for the past couple of months. We recently have been running into some major pains with build times sometimes taking up to 20 seconds to be able to debug the new code that we have pushed. A couple of unique things about our application.

  • Its Typescript
  • Its a monorepo ( yarn workspaces & Lerna )
  • We use barrel files
  • We currently only have one additional Webpack plugin circular-dependency-plugin
  • Its a large codebase

Versions

  • Razzle 3.1.0
  • Node 10.15
  • Typescript 3.7.4

Wondering if anyone has some experience with getting build times down in Razzle? The teams are functioning right now, but its starting to become an issue and we would love to hear from the Razzle community if there is something that we can do to help reduce our build times.

Any feedback welcomed.

Most helpful comment

Razzle 3.2 will have builtin typescript support.

You could look into using thread-loader in babel to compile in paralell.

All 4 comments

Razzle 3.2 will have builtin typescript support.

You could look into using thread-loader in babel to compile in paralell.

Next.js does this with thread-loader and cache-loader. We should have this in razzle too.

@fivethreeo thanks for your recommendations, those are some great recommendation. I think we will look into the thread loader that looks promising. I did not know that existed.

We were able to get some gains from removing the circular dependency plugin on development. I think the team is happy with the change and love the recs. Closing this ticket.

Great! If you find a good solution to this please update us :)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

howardya picture howardya  ·  5Comments

GouthamKD picture GouthamKD  ·  3Comments

mhuggins picture mhuggins  ·  3Comments

Ronny25 picture Ronny25  ·  5Comments

corydeppen picture corydeppen  ·  3Comments