Skip to content

Conversation

djhi
Copy link
Collaborator

@djhi djhi commented Aug 28, 2025

Problem

There are still hooks and components that could be in ra-core but are in ra-ui-materialui. We had to duplicate them in shadcn-admin-kit

Solution

  • move them to ra-core

How To Test

  • All tests should still pass

Additional Checks

  • The PR targets master for a bugfix or a documentation fix, or next for a feature
    - [ ] The PR includes unit tests (if not possible, describe why) no real logic
    - [ ] The PR includes one or several stories (if not possible, describe why) just contexts and consuming hooks

@djhi djhi added the WIP Work In Progress label Aug 28, 2025
@djhi djhi changed the title Ra core primitives Move more primitives from ra-ui-materialui to ra-core Aug 28, 2025
* @deprecated Import from `ra-core` or `react-admin` instead
*/
export { ArrayInputContext, useArrayInput } from 'ra-core';
export {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

all ra-core is already re-exported by react-admin, aren't these hooks going to be exported twice?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's what we did in #10873. Should I revert it too? I think you're right but strangely enough, TS didn't complain at build time

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

However, not re-exporting from ra-ui-materialui would be a breaking change for people importing from it instead of react-admin

@djhi djhi added RFR Ready For Review WIP Work In Progress and removed WIP Work In Progress RFR Ready For Review labels Aug 29, 2025
@slax57 slax57 self-requested a review September 1, 2025 08:19
@djhi djhi added RFR Ready For Review and removed WIP Work In Progress labels Sep 1, 2025
@slax57 slax57 merged commit 31204a0 into next Sep 1, 2025
15 checks passed
@slax57 slax57 deleted the ra-core-primitives branch September 1, 2025 08:29
@slax57 slax57 added this to the 5.11.0 milestone Sep 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
RFR Ready For Review
Development

Successfully merging this pull request may close these issues.

3 participants