Skip to content

fix(source-react-runtime): handle React types in props without skippi…#112

Merged
zdunecki merged 3 commits into
masterfrom
feat/xyd-source-react-runtime
Apr 26, 2026
Merged

fix(source-react-runtime): handle React types in props without skippi…#112
zdunecki merged 3 commits into
masterfrom
feat/xyd-source-react-runtime

Conversation

@zdunecki

Copy link
Copy Markdown
Member

…ng components

When a component's props contain types typia can't resolve (React.ReactNode, React.ReactElement, etc.), fall back to the TS type checker to extract prop schemas instead of skipping the component entirely. This ensures all components get __xydUniform metadata — React-typed props show their actual type name (e.g. "ReactNode") instead of being lost.

  • Add per-component retry with TS type checker fallback
  • Add fallbackExtractSchema and tsTypeToJsonSchema helpers
  • Fix boolean detection (TS represents boolean as true|false union)
  • Add -2.vite-lib.react-types-resilience test fixture

…ng components

When a component's props contain types typia can't resolve (React.ReactNode,
React.ReactElement, etc.), fall back to the TS type checker to extract prop
schemas instead of skipping the component entirely. This ensures all components
get __xydUniform metadata — React-typed props show their actual type name
(e.g. "ReactNode") instead of being lost.

- Add per-component retry with TS type checker fallback
- Add fallbackExtractSchema and tsTypeToJsonSchema helpers
- Fix boolean detection (TS represents boolean as true|false union)
- Add -2.vite-lib.react-types-resilience test fixture
@netlify

netlify Bot commented Apr 26, 2026

Copy link
Copy Markdown

Deploy Preview for xyd-storybook ready!

Name Link
🔨 Latest commit 1f3977e
🔍 Latest deploy log https://app.netlify.com/projects/xyd-storybook/deploys/69ee3f49cab7ea00084c373c
😎 Deploy Preview https://deploy-preview-112--xyd-storybook.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

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

@netlify

netlify Bot commented Apr 26, 2026

Copy link
Copy Markdown

Deploy Preview for xyd-website canceled.

Name Link
🔨 Latest commit 1f3977e
🔍 Latest deploy log https://app.netlify.com/projects/xyd-website/deploys/69ee3f49f11dd90008204b37

@netlify

netlify Bot commented Apr 26, 2026

Copy link
Copy Markdown

Deploy Preview for xyd-apidocs-demo ready!

Name Link
🔨 Latest commit 1f3977e
🔍 Latest deploy log https://app.netlify.com/projects/xyd-apidocs-demo/deploys/69ee3f49f3d6bc000813ca22
😎 Deploy Preview https://deploy-preview-112--xyd-apidocs-demo.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

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

Adds -3.vite-app.iframe-multi-entry test: a Vite app with two HTML entries
where the main app loads an iframe pointing to a separate React app entry.
Verifies __xydUniform is injected across both entries, including components
with React types in props (UserCard with ReactElement/ReactNode) via the
type checker fallback.
@zdunecki zdunecki merged commit 2dd267c into master Apr 26, 2026
5 checks passed
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.

1 participant