Skip to content
This repository was archived by the owner on Mar 10, 2025. It is now read-only.

Adding/extending support for several unhandled block types (GitBook Page refs,Hint,Anchor,Emoji node,inline-image,etc) - #7

Open
I-Dont-Remember wants to merge 13 commits into
conversation:mainfrom
I-Dont-Remember:feature/personal-spaces-inline-emojis
Open

I-Dont-Remember wants to merge 13 commits into
conversation:mainfrom
I-Dont-Remember:feature/personal-spaces-inline-emojis

Conversation

@I-Dont-Remember

@I-Dont-Remember I-Dont-Remember commented Jun 20, 2023 •

Copy link
Copy Markdown

Dove in to just fix page links, ended up finding and touching up a variety of other things I ran into.

Changes

  • Now able to pull Spaces from a user's personal, not just an organization space
  • GitBook page links were undefined, now are connected to the actual page metadata and look like [Submit](/docs/requests/submit "Submit a Request")
  • Hint blocks were undefined, now are rendered as block quote with emoji (see README for example).
  • inline images in some cases were undefined
  • anchor links were showing as undefined
  • Emoji node - should fix UnhandledPromiseRejection "Unknown inline type: emoji" #5
  • Added unit tests for the new functionality
  • Script for downloading all images of a Space

QA

  • Unit tests pass
  • Files formatted with Prettier
  • type checks pass
  • No undefined showing when run on actual Spaces

Areas for potential improvement

I was moving fast and didn't have the time to hit every area I might have liked to.

  • I believe the files lookup dict could be combined with the spaceContent data that I added to the markdown renderer
  • Would be nice to be able to pass a prefix to GitBook links rendering, in case you want to keep the same structure at the new destination for your markdown but it sits under a different path.

@I-Dont-Remember I-Dont-Remember changed the title Adding/extending support for several unhandled block types (GitBook Page refs,Hint,Anchor,inline-image,etc) Adding/extending support for several unhandled block types (GitBook Page refs,Hint,Anchor,Emoji node,inline-image,etc) Jun 20, 2023
@I-Dont-Remember
I-Dont-Remember force-pushed the feature/personal-spaces-inline-emojis branch from 1b6e85a to e81b89a Compare June 28, 2023 15:42
@serpixel serpixel mentioned this pull request Sep 11, 2023
4 tasks done
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Development

Successfully merging this pull request may close these issues.

UnhandledPromiseRejection "Unknown inline type: emoji"

1 participant