diff --git a/client/boot/index.js b/client/boot/index.js
index 0a67855932d5e..62ebe30f6cf42 100644
--- a/client/boot/index.js
+++ b/client/boot/index.js
@@ -203,11 +203,11 @@ function reduxStoreReady( reduxStore ) {
}
if ( config.isEnabled( 'network-connection' ) ) {
- require( 'lib/network-connection' ).init( reduxStore );
+ asyncRequire( 'lib/network-connection', netConn => netConn.init( reduxStore ) );
}
if ( config.isEnabled( 'css-hot-reload' ) ) {
- require( 'lib/css-hot-reload' )();
+ asyncRequire( 'lib/css-hot-reload', cssHotReload => cssHotReload() );
}
// Render Layout only for non-isomorphic sections.
diff --git a/client/layout/index.jsx b/client/layout/index.jsx
index 7f118a87844ca..263183b01c1d0 100644
--- a/client/layout/index.jsx
+++ b/client/layout/index.jsx
@@ -10,7 +10,8 @@ var React = require( 'react' ),
/**
* Internal dependencies
*/
-var MasterbarLoggedIn = require( 'layout/masterbar/logged-in' ),
+var AsyncLoad = require( 'components/async-load' ),
+ MasterbarLoggedIn = require( 'layout/masterbar/logged-in' ),
MasterbarLoggedOut = require( 'layout/masterbar/logged-out' ),
observe = require( 'lib/mixins/data-observe' ),
GlobalNotices = require( 'components/global-notices' ),
@@ -29,8 +30,7 @@ var MasterbarLoggedIn = require( 'layout/masterbar/logged-in' ),
QueryPreferences = require( 'components/data/query-preferences' ),
KeyboardShortcutsMenu,
Layout,
- SupportUser,
- Happychat = require( 'components/happychat' );
+ SupportUser;
import { isOffline } from 'state/application/selectors';
import { hasSidebar } from 'state/ui/selectors';
@@ -171,7 +171,7 @@ Layout = React.createClass( {
isEnabled={ translator.isEnabled() }
isActive={ translator.isActivated() }/>
{ this.renderPreview() }
- { config.isEnabled( 'happychat' ) && this.props.chatIsOpen && }
+ { config.isEnabled( 'happychat' ) && this.props.chatIsOpen && }
);
}