Passed
Pull Request — master (#141)
by
unknown
01:35
created

client/index.js   A

Complexity

Total Complexity 1
Complexity/F 0

Size

Lines of Code 20
Function Count 0

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
wmc 1
eloc 16
mnd 1
bc 1
fnc 0
dl 0
loc 20
rs 10
bpm 0
cpm 0
noi 0
c 0
b 0
f 0
1
import React from 'react';
2
import { render } from 'react-dom';
3
4
import App from './app';
5
6
const renderToPage = Component => {
7
  render(<Component />, document.getElementById('app'));
8
};
9
10
renderToPage(App);
11
12
if (process.env.NODE_ENV === 'development' && module.hot) {
13
  module.hot.accept('./app', () => {
14
    const HotApp = require('./app').default;
15
    renderToPage(HotApp);
16
  });
17
}
18
19
console.log('Version:', window.CONFIG.VERSION);
20