solid-start icon indicating copy to clipboard operation
solid-start copied to clipboard

[Feature?]: Provide a way to disable code splitting

Open par5er opened this issue 1 year ago • 3 comments

Duplicates

  • [X] I have searched the existing issues

Latest version

  • [X] I have tested the latest version

Summary 💡

An option in app.config.ts to disable code splitting. Only a single JS file would be emitted in this case instead of splitting on route.

Examples 🌈

No response

Motivation 🔦

I am mangling property names with terser but because every page has its own bundle, the property names are not consistent between chunks causing breakage

par5er avatar Dec 21 '24 12:12 par5er

possible duplicate of #1575

huseeiin avatar Dec 21 '24 14:12 huseeiin

thanks for that @huseeiin . I agree there's a scenario where disabling lazy routes can be the same as serving a single-bundle. But perhaps not necessarily. I see some usage/situations where not lazy-loading routes (or some routes) may not lead to everything in the same bundle.

but, @par5er we're currently revisiting our bundling architecture, so I'll put a hold on this one, I'm hoping in the future our configuration can be extensible enough that, perhaps, what you want can be entirely achieved in user-land.

atilafassina avatar Feb 13 '25 17:02 atilafassina

thanks for that @huseeiin . I agree there's a scenario where disabling lazy routes can be the same as serving a single-bundle. But perhaps not necessarily. I see some usage/situations where not lazy-loading routes (or some routes) may not lead to everything in the same bundle.

but, @par5er we're currently revisiting our bundling architecture, so I'll put a hold on this one, I'm hoping in the future our configuration can be extensible enough that, perhaps, what you want can be entirely achieved in user-land.

ideally you'd choose whether to lazily or eagerly load each route

huseeiin avatar Feb 13 '25 18:02 huseeiin