Hi, thanks for publishing react-native-streamdown.
I think the setup docs could use a small Expo-specific section. The current examples are easy to follow, but they are written from a React Native Community app perspective, while Expo projects usually need slightly different setup for both Metro and Babel.
For Expo apps:
- Metro usually starts from
expo/metro-config, not @react-native/metro-config
react-native-worklets already exposes an Expo-specific helper for Bundle Mode via getBundleModeMetroConfig(config)
- Expo apps often do not start with a
babel.config.js, but once one is added for the Worklets plugin, it still needs to preserve Expo’s default preset:
module.exports = function (api) {
api.cache(true);
return {
presets: ["babel-preset-expo"],
plugins: [
[
"react-native-worklets/plugin",
{
bundleMode: true,
workletizableModules: ["remend"],
},
],
],
};
};
And for Metro, an Expo example would look more like:
const { getDefaultConfig } = require("expo/metro-config");
const { getBundleModeMetroConfig } = require("react-native-worklets/bundleMode");
let config = getDefaultConfig(__dirname);
module.exports = getBundleModeMetroConfig(config);
In monorepos, people may still need to add the .worklets watch folder, but this gets the setup much closer to the correct Expo shape.
That would make first-time setup smoother for Expo users without changing the main docs much.
Hi, thanks for publishing
react-native-streamdown.I think the setup docs could use a small Expo-specific section. The current examples are easy to follow, but they are written from a React Native Community app perspective, while Expo projects usually need slightly different setup for both Metro and Babel.
For Expo apps:
expo/metro-config, not@react-native/metro-configreact-native-workletsalready exposes an Expo-specific helper for Bundle Mode viagetBundleModeMetroConfig(config)babel.config.js, but once one is added for the Worklets plugin, it still needs to preserve Expo’s default preset:And for Metro, an Expo example would look more like:
In monorepos, people may still need to add the
.workletswatch folder, but this gets the setup much closer to the correct Expo shape.That would make first-time setup smoother for Expo users without changing the main docs much.