1
0
mirror of https://github.com/phuoc-ng/csslayout.git synced 2025-10-24 11:16:27 +02:00

Refactor details view

This commit is contained in:
Phuoc Nguyen
2019-11-24 22:27:52 +07:00
parent 59c65079a3
commit 24d36dc1c6
38 changed files with 41 additions and 256 deletions

View File

@@ -0,0 +1,13 @@
import React from 'react';
import highlight from '../helpers/highlight';
const SampleCode = ({ code, lang }) => {
return code === ''
? <></>
: (
<pre className="h-100 lh-copy ma0" dangerouslySetInnerHTML={{ __html: highlight(code, lang) }} />
);
};
export default SampleCode;