I remain unsatisfied with most Django setups, including my own, that try to incorporate a reasonable JavaScript build pipeline. The JS build is inevitably a separate build step and a local dev server for hot reloading. Sure, deployment is fairly straightforward: compile JS, then collectstatic. It's the development story that suffers for its complexity imo.

I paired Django with AlpineJS for webauthn.io and in general it's fine to make updates to. But I just crested 575 lines of AlpineJS in a single HTML component and it's left me with a sense of dread about ongoing maintainability as I gradually add "just one more feature".

I miss my components-based, TypeScript-checked dev flow when I work with Django. Maybe it's time to look to vanilla Web Components to break some of this up, but then that won't get me the static type checking of TypeScript.

Anyone got any stories of how they wire up at least a TypeScript JS codebase for light front end interactivity, while still leveraging Django views for SSR?

0

If you have a fediverse account, you can quote this note from your own instance. Search https://infosec.exchange/users/iamkale/statuses/115351962325304199 on your instance and quote it. (Note that quoting is not supported in Mastodon.)