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

Seems to be incompatible with mdx-deck 2.0 #53

Closed
emirotin opened this issue Mar 18, 2019 · 13 comments · May be fixed by #54
Closed

Seems to be incompatible with mdx-deck 2.0 #53

emirotin opened this issue Mar 18, 2019 · 13 comments · May be fixed by #54

Comments

@emirotin
Copy link

First, a peer dep of styled-components is required for it to work and it's not mentioned in the readme

Second, it fails with withDeck not being a function

@emirotin
Copy link
Author

WRT the first one mdx-deck has switched to emotion and is now using emotion-theming.
For the 2nd the changes seem to be too major and I'm unfamiliar with the code base of both projects so I wasn't able to spot the proper change but there are withContext HOC and useDeck hook now exported from mdx-deck that are probably the way to go.

@mbilokonsky
Copy link

Just hit this too, which is a bummer because this was going to be a perfect tool for the deck I'm building!

@pomber
Copy link
Owner

pomber commented Mar 21, 2019

I'm planning to do a big refactor (and add more features), but I'm currently busy with other things. So the ETA is end of April.

@mbilokonsky
Copy link

awesome, thanks!

@emirotin
Copy link
Author

@mbilokonsky use mdx-deck ^1.10.0 it works nice, the docs are here https://github.com/jxnblk/mdx-deck/tree/v1.10.2/docs

@madrus
Copy link

madrus commented Apr 21, 2019

1.10.0
Works with inline code but not with code snippets like code={require("!raw-loader!./my-snippet.js")}. code parameter expects a string and not an object (error message).

@w1zd
Copy link

w1zd commented Apr 22, 2019

1.10.0
Works with inline code but not with code snippets like code={require("!raw-loader!./my-snippet.js")}. code parameter expects a string and not an object (error message).

Same issue as you.

@christopherjbaker
Copy link

@madrus @finish8 use code={require("!raw-loader!./my-snippet.js").default} instead

@madrus
Copy link

madrus commented Apr 26, 2019

@madrus @finish8 use code={require("!raw-loader!./my-snippet.js").default} instead

Wow! It works indeed. Thanks!

@w1zd
Copy link

w1zd commented Apr 29, 2019

@madrus @finish8 use code={require("!raw-loader!./my-snippet.js").default} instead

love you 😘

@aleclarson
Copy link

#54 works for me

@pomber
Copy link
Owner

pomber commented May 10, 2019

I'm planning to do a big refactor (and add more features), but I'm currently busy with other things. So the ETA is end of April.

Update: Now I have time to work on releasing a new version, so expect an alpha of code surfer v2 soon.

@pomber
Copy link
Owner

pomber commented Dec 10, 2019

Fixed in v3 (well, it isn't compatible with mdx-deck v2, but it's compatible with mdx-deck v3)

@pomber pomber closed this as completed Dec 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants