Skip to content

feat: route uvdsl SharedWorker + dynamic chunks under /mashlib-chunks/#397

Open
m5x5 wants to merge 2 commits into
SolidOS:post-milestone3mfrom
m5x5:feat/uvdsl-worker-asset-routing
Open

feat: route uvdsl SharedWorker + dynamic chunks under /mashlib-chunks/#397
m5x5 wants to merge 2 commits into
SolidOS:post-milestone3mfrom
m5x5:feat/uvdsl-worker-asset-routing

Conversation

@m5x5
Copy link
Copy Markdown

@m5x5 m5x5 commented May 18, 2026

Summary

  • assetModuleFilename: 'mashlib-chunks/[hash][ext][query]' and chunkFilename: 'mashlib-chunks/[contenthash].js' route uvdsl's SharedWorker asset and solid-panes' dynamic-import chunks into a known subfolder of dist/.
  • Adds @uvdsl/solid-oidc-client-browser as a dependency so webpack can resolve the package that solid-logic externalizes.

Without the asset routing, the worker file lands at /<hash>.js (webpack default), where css-mashlib doesn't serve it.

Refs SolidOS/solid-logic#274

Coordinated PRs

  • SolidOS/solid-logic — auth library swap that introduces the SharedWorker
  • SolidOS/css-mashlib — folder StaticAssetEntry + ACL for the new subfolder

Should land together with the css-mashlib PR.

solid-logic's swap to @uvdsl/solid-oidc-client-browser brings in a
SharedWorker (RefreshWorker.js) for background token refresh. uvdsl
constructs the worker URL via \`new URL('./RefreshWorker.js',
import.meta.url)\`, which webpack handles as an asset module.

By default webpack emits the worker at \`/<hash>.js\` (root), where
CSS doesn't serve it. Setting \`assetModuleFilename\` and
\`chunkFilename\` routes both the worker asset and solid-panes'
dynamic-import chunks into \`/mashlib-chunks/\`, where css-mashlib's
matching StaticAssetEntry can serve them.

Refs SolidOS/solid-logic#274

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@m5x5 m5x5 changed the base branch from main to post-milestone3m May 18, 2026 19:03
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Routes webpack-emitted runtime assets (dynamic-import chunks and the new uvdsl SharedWorker script) into a predictable subfolder under dist/, aligning Mashlib’s build output with downstream static asset serving expectations (per the coordinated css-mashlib changes), and ensures webpack can resolve the new auth-related browser package.

Changes:

  • Configure webpack output.chunkFilename to emit dynamic-import chunks under dist/mashlib-chunks/.
  • Configure webpack output.assetModuleFilename to emit worker/asset-module outputs under dist/mashlib-chunks/.
  • Add @uvdsl/solid-oidc-client-browser as a runtime dependency (and lockfile update) so webpack can resolve it during bundling.

Reviewed changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated no comments.

File Description
webpack.config.mjs Routes chunk and asset-module outputs into mashlib-chunks/ under dist/ to match static serving constraints.
package.json Adds @uvdsl/solid-oidc-client-browser dependency needed for bundling/resolution.
package-lock.json Locks the newly added dependency and its transitive requirements.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: In review

Development

Successfully merging this pull request may close these issues.

3 participants