-
-
Notifications
You must be signed in to change notification settings - Fork 5k
Closed
Labels
Description
Environment Info
Node version(node -v): v6.9.2
Your theme _config.yml (Optional): next
For question
I specified code block as follow. But when i deploy the site and found syntax highlight doesn't work. I guess it 's the reason of dom element in jsx. How can i fix it?
//use ```javascript (or try: jsx) doesn't work
let items = ['textA', 'textB', 'textC'];
let list = items => items.map( text => <li>{ text }</li>);
let foo = (
<div id="foo">
zhi zhi zhi!
<ul>
{list(items)}
</ul>
</div>
);
let items = ['textA', 'textB', 'textC'];
let list = items => items.map(text => Object(__WEBPACK_IMPORTED_MODULE_0__preact__["a" /* h */])(
'li',
null,
text
));
let foo = Object(__WEBPACK_IMPORTED_MODULE_0__preact__["a" /* h */])(
'div',
{ id: 'foo' },
'zhi zhi zhi!',
Object(__WEBPACK_IMPORTED_MODULE_0__preact__["a" /* h */])(
'ul',
null,
list(items)
)
);Reactions are currently unavailable