Skip to content

feat(react-native): add style-guide.json and Stitch API reference - #65

Open
ademakdogan wants to merge 1 commit into
google-labs-code:mainfrom
ademakdogan:feat/react-native-extras
Open

feat(react-native): add style-guide.json and Stitch API reference#65
ademakdogan wants to merge 1 commit into
google-labs-code:mainfrom
ademakdogan:feat/react-native-extras

Conversation

@ademakdogan

Copy link
Copy Markdown

Follow-up to #47 (closed as a duplicate of #42). As suggested by @davideast in that thread, this adds the extra resources on top of the merged react-native skill rather than duplicating the core skill.

What this adds

  • resources/style-guide.json — starter design tokens (colors, spacing, typography, border radii) using React Native-friendly numeric units. Gives the skill a concrete target to sync extracted Stitch values into, instead of hardcoding styles. Brings react-native to parity with the sibling react-components skill, which already ships a style guide.
  • resources/stitch-api-reference.md — documents the get_screen metadata schema and React Native-specific mapping rules (density-independent sizing via useWindowDimensions/Dimensions, asset handling through mockData.ts, and mapping the HTML tailwind.config into the style guide / theme.ts rather than merging a web config).

SKILL.md wiring

Both resources are referenced from SKILL.md (the retrieval step points to the API reference; the color-extraction step points to the style guide) so they are part of the generation flow rather than orphaned files.

No changes to the core skill behavior, scripts, or existing resources.

… reference

Adds two follow-up resources to the react-native skill, complementing the
existing build skills:

- resources/style-guide.json: starter design tokens (colors, spacing,
  typography, border radii) using React Native-friendly numeric units, so
  extracted Stitch values map to a theme instead of hardcoded styles.
- resources/stitch-api-reference.md: documents the get_screen metadata
  schema and React Native-specific mapping rules (density-independent
  sizing, asset handling, theme extraction over Tailwind merging).

SKILL.md references both resources from the retrieval and color-extraction
steps so they are part of the generation flow.
@zachshallbetter

zachshallbetter commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Hey @ademakdogan! I think I can help you get this merged. The repo was recently-ish restructured to move all skills into the plugins/ directory, which is the cause of your layout conflicts.

To resolve the conflicts, you can run these steps on your branch:

  1. Rebase on the latest main:
    git fetch origin
    git rebase origin/main

  2. Move your added files to their new location in the plugins tree:
    git mv skills/react-native/resources/stitch-api-reference.md skills/react-native/resources/style-guide.json plugins/stitch-build/skills/react-native/resources/

  3. Apply your SKILL.md changes manually to the new skill path:
    plugins/stitch-build/skills/react-native/SKILL.md

  4. Remove the old SKILL.md and finalize the rebase:
    git rm skills/react-native/SKILL.md git add plugins/stitch-build/skills/react-native/ git rebase --continue

Once committed and pushed, this should clear the merge conflicts!

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