Fixed problem with rendering to null DOM component
This commit is contained in:
parent
7552e20cbc
commit
38964fbd61
1 changed files with 2 additions and 2 deletions
|
@ -14,10 +14,10 @@ if ($('body').hasClass('index')) { // Render components on index
|
||||||
React.render(<ProjectImagesMain />, document.getElementById('project-images-main'));
|
React.render(<ProjectImagesMain />, document.getElementById('project-images-main'));
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($('navbar')) {
|
if ($('navbar').length > 0) {
|
||||||
React.render(<NavBar />, $('navbar')[0]);
|
React.render(<NavBar />, $('navbar')[0]);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($('#breadcrumbs')) {
|
if ($('#breadcrumbs') > 0) {
|
||||||
React.render(<Breadcrumbs />, $('#breadcrumbs')[0]);
|
React.render(<Breadcrumbs />, $('#breadcrumbs')[0]);
|
||||||
}
|
}
|
||||||
|
|
Reference in a new issue