Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: export props for accordion #16284

Closed

Conversation

Gururajj77
Copy link
Contributor

Closes #16154

Created a Draft PR to get the export reviewed

Changelog

Changed

  • Exporting AccordionProps

Copy link

netlify bot commented Apr 30, 2024

Deploy Preview for v11-carbon-react ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 21bd396
🔍 Latest deploy log https://app.netlify.com/sites/v11-carbon-react/deploys/6630a996ebbdb20008105361
😎 Deploy Preview https://deploy-preview-16284--v11-carbon-react.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link
Member

@tay1orjones tay1orjones left a comment

Choose a reason for hiding this comment

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

We probably should be as explicit as possible with both the imports and exports.


Do you think we could batch all the other ones into one PR or would you prefer to do separate ones for each listed in #16154

Also see my note over there: #16154 (comment) - I think the expectation here for now is that we'll only be able to make these available through fully qualified import paths, e.g.

import { type AccordionProps } from "@carbon/react/es/components/Accordion";

Does that match what you've understood so far here working on this? Maybe I'm incorrect.

@@ -5,9 +5,10 @@
* LICENSE file in the root directory of this source tree.
*/

import Accordion from './Accordion';
import Accordion, { AccordionProps } from './Accordion';
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
import Accordion, { AccordionProps } from './Accordion';
import Accordion, { type AccordionProps } from './Accordion';

Comment on lines 11 to +12
export { Accordion };
export type { AccordionProps };
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
export { Accordion };
export type { AccordionProps };
export { Accordion, type AccordionProps };

@Gururajj77
Copy link
Contributor Author

This was a demo PR, actual PRs for the export are raised: #16447 and #16448

@Gururajj77 Gururajj77 closed this May 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: typescript role: dev 🤖 type: infrastructure 🤖 Issues relating to devops, tech debt, etc.
Projects
Status: ✅ Done
Status: Done
Development

Successfully merging this pull request may close these issues.

[Feature Request]: Export props for TypeScript components
2 participants