Skip to content

chore(deps): bump @juspay/rescript-bindgen to ^1.4.0-beta.1 + regenerate - #142

Merged
jagguji merged 1 commit into
mainfrom
chore/bindgen-1.4.0-beta.1
Aug 12, 2026
Merged

chore(deps): bump @juspay/rescript-bindgen to ^1.4.0-beta.1 + regenerate#142
jagguji merged 1 commit into
mainfrom
chore/bindgen-1.4.0-beta.1

Conversation

@jagguji

@jagguji jagguji commented Aug 12, 2026

Copy link
Copy Markdown
Collaborator

Bumps @juspay/rescript-bindgen ^1.4.0-beta.0^1.4.0-beta.1 and regenerates.

Regenerated against the current pin @juspay/blend-design-system@0.0.37, so this diff is the bindgen delta alone — no blend changes mixed in. #141 (blend 0.0.38-beta.0) can rebase on this and show a clean blend-only diff.

Is this an improvement?

Yes, and measurably. beta.1 is eight correctness fixes, no new surface. Two close defects this repo has already been bitten by:

Fix Why it matters here
#171 constructor-name collisions put the wrong string on the wire ReScript scopes variant constructors per module, so two enums in one *Types.res could both define Value; where the expected type isn't known ReScript silently binds the last one. In blend this hit HighchartsSharedTypes.Point"point" vs "Point", which Highcharts treats as case-sensitive — and broke the portal dashboard migration (#133).
#170 self-referential discriminated unions crashed extraction Affected components vanished from the output with no report entry. This was flagged as a known issue when #139 landed beta.0 — fixed here.

Plus #175 (void/undefinedunit, not a dead string), #186 (views modules were write-only for some arms — 95 readers added), #181, #177, and entry-lifecycle #179/#180/#182.

Verification

  • Buckets unchanged — 226 components · ✅ 219 usable · 🔍 7 review · 🛑 0 broken. Same 7 components in review. 3356 → 3365 shared types.
  • All 305 modules compile; rescript format -c clean.
  • Typing strictly improves — 362 ⚪ loose fields removed, 0 added:
    • 330 were TS undefined, 18 were void — both emitted as a dead string, now unit. Anything passed there never reached the library.
    • 10 were ColumnDefinition<T> degraded to 'a, now the real columnDefinition_t (#177 — two instantiations of one generic are two types, rather than one record lying about both).
    • 3 single string literals became polyvars ([#flex], [#center], [#auto]).
    • ⚠️ REVIEW placeholders unchanged at 93.
  • Runtime wire format provably unchanged — the multiset of @as("…") literals across src/ is byte-identical before and after, except @as("type") 225 → 235, which is exactly the 10 new per-arm ColumnDefinition records. No emitted string moved.

Breaking — at ReScript call sites only, never at runtime

  1. Renamed collision constructors. HighchartsSharedTypes: SolidSolidStyleValue/SolidShapeValue, PointPointConstructorType/PointObjectScope/PointPointArray, Pointer, Polygon, Series, TriangleDown, Value. DataTableTypes: DateRangeDateRangeColumnType/DateRangeTypeType/DateRangeFilterComponent. EditorSharedTypes: 12 groups. Full list in src/_REPORT.md under 🔤.
  2. Content-hashed shared type names churn where content changed — 14 retired, 51 added. The hash follows the content by design.
  3. Props that were a dead string are now unit or a polyvar, so a call site passing a string there becomes a compile error. That code was already broken; this turns a silent runtime no-op into a loud one.

145 same-value collisions are reported but deliberately not renamed — they resolve to the same runtime shape either way, so renaming would churn consumers for no correctness gain. New 🔤 section in src/_REPORT.md lists them.

Reviewer checklist

  • npm run build green (CI blocks otherwise)
  • src/_REPORT.md — 0 broken; skim the new 🔤 collision section
  • Renamed constructors above are the ones downstream code is most likely to reference

Version intentionally left at 0.0.37-1 — matching #139, where the bindgen bump carried no version change and the release commit handled it separately.

🤖 Generated with Claude Code

1.4.0-beta.1 is eight correctness fixes on top of beta.0. Two of them close
defects this repo has already been bitten by:

  - #171 constructor-name collisions put the WRONG string on the wire. ReScript
    scopes variant constructors per module, so two enums in one *Types.res could
    both define `Value`; where the expected type isn't known ReScript silently
    binds the last definition. In blend this hit HighchartsSharedTypes.Point
    ("point" vs "Point" — Highcharts treats these as case-sensitive) and broke
    the portal dashboard migration (#133). 16 collision groups are now renamed by
    their owning type; 145 same-value collisions are reported, not renamed.
  - #170 self-referential discriminated unions crashed extraction and the
    affected components vanished from the output with no report entry. This was
    called out as a known issue when #139 landed beta.0; it is fixed here.

Also #175 (void/undefined leaves map to unit, not a dead string), #186 (views
modules were write-only for some arms — 95 readers added), #181, #177, and the
entry-lifecycle fixes #179/#180/#182.

Regenerated against the current pin, @juspay/blend-design-system@0.0.37, so this
diff is the bindgen delta alone with no blend changes mixed in.

Buckets unchanged: 226 components, 219 usable, 7 review, 0 broken. Same 7
components in review as before. 3356 -> 3365 shared types. All 305 modules
compile; rescript format -c is clean.

Typing strictly improves — 362 `⚪ loose` fields removed, 0 added:
  - 330 were TS `undefined` and 18 were `void`, both emitted as a dead `string`;
    they are now `unit`. Anything passed there never reached the library.
  - 10 were `ColumnDefinition<T>` degraded to `'a`, now the real
    `columnDefinition_t` (#177 — two instantiations of one generic are two
    types, instead of one record that lied about both).
  - 3 single string literals became polyvars (`[#flex]`, `[#center]`, `[#auto]`).
`⚠️ REVIEW` placeholders unchanged at 93.

Runtime wire format is provably unchanged: the multiset of `@as("...")` literals
across src/ is byte-identical before and after, except `@as("type")` 225 -> 235,
which is the 10 new per-arm ColumnDefinition records. No emitted string moved.

BREAKING at ReScript call sites only, never at runtime:
  - Renamed collision constructors, e.g. HighchartsSharedTypes `Solid` ->
    `SolidStyleValue`/`SolidShapeValue`, `Point` -> `PointConstructorType`/
    `PointObjectScope`/`PointPointArray`, DataTableTypes `DateRange` ->
    `DateRangeColumnType`/`DateRangeTypeType`/`DateRangeFilterComponent`.
  - Content-hashed shared type names churn where content changed (14 names
    retired, 51 added) — the hash follows the content by design.
  - Props that were a dead `string` are now `unit` or a polyvar, so a call site
    passing a string there becomes a compile error. That code was already
    broken; this converts a silent runtime no-op into a loud one.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@jagguji
jagguji merged commit 91de1a3 into main Aug 12, 2026
6 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