Skip to content

Commit

Permalink
Don't let extra attributes not match
Browse files Browse the repository at this point in the history
  • Loading branch information
jonrohan committed Nov 6, 2017
1 parent 1779f0e commit 49e98ce
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion .storybook/lib/storiesFromMarkdown.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const htmlParser = new htmlToReact.Parser()

const railsOcticonToReact = (html) => {
// <%= octicon "tools" %> to <Octicon name="tools" />
const octre = /<%= octicon ["']([a-z\-]+)["'] %>/gi
const octre = /<%= octicon ["']([a-z\-]+)["'][^%]*%>/gi
html = html.replace(octre, (match, name) => {
return ReactDOMServer.renderToStaticMarkup(<Octicon name={name} />)
})
Expand Down

0 comments on commit 49e98ce

Please sign in to comment.