Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function GitHubContainer(props) {
let version = Iconify.getVersion(),
majorVersion = version.split('.').shift();
const text = {
code:
'',
codeImport: "import Iconify from '@iconify/iconify';",
sample: '<span data-icon="fa-home" class="iconify"></span>',
sample2:
'',
};
return (
function HTMLCodeBlock(props) {
let icon = props.icon,
name = icon.icon.prefix + ':' + icon.icon.name;
let version = Iconify.getVersion(),
majorVersion = version.split('.').shift();
let attribs = [],
styles = [];
if (icon.hasColor && icon.color) {
styles.push('color: ' + icon.color + ';');
}
if (icon.height) {
styles.push('font-size: ' + icon.height + 'px;');
}
if (styles.length) {
attribs.push(' style="' + styles.join(' ') + '"');
}