Skip to content

Commit

Permalink
ensure ?raw import works in React example
Browse files Browse the repository at this point in the history
  • Loading branch information
hmsk committed Feb 24, 2023
1 parent 28c5cdd commit ee8768c
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 20 deletions.
39 changes: 19 additions & 20 deletions examples/react/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions examples/react/src/App.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import React, { useState } from 'react'
import logo from './logo.svg'
import './App.css'
import { html, toc, ReactComponent } from './content.md'
import content from './content.md?raw'
import LinkToRepository from './LinkToRepository'

function App() {
Expand Down Expand Up @@ -34,6 +35,10 @@ function App() {
{toc.map((h,i) => <li key={i}>{h.level} - {h.content}</li>)}
<h2>ReactComponent</h2>
<ReactComponent LinkToRepository={LinkToRepository} />
<h2>?raw import</h2>
<blockquote>
{content}
</blockquote>
</main>
</div>
)
Expand Down

0 comments on commit ee8768c

Please sign in to comment.