spectacle icon indicating copy to clipboard operation
spectacle copied to clipboard

Chore/spectacle mdx loader addition

Open paulmarsicloud opened this issue 1 year ago • 6 comments

Description

First pass and attempt at bringing in spectacle-mdx-loader into the monorepo. Took onboard @ryan-roemer's advice to remove all devDeps and scripts and focus on getting lint and prettier working as a start. Moved prop-types and spectacle-mdx-loader into top-level package.json so that spectacle-mdx-loader could be called directly from examples/mdx/webpack.config.js.

In a good spot now for a second pair of eyes to take a look through 👍

Fixes #1164

Type of Change

  • [x] New feature (non-breaking change which adds functionality)
  • [ ] This change requires a documentation update

How Has This Been Tested?

Checklist: (Feel free to delete this section upon completion)

  • [ ] I have included a changeset if this change will require a version change to one of the packages.
  • [x] I have performed a self-review of my own code
  • [ ] I have commented my code, particularly in hard-to-understand areas
  • [ ] I have made corresponding changes to the documentation
  • [x] I have run pnpm run check:ci and all checks pass
  • [ ] I have added tests that prove my fix is effective or that my feature works
  • [x] My changes generate no new warnings
  • [ ] Any dependent changes have been merged and published in downstream modules

paulmarsicloud avatar Sep 20 '22 01:09 paulmarsicloud

@paulmarsicloud I've finished my cleanup of examples configs and dependencies. Mind double checking my commits?

@carlos-kelly @gksander @fritz-c I've noticed a discrepancy in code blocks in MD vs. MDX.

For our MD example with pnpm start:md for the code page we have:

Screen Shot 2022-09-21 at 1 50 03 PM

For our MDX example with pnpm start:mdx for the code page with exact same sample we have:

Screen Shot 2022-09-21 at 1 50 08 PM

Any ideas here? Thanks!

ryan-roemer avatar Sep 21 '22 20:09 ryan-roemer

Offhand, now that I'm looking at things looks like our Markdown component does a lot more than mdxComponentMap does alone -- and we recommend in our guide to just use the mdxComponentMap for MDX decks.

ryan-roemer avatar Sep 21 '22 20:09 ryan-roemer

Per slack discussion, we're not blocking on this and I've filed https://github.com/FormidableLabs/spectacle/issues/1232 to capture.

ryan-roemer avatar Sep 21 '22 21:09 ryan-roemer

@paulmarsicloud I've finished my cleanup of examples configs and dependencies. Mind double checking my commits?

Commits look good and works proper on my end!

paulmarsicloud avatar Sep 22 '22 00:09 paulmarsicloud

@paulmarsicloud We're missing a build task for examples/mdx which I'm going to add (and to CI)

ryan-roemer avatar Sep 22 '22 15:09 ryan-roemer

I've added the build task. I think we're otherwise ready for this PR with all the rest of the follow-on work ticketed.

ryan-roemer avatar Sep 22 '22 15:09 ryan-roemer