Skip to content

fix: final 1.x patch (React 18, types, require) with 2.0 deprecations - #84

Merged
akash-aman merged 4 commits into
mainfrom
fix/v1-final-patch
Oct 5, 2026
Merged

akash-aman merged 4 commits into
mainfrom
fix/v1-final-patch

Conversation

@akash-aman

Copy link
Copy Markdown
Collaborator

The final 1.x patch: fixes for bugs in the published packages, plus deprecation notes ahead of 2.0. Library behaviour doesn't change.

Fixes

  • React 18 works. The React bundle inlined React 19's react/jsx-runtime, so it couldn't render under React 18. react/* and react-dom/* are now external, and the peers are ^18.0.0 || ^19.0.0 (the react peer was ^0.0.1).
  • Types resolve. The React and Solid declarations imported ../../../core/src, a path that doesn't exist in the published package, so core types were any for users. Each package now ships one self-contained index.d.ts, plus index.d.cts for CommonJS.
  • require() works. The CommonJS builds were named *.cjs.js in "type": "module" packages, so Node loaded them as ESM. They're now *.cjs. Core's browser field, which pointed bundlers at an IIFE with no exports, is removed.
  • Installs on Node 18+. It required Node 22.16.
  • Solid: solid-js is a peer dependency, so apps don't get two copies.
  • Docs: the React README now imports the correct stylesheet, and all repository links point to xcode-studio/dynamix-layout.
  • Deprecations: every React prop and every core and React export that 2.0 renames or removes is marked @deprecated, naming its replacement and linking the migration guide.
    • Solid's props stay the same in 2.0, so only updateJSON (new payload) and the slider timeouts are annotated there.

Removed

  • The React package's IIFE/UMD builds. exports never exposed them, and with React's JSX runtime external they couldn't work.

Verified

  • Lint, build and all 3,732 tests pass.
  • publint and @arethetypeswrong/cli: no problems for core, react or solid. Before, React had masquerading CommonJS types and node16 resolution errors.
  • The packed packages render in a project with only React 18.3.1 installed.
  • require() loads the core and React CommonJS builds.

Release

The changeset bumps core to 1.1.1, and react and solid to 1.0.3. After merge, the release workflow opens the Version Packages PR.

This conflicts with the v2 branch in the package and build configs. v2 already contains these fixes, so its versions win when it's rebased.

- Externalize react/jsx-runtime and react-dom subpaths (the bundle
  inlined React 19's runtime) and set the React peers to ^18 || ^19.
- Name the CommonJS builds .cjs so require() loads them as CommonJS in
  these "type": "module" packages; drop core's browser field.
- Ship one rolled-up declaration file per package, importing
  @dynamix-layout/core as a package instead of ../../../core/src, plus
  index.d.cts for require.
- solid-js becomes a peer dependency of the Solid package, and the
  packages install on Node 18+.
Marks the props and exports that 2.0 renames or removes as @deprecated,
each naming its replacement and linking the migration guide, so editors
show what to change before upgrading. Solid's props stay in 2.0, so only
updateJSON (new payload) and the slider timeouts are annotated there.
@vercel

vercel Bot commented Oct 5, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
dynamix-layout-react Ready Ready Preview Oct 5, 2026 2:45am UTC

@akash-aman
akash-aman merged commit fcb1894 into main Oct 5, 2026
4 checks passed
@github-actions github-actions Bot mentioned this pull request Oct 5, 2026

This branch was successfully deployed

1 active deployment
Preview – dynamix-layout-react — a8295a79 Deployed Oct 5, 2026 by vercel[bot]
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