mirror of
https://github.com/tomru/pdfer.git
synced 2026-03-03 14:37:21 +01:00
19 lines
416 B
JavaScript
19 lines
416 B
JavaScript
import { render } from 'preact';
|
|
|
|
function init() {
|
|
const App = require('./views').default;
|
|
render(App, document.getElementById('root'), document.getElementById('app'));
|
|
}
|
|
|
|
init();
|
|
|
|
if (process.env.NODE_ENV === 'production') {
|
|
console.log('What are ya looking at?');
|
|
} else {
|
|
require('preact/devtools');
|
|
// listen for HMR
|
|
if (module.hot) {
|
|
module.hot.accept('./views', init);
|
|
}
|
|
}
|