Index of every page on this site: llms.txt
All skills
software-mansion-labs avatar

/enable-worklets-bundle-mode

@43cde80
Run it yourself

Enable react-native-worklets Bundle Mode (imports inside worklets, third party libraries on worklet runtimes) in an Expo, RN CLI or brownfield React Native app, including the mandatory metro/metro-runtime patches. Use when the user asks to enable Bundle Mode, wants to import npm libraries inside worklets or offload JS code to worklet runtimes, or hits "Failed to get the SHA-1" errors in a worklets Bundle Mode project / missing Fast Refresh for worklet code. Covers enabling only — not disabling; upgrades react-native-worklets to a compatible version when needed, but never installs it from scratch and never touches Reanimated.

Use this Skill: https://skilld.dev/gh/software-mansion-labs/skills/enable-worklets-bundle-mode

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

referencespatching-pnpm.md

≈507 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Bundle Mode metro patches — pnpm

Applies the metro + metro-runtime Bundle Mode patches with pnpm's native patching (https://pnpm.io/cli/patch). Uses the patch-package-format patch files.

NOT upstream-verified: the worklets repo ships no pnpm instructions (its patches README asks for contributions). This flow follows pnpm's documented mechanism; the patch -p3 re-targeting is needed because the patch-package-format files carry node_modules/{pkg}/-prefixed paths while pnpm patch dirs are package-relative (-p3 strips a/node_modules/{pkg}/), and that re-targeting has been validated locally against the 0.84.4 metro patch. Treat the verification greps in step 4 of the skill as mandatory.

BASE=https://raw.githubusercontent.com/software-mansion/react-native-reanimated/main/packages/react-native-worklets/bundleMode/patches

Find your installed versions (pnpm why metro, pnpm why metro-runtime), then for each package (substitute the version; %2B is the URL-encoded + in the filename; the --edit-dir must not exist beforehand):

rm -rf .claude/tmp/metro-patch
pnpm patch metro@0.84.4 --edit-dir=.claude/tmp/metro-patch
curl -fsSL "$BASE/patch-package/metro/metro%2B0.84.4.patch" | patch -p3 -d .claude/tmp/metro-patch
pnpm patch-commit .claude/tmp/metro-patch
rm -rf .claude/tmp/metro-runtime-patch
pnpm patch metro-runtime@0.84.4 --edit-dir=.claude/tmp/metro-runtime-patch
curl -fsSL "$BASE/patch-package/metro-runtime/metro-runtime%2B0.84.4.patch" | patch -p3 -d .claude/tmp/metro-runtime-patch
pnpm patch-commit .claude/tmp/metro-runtime-patch

pnpm patch-commit writes a package-relative patch under patches/ and registers it in pnpm.patchedDependencies in package.json, so it re-applies on every install. Do NOT point patchedDependencies at the downloaded patch-package-format files directly — their node_modules/{pkg}/ path prefixes don't match pnpm's package-relative patch format. Clean up the --edit-dir temp directories afterwards.

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No alerts2mo3 checks · Risk SAFE
  • Gen Agent Trust Hub2mo

    This skill enables Bundle Mode for react-native-worklets by updating Babel and Metro configurations and applying official patches to the Metro bundler. It fetches these patches from the official software-mansion GitHub repository and applies them using standard package management tools.

  • Socket2mo

    No alerts

  • Snyk2mo

    Risk: LOW · No issues

Signed by skilld at 43cde80. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 2 weeks ago.

Activeupdated 4 months ago
metadata
{
  "author": "Tomasz Żelawski",
  "version": "1.0.0"
}
Other metadata
compatibility
Requires network access to raw.githubusercontent.com and api.github.com to fetch metro patches

README badge

README badge for software-mansion-labs/skills/enable-worklets-bundle-mode