diff --git a/src/index.es6 b/src/index.es6
index 8a46fcb..0b43cdc 100644
--- a/src/index.es6
+++ b/src/index.es6
@@ -17,6 +17,8 @@
* You should have received a copy of the GNU Lesser General Public License
* along with Cockpit; If not, see .
*/
+
+import 'cockpit';
import React from 'react';
import { StarterKit } from './starter-kit-view.jsx';
@@ -30,10 +32,4 @@ function render() {
);
}
-/**
- * Start the application.
- */
-export function run() {
- // do initial render
- render();
-}
+document.addEventListener("DOMContentLoaded", render);
diff --git a/src/index.js b/src/index.js
deleted file mode 100644
index 771afd4..0000000
--- a/src/index.js
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * Copyright (C) 2017 Red Hat, Inc.
- *
- * Cockpit is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as published by
- * the Free Software Foundation; either version 2.1 of the License, or
- * (at your option) any later version.
- *
- * Cockpit is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public License
- * along with this package; If not, see .
- */
-
-var cockpit = require("cockpit");
-
-document.addEventListener("DOMContentLoaded", function() {
- var app = require("./index.es6");
- app.run();
-});
diff --git a/webpack.config.js b/webpack.config.js
index a0c0372..b162489 100644
--- a/webpack.config.js
+++ b/webpack.config.js
@@ -21,7 +21,7 @@ var production = process.env.NODE_ENV === 'production';
var info = {
entries: {
"index": [
- "./index.js"
+ "./index.es6"
]
},
files: [