Skip to content

Instantly share code, notes, and snippets.

@neenhouse
Last active June 1, 2020 15:26
Show Gist options
  • Save neenhouse/4b0dc9946e4a356d813ef5154a39a23e to your computer and use it in GitHub Desktop.
Save neenhouse/4b0dc9946e4a356d813ef5154a39a23e to your computer and use it in GitHub Desktop.
Federated AppShell
import React from 'react';
import PropTypes from 'prop-types';
import {HashRouter} from 'react-router-dom';
import {Header} from './Header';
import {Footer} from './Footer';
import './App.less';
function App({children}) {
return (
<HashRouter>
<div className={'appshell-container'}>
<Header />
<div className="appshell-content">{children}</div>
<Footer />
</div>
</HashRouter>
);
}
App.propTypes = {
children: PropTypes.Any
};
export default App;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment