Skip to content

Commit

Permalink
fix(readme): update jsx example
Browse files Browse the repository at this point in the history
  • Loading branch information
tunnckoCore committed Feb 11, 2017
1 parent 78ae626 commit c37b53e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
6 changes: 2 additions & 4 deletions .verb.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ const tree = h('h1.big#hero.header', 'Hello World')
const html = toHtml(tree)
console.log(html)
// => '<h1 id="hero" class="big header">Hello World</h1>'

```

Or, using the JSX syntax and adding the [JSX Pragma](https://jasonformat.com/wtf-is-jsx/) somewhere at the top
Expand All @@ -50,10 +49,9 @@ const h = require('mich-h')
const toHtml = require('{%= name %}')

const hi = 'Hello World'
const tree = <h1 id="hero" className="big header">{hi}<h1>
const tree = <h1 id="hero" className="big header">{hi}</h1>

const html = toHtml(tree)
console.log(html)
console.log(toHtml(tree))
// => '<h1 id="hero" class="big header">Hello World</h1>'
```

Expand Down
6 changes: 2 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ const tree = h('h1.big#hero.header', 'Hello World')
const html = toHtml(tree)
console.log(html)
// => '<h1 id="hero" class="big header">Hello World</h1>'

```

Or, using the JSX syntax and adding the [JSX Pragma](https://jasonformat.com/wtf-is-jsx/) somewhere at the top
Expand All @@ -60,10 +59,9 @@ const h = require('mich-h')
const toHtml = require('mich-to-html')

const hi = 'Hello World'
const tree = <h1 id="hero" className="big header">{hi}<h1>
const tree = <h1 id="hero" className="big header">{hi}</h1>

const html = toHtml(tree)
console.log(html)
console.log(toHtml(tree))
// => '<h1 id="hero" class="big header">Hello World</h1>'
```

Expand Down

0 comments on commit c37b53e

Please sign in to comment.