Update dependencies, build, and testing for Ink.

Review Request #14645 — Created Oct. 20, 2025 and updated

Information

Ink
master

Reviewers

This change accomplishes several tasks towards unifying our JavaScript
build infrastructure and supported more modern node.js environments:

  • Replace many specific dependencies with a new dependency on
    @beanbag/js-buildkit.
  • Eliminate unused or obsolete dependencies.
  • Base tsconfig.json on our shared config.
  • Copy our customized @types/backbone into this source tree, rather
    than referencing it from node_modules. I'm working on upstreaming
    these changes so we don't have to ship our own at all.
  • Ship types as both index.d.ts and index.d.mts.
  • Update to Storybook 10.
  • Update to ESLint 9.

This includes a few changes specifically related to Storybook:

  • We no longer need to manually inject axe-playwright into the page,
    since the a11y tests are now handled automatically.
  • Fixed the text-color assignment in theme.css, since there's actually
    nothing called --ink-p-text-color.
  • Pinned the version of @types/react because @types/mdx uses older
    names for things even when @mdx/react seems fine.

Plus a few changes relating to fixing unit tests:

  • Use @babel/register for transpiling during jasmine testing rather
    than ts-node. It seems like the ts-node one was broken on modern
    node environments, and using babel instead keeps our unit tests
    running in a much closer mode to how the code is built for packaging.
    This required some massaging of our babel configuration to allow
    slightly different plugin configurations between dev and test.
  • Import MenuItemsRadioGroup as type MenuItemsRadioGroup in
    menuItemModel.ts in order to prevent a circular dependency.
  • Use this.constructor for static member access inside MenuView, so
    unit tests and the class itself aren't looking at different versions
    of static members.
  • Did a build.
  • Ran unit tests.
  • Ran storybook.
  • Used this is a workspace with other packages that depend on it.
Summary ID
Update dependencies, build, and testing for Ink.
This change accomplishes several tasks towards unifying our JavaScript build infrastructure and supported more modern node.js environments: * Replace many specific dependencies with a new dependency on `@beanbag/js-buildkit`. * Eliminate unused or obsolete dependencies. * Base `tsconfig.json` on our shared config. * Copy our customized `@types/backbone` into this source tree, rather than referencing it from `node_modules`. I'm working on upstreaming these changes so we don't have to ship our own at all. * Ship types as both `index.d.ts` and `index.d.mts`. * Update to Storybook 10. * Update to ESLint 9. This includes a few changes specifically related to Storybook: * We no longer need to manually inject axe-playwright into the page, since the a11y tests are now handled automatically. * Fixed the text-color assignment in theme.css, since there's actually nothing called `--ink-p-text-color`. * Pinned the version of `@types/react` because `@types/mdx` uses older names for things even when `@mdx/react` seems fine. Plus a few changes relating to fixing unit tests: * Use `@babel/register` for transpiling during jasmine testing rather than `ts-node`. It seems like the `ts-node` one was broken on modern node environments, and using babel instead keeps our unit tests running in a much closer mode to how the code is built for packaging. This required some massaging of our babel configuration to allow slightly different plugin configurations between dev and test. * Import `MenuItemsRadioGroup` as `type MenuItemsRadioGroup` in menuItemModel.ts in order to prevent a circular dependency. * Use `this.constructor` for static member access inside `MenuView`, so unit tests and the class itself aren't looking at different versions of static members. Testing Done: - Did a build. - Ran unit tests. - Ran storybook. - Used this is a workspace with other packages that depend on it.
trtpqsmzywpuxzwoulstvmtyvnkkrwqz
Description From Last Updated

This was intentionally set to help ensure tests weren't conflicting with each other in unexpected ways.

chipx86chipx86
david
david
maubin
  1. Ship It!
  2. 
      
david
chipx86
  1. This change does a whole lot of unrelated things (e.g., the menu/constructor fixes aren't related to the type fixes, the unit test fixes, etc). It's pretty hard to review correctly.

    The main thing I want to be 100% sure of is that a build from before and after this change effectively looks the same. Some TypeScript options were removed, presumably due to newer defaults, but I don't want any surprises.

    1. The tsconfig options that were removed are now in the common tsconfig that this inherits from.

  2. spec/support/jasmine.json (Diff revision 4)
     
     
    Show all issues

    This was intentionally set to help ensure tests weren't conflicting with each other in unexpected ways.

  3. 
      
david
Review request changed
Commits:
Summary ID
Update dependencies, build, and testing for Ink.
This change accomplishes several tasks towards unifying our JavaScript build infrastructure and supported more modern node.js environments: * Replace many specific dependencies with a new dependency on `@beanbag/js-buildkit`. * Eliminate unused or obsolete dependencies. * Base `tsconfig.json` on our shared config. * Copy our customized `@types/backbone` into this source tree, rather than referencing it from `node_modules`. I'm working on upstreaming these changes so we don't have to ship our own at all. * Ship types as both `index.d.ts` and `index.d.mts`. * Update to Storybook 10. * Update to ESLint 9. This includes a few changes specifically related to Storybook: * We no longer need to manually inject axe-playwright into the page, since the a11y tests are now handled automatically. * Fixed the text-color assignment in theme.css, since there's actually nothing called `--ink-p-text-color`. * Pinned the version of `@types/react` because `@types/mdx` uses older names for things even when `@mdx/react` seems fine. Plus a few changes relating to fixing unit tests: * Use `@babel/register` for transpiling during jasmine testing rather than `ts-node`. It seems like the `ts-node` one was broken on modern node environments, and using babel instead keeps our unit tests running in a much closer mode to how the code is built for packaging. This required some massaging of our babel configuration to allow slightly different plugin configurations between dev and test. * Import `MenuItemsRadioGroup` as `type MenuItemsRadioGroup` in menuItemModel.ts in order to prevent a circular dependency. * Use `this.constructor` for static member access inside `MenuView`, so unit tests and the class itself aren't looking at different versions of static members. Testing Done: - Did a build. - Ran unit tests. - Ran storybook. - Used this is a workspace with other packages that depend on it.
trtpqsmzywpuxzwoulstvmtyvnkkrwqz
Update dependencies, build, and testing for Ink.
This change accomplishes several tasks towards unifying our JavaScript build infrastructure and supported more modern node.js environments: * Replace many specific dependencies with a new dependency on `@beanbag/js-buildkit`. * Eliminate unused or obsolete dependencies. * Base `tsconfig.json` on our shared config. * Copy our customized `@types/backbone` into this source tree, rather than referencing it from `node_modules`. I'm working on upstreaming these changes so we don't have to ship our own at all. * Ship types as both `index.d.ts` and `index.d.mts`. * Update to Storybook 10. * Update to ESLint 9. This includes a few changes specifically related to Storybook: * We no longer need to manually inject axe-playwright into the page, since the a11y tests are now handled automatically. * Fixed the text-color assignment in theme.css, since there's actually nothing called `--ink-p-text-color`. * Pinned the version of `@types/react` because `@types/mdx` uses older names for things even when `@mdx/react` seems fine. Plus a few changes relating to fixing unit tests: * Use `@babel/register` for transpiling during jasmine testing rather than `ts-node`. It seems like the `ts-node` one was broken on modern node environments, and using babel instead keeps our unit tests running in a much closer mode to how the code is built for packaging. This required some massaging of our babel configuration to allow slightly different plugin configurations between dev and test. * Import `MenuItemsRadioGroup` as `type MenuItemsRadioGroup` in menuItemModel.ts in order to prevent a circular dependency. * Use `this.constructor` for static member access inside `MenuView`, so unit tests and the class itself aren't looking at different versions of static members. Testing Done: - Did a build. - Ran unit tests. - Ran storybook. - Used this is a workspace with other packages that depend on it.
trtpqsmzywpuxzwoulstvmtyvnkkrwqz

Checks run (2 succeeded)

flake8 passed.
JSHint passed.