Skip to content

feat(playground): add docs playground#4846

Merged
2heal1 merged 5 commits into
mainfrom
feat/doc-playground
Jun 26, 2026
Merged

feat(playground): add docs playground#4846
2heal1 merged 5 commits into
mainfrom
feat/doc-playground

Conversation

@2heal1

@2heal1 2heal1 commented Jun 26, 2026

Copy link
Copy Markdown
Member

Description

add mf playrgound

Related Issue

Types of changes

  • Docs change / refactoring / dependency upgrade
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

Checklist

  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • I have updated the documentation.

@changeset-bot

changeset-bot Bot commented Jun 26, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: dac432a

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@module-federation/playground Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@netlify

netlify Bot commented Jun 26, 2026

Copy link
Copy Markdown

Deploy Preview for module-federation-docs ready!

Name Link
🔨 Latest commit dac432a
🔍 Latest deploy log https://app.netlify.com/projects/module-federation-docs/deploys/6a3e237564cb2d00089e9bff
😎 Deploy Preview https://deploy-preview-4846--module-federation-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@pkg-pr-new

pkg-pr-new Bot commented Jun 26, 2026

Copy link
Copy Markdown

Open in StackBlitz

@module-federation/devtools

pnpm add https://pkg.pr.new/@module-federation/devtools@dac432a

@module-federation/cli

pnpm add https://pkg.pr.new/@module-federation/cli@dac432a

create-module-federation

pnpm add https://pkg.pr.new/create-module-federation@dac432a

@module-federation/dts-plugin

pnpm add https://pkg.pr.new/@module-federation/dts-plugin@dac432a

@module-federation/enhanced

pnpm add https://pkg.pr.new/@module-federation/enhanced@dac432a

@module-federation/error-codes

pnpm add https://pkg.pr.new/@module-federation/error-codes@dac432a

@module-federation/esbuild

pnpm add https://pkg.pr.new/@module-federation/esbuild@dac432a

@module-federation/managers

pnpm add https://pkg.pr.new/@module-federation/managers@dac432a

@module-federation/manifest

pnpm add https://pkg.pr.new/@module-federation/manifest@dac432a

@module-federation/metro

pnpm add https://pkg.pr.new/@module-federation/metro@dac432a

@module-federation/metro-plugin-rnc-cli

pnpm add https://pkg.pr.new/@module-federation/metro-plugin-rnc-cli@dac432a

@module-federation/metro-plugin-rnef

pnpm add https://pkg.pr.new/@module-federation/metro-plugin-rnef@dac432a

@module-federation/metro-plugin-rock

pnpm add https://pkg.pr.new/@module-federation/metro-plugin-rock@dac432a

@module-federation/modern-js

pnpm add https://pkg.pr.new/@module-federation/modern-js@dac432a

@module-federation/modern-js-v3

pnpm add https://pkg.pr.new/@module-federation/modern-js-v3@dac432a

@module-federation/native-federation-tests

pnpm add https://pkg.pr.new/@module-federation/native-federation-tests@dac432a

@module-federation/native-federation-typescript

pnpm add https://pkg.pr.new/@module-federation/native-federation-typescript@dac432a

@module-federation/nextjs-mf

pnpm add https://pkg.pr.new/@module-federation/nextjs-mf@dac432a

@module-federation/node

pnpm add https://pkg.pr.new/@module-federation/node@dac432a

@module-federation/observability-plugin

pnpm add https://pkg.pr.new/@module-federation/observability-plugin@dac432a

@module-federation/playground

pnpm add https://pkg.pr.new/@module-federation/playground@dac432a

@module-federation/retry-plugin

pnpm add https://pkg.pr.new/@module-federation/retry-plugin@dac432a

@module-federation/rsbuild-plugin

pnpm add https://pkg.pr.new/@module-federation/rsbuild-plugin@dac432a

@module-federation/rspack

pnpm add https://pkg.pr.new/@module-federation/rspack@dac432a

@module-federation/rspress-plugin

pnpm add https://pkg.pr.new/@module-federation/rspress-plugin@dac432a

@module-federation/runtime

pnpm add https://pkg.pr.new/@module-federation/runtime@dac432a

@module-federation/runtime-core

pnpm add https://pkg.pr.new/@module-federation/runtime-core@dac432a

@module-federation/runtime-tools

pnpm add https://pkg.pr.new/@module-federation/runtime-tools@dac432a

@module-federation/sdk

pnpm add https://pkg.pr.new/@module-federation/sdk@dac432a

@module-federation/storybook-addon

pnpm add https://pkg.pr.new/@module-federation/storybook-addon@dac432a

@module-federation/third-party-dts-extractor

pnpm add https://pkg.pr.new/@module-federation/third-party-dts-extractor@dac432a

@module-federation/treeshake-frontend

pnpm add https://pkg.pr.new/@module-federation/treeshake-frontend@dac432a

@module-federation/treeshake-server

pnpm add https://pkg.pr.new/@module-federation/treeshake-server@dac432a

@module-federation/typescript

pnpm add https://pkg.pr.new/@module-federation/typescript@dac432a

@module-federation/utilities

pnpm add https://pkg.pr.new/@module-federation/utilities@dac432a

@module-federation/webpack-bundler-runtime

pnpm add https://pkg.pr.new/@module-federation/webpack-bundler-runtime@dac432a

@module-federation/bridge-react

pnpm add https://pkg.pr.new/@module-federation/bridge-react@dac432a

@module-federation/bridge-react-webpack-plugin

pnpm add https://pkg.pr.new/@module-federation/bridge-react-webpack-plugin@dac432a

@module-federation/bridge-shared

pnpm add https://pkg.pr.new/@module-federation/bridge-shared@dac432a

@module-federation/bridge-vue3

pnpm add https://pkg.pr.new/@module-federation/bridge-vue3@dac432a

@module-federation/inject-external-runtime-core-plugin

pnpm add https://pkg.pr.new/@module-federation/inject-external-runtime-core-plugin@dac432a

commit: dac432a

@github-actions

github-actions Bot commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Bundle Size Report

11 package(s) changed, 31 unchanged.

Package dist + ESM entry

Package Total dist (raw) Delta ESM gzip Delta
@module-federation/cli 26.3 kB no change 786 B no change
@module-federation/core 39.1 kB no change 173 B no change
@module-federation/devtools 664.0 kB no change 4.0 kB no change
@module-federation/enhanced 810.0 kB no change 672 B no change
@module-federation/managers 69.8 kB no change 334 B no change
@module-federation/manifest 136.1 kB no change 182 B no change
@module-federation/metro-plugin-rnc-cli 0 B no change 314 B no change
@module-federation/node 193.4 kB no change 217 B no change
@module-federation/playground 28.81 MB +28.81 MB (+∞%) 50.9 kB +50.9 kB (+∞%)
@module-federation/storybook-addon 79.2 kB no change 100 B no change
@module-federation/utilities 110.6 kB no change 328 B no change

Bundle targets

Package Web bundle (gzip) Delta Node bundle (gzip) Delta
@module-federation/cli 2.3 kB -31 B (-1.3%) 2.3 kB -31 B (-1.3%)
@module-federation/core 1.1 kB -31 B (-2.8%) 1.0 kB -30 B (-2.8%)
@module-federation/devtools 30.2 kB -28 B (-0.1%) 30.2 kB -28 B (-0.1%)
@module-federation/enhanced 2.6 kB -44 B (-1.6%) 2.6 kB -44 B (-1.6%)
@module-federation/managers 2.4 kB -27 B (-1.1%) 2.4 kB -27 B (-1.1%)
@module-federation/manifest 6.1 kB -40 B (-0.6%) 6.1 kB -40 B (-0.6%)
@module-federation/metro-plugin-rnc-cli 411 B -26 B (-5.9%) 411 B -26 B (-5.9%)
@module-federation/node 9.2 kB -28 B (-0.3%) 9.2 kB -28 B (-0.3%)
@module-federation/playground 47.0 kB +47.0 kB (+∞%) 47.0 kB +47.0 kB (+∞%)
@module-federation/storybook-addon 1.9 kB -24 B (-1.2%) 1.7 kB -24 B (-1.3%)
@module-federation/utilities 2.6 kB -31 B (-1.2%) 2.6 kB -31 B (-1.2%)

Consumer scenarios

Scenario Web output (gzip) Delta Node output (gzip) Delta Gap (node-web) Delta
Enhanced remoteEntry 21.4 kB -12 B (-0.1%) 22.5 kB -7 B (-0.0%) +1.1 kB +5 B

Total dist (raw): 35.63 MB (+28.81 MB (+422.4%))
Total ESM gzip: 129.5 kB (+50.9 kB (+64.8%))
Total web bundle (gzip): 254.3 kB (+46.7 kB (+22.5%))
Total node bundle (gzip): 254.8 kB (+46.7 kB (+22.5%))
Tracked ./bundler entry gzip: 556 B (no change)
Tracked ./bundler web bundle (gzip): 4.8 kB (no change)
Tracked ./bundler node bundle (gzip): 4.8 kB (no change)

Bundle sizes are generated with rslib (Rspack). Package-root metrics preserve the historical report. Tracked subpath exports such as ./bundler are measured separately so ENV_TARGET-driven tree-shaking is visible. Bare imports are externalized to keep package-level sizes consistent, and assets are emitted as resources.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: d2764447fc

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +1966 to +1970
<iframe
key={currentRunId}
className={cx('vp-previewFrame')}
title="Sandbox Preview"
srcDoc={buildPreviewDocument(previewState, defaults)}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Sandbox the preview iframe before running remotes

When a user enters or shares a third-party manifest URL, the fetched remote entry and exposed module execute inside this srcDoc iframe. Because the iframe has no sandbox, the srcdoc document inherits the docs site's origin, so arbitrary remote code can access window.parent and same-origin DOM/storage/non-HttpOnly cookies rather than being confined to the preview. Please run the preview in an isolated sandbox/origin before allowing arbitrary manifests to execute.

Useful? React with 👍 / 👎.

@2heal1 2heal1 merged commit f8b9b32 into main Jun 26, 2026
27 checks passed
@2heal1 2heal1 deleted the feat/doc-playground branch June 26, 2026 07:13
@2heal1 2heal1 mentioned this pull request Jul 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant