'what is the difference between entrtpoints and route based splitting

In a single page react app, there are multiple pages. Now I can make different chunk for each pages in two ways -

  1. Route based code splitting
  2. Multiple entry points for each pages in webpack config

Are there any differences between these two approaches? in terms of result? What should be the preferred one?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source