Skip to content

Add expo-serve-sim and withSimServe helper#5

Open
krystofwoldrich wants to merge 1 commit into
EvanBacon:mainfrom
krystofwoldrich:claude/metro-serve-sim-integration-TvFpX
Open

Add expo-serve-sim and withSimServe helper#5
krystofwoldrich wants to merge 1 commit into
EvanBacon:mainfrom
krystofwoldrich:claude/metro-serve-sim-integration-TvFpX

Conversation

@krystofwoldrich

Copy link
Copy Markdown
Contributor

Replaces the verbose enhanceMiddleware + connect snippet in the README with a one-liner: withSimServe(getDefaultConfig(__dirname)). The helper mutates the Metro config in place and composes with any existing server.enhanceMiddleware, falling through to Metro's middleware via next() so no connect dependency is needed.

Comment thread packages/serve-sim/build.ts Outdated

const metroResult = await Bun.build({
entrypoints: [resolve(root, "src/metro.ts")],
target: "bun",

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Probably should be node, there is related PR in #8

@EvanBacon

Copy link
Copy Markdown
Owner

Ideally this package would be agnostic to React Native and instead offer functional adapters for frameworks

@krystofwoldrich krystofwoldrich force-pushed the claude/metro-serve-sim-integration-TvFpX branch from f2d01e2 to 44257e2 Compare May 5, 2026 13:18
@krystofwoldrich

Copy link
Copy Markdown
Contributor Author

I see, what about having expo-server-sim?

@krystofwoldrich krystofwoldrich changed the title Add serve-sim/metro entry with withSimServe helper Add expo-serve-sim and withSimServe helper May 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants