Skip to content

feat(package): dual module support - #11933

Closed
kmcfaul wants to merge 8 commits into
patternfly:mainfrom
kmcfaul:dual-module-supp
Closed

feat(package): dual module support#11933
kmcfaul wants to merge 8 commits into
patternfly:mainfrom
kmcfaul:dual-module-supp

Conversation

@kmcfaul

@kmcfaul kmcfaul commented Jul 23, 2025

Copy link
Copy Markdown
Contributor

What: Closes #11686
Assisted-by: Cursor

First pass on dual module package.json.

react-icons, react-tokens, and react-styles are not currently included because of what we output to the dist & what our docs expects when consuming our repos. Need to investigate further to see if we can adjust without breaking.

@patternfly-build

patternfly-build commented Jul 23, 2025

Copy link
Copy Markdown
Collaborator

import { treeRow } from './utils';
import { mergeProps } from './base/merge-props';
import { IVisibility } from './utils/decorators/classNames';
import { Tooltip } from '@patternfly/react-core/dist/esm/components/Tooltip/Tooltip';

@kmcfaul kmcfaul Jul 28, 2025

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

This is worth pointing out and thinking about - with the new export format, it appears that directory level imports and file level imports cannot exist simultaneously and be resolved successfully (component wildcard patterns end up interfering with each other).

Currently, only directory imports are supported so file imports like the above Tooltip won't work and would need to be updated. There are several of these type of imports reported in our analytics. Still investigating if that can be updated to support both.

import QuestionCircleIcon from '@patternfly/react-icons/dist/esm/icons/question-circle-icon';
import EllipsisVIcon from '@patternfly/react-icons/dist/esm/icons/ellipsis-v-icon';
import imgAvatar from '@patternfly/react-core/src/components/assets/avatarImg.svg';
// import imgAvatar from '../components/assets/avatarImg.svg';

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Look at inlining this.

@jamestalton jamestalton left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM!

@kmcfaul

kmcfaul commented Sep 15, 2025

Copy link
Copy Markdown
Contributor Author

This will be on hold until a breaking change release, so will be closed for now.

@kmcfaul kmcfaul closed this Sep 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug - Package Publishing - Published Libraries should follow NPM dual module package standards

3 participants