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 markdown stories #464

Merged
merged 5 commits into from
Mar 27, 2018
Merged

Fix markdown stories #464

merged 5 commits into from
Mar 27, 2018

Conversation

shawnbot
Copy link
Contributor

Fixes #463. This commit hosed our markdown parsing by adding a markdown preprocessor to Storybook, which prevented us from parsing the markdown files as raw markdown.

Also, single quotes are better than double?

/cc @primer/ds-core

.map(parseBlockAttrs)
.filter(({block}) => block.story !== "false")
.map(node => {
return nodeToStory(node, path)
Copy link

Choose a reason for hiding this comment

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

Nit: could technically be on the same line

.map(node => nodeToStory(node, path))

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yup, good catch. Pretty sure I was doing something else in this function earlier. 😊

Copy link
Member

@jonrohan jonrohan left a comment

Choose a reason for hiding this comment

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

Left more of a note for future selves, but I'm cool with this if it works 👍

loader: 'raw-loader',
})
}
})
Copy link
Member

Choose a reason for hiding this comment

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

Don't know if this is common practice in webpack config, but I would feel better if eventually we used the standard loaders, maybe enhancing with extra webpack stuff. 🤷‍♂️

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yep, it's definitely a hack!

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.

None yet

3 participants