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

fix: types #877

Merged
merged 4 commits into from
May 17, 2024
Merged

fix: types #877

merged 4 commits into from
May 17, 2024

Conversation

kellyjosephprice
Copy link
Collaborator

@kellyjosephprice kellyjosephprice commented May 17, 2024

PR App

🧰 Changes

Fixes a bunch of types from the jsx-coercion PR.

🧬 QA & Testing

@kellyjosephprice kellyjosephprice changed the base branch from next to beta May 17, 2024 00:35
@kellyjosephprice kellyjosephprice marked this pull request as ready for review May 17, 2024 18:35
Copy link
Contributor

@jennspencer jennspencer left a comment

Choose a reason for hiding this comment

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

⌨️

(TIL there's no typewriter emoji???)

@kellyjosephprice
Copy link
Collaborator Author

⌨️

(TIL there's no typewriter emoji???)

https://www.unicode.org/pending/proposals.html

@kellyjosephprice kellyjosephprice merged commit c0a4d66 into beta May 17, 2024
10 of 11 checks passed
@kellyjosephprice kellyjosephprice deleted the fix/types branch May 17, 2024 20:29
Copy link
Member

Choose a reason for hiding this comment

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

looks like there's a type error on line 96 now?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

@@ -112,12 +112,12 @@ export const html = (text: string, opts = {}) => {
unimplemented('html export');
};

const astProcessor = (opts = {}) =>
const astProcessor = (opts: MdastOpts = { components: {} }) =>
Copy link
Member

Choose a reason for hiding this comment

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

Can components get more specific or is it just Record<string, string>?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I don't think so? It's a mapping of tag name to component body?

Copy link
Member

Choose a reason for hiding this comment

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

might want to narrow it to Record<string, string> because right now it'll allow Record<string, unknown>

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

How?

image

Copy link
Member

Choose a reason for hiding this comment

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

oh my bad. MdastOpts is where components is defined, I misread the = there as : and thought you were typing opts: { components: {} }

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Thought I was about to have my type system shattered.

Copy link
Member

Choose a reason for hiding this comment

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

nope im just a dumbass. carry on

processor/transform/readme-components.ts Show resolved Hide resolved
rafegoldberg pushed a commit that referenced this pull request May 17, 2024
## Version 6.75.0-beta.32

### ✨ New & Improved

* fix dynamic require ([2482231](2482231))
* jsx-coercion ([#876](#876)) ([b742c6c](b742c6c))

### 🛠 Fixes & Updates

* types ([#877](#877)) ([c0a4d66](c0a4d66))

<!--SKIP CI-->
@rafegoldberg
Copy link
Contributor

This PR was released!

🚀 Changes included in v6.75.0-beta.32

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.

4 participants