Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
import { Link, Redirect, Route, Switch } from 'react-router-dom';
import FlowText from './flow-text';
const Text = importComponent(() => import('./text'));
const ServerDataHoC = withServerData(({ serverData }) => (
<output>{serverData.method}</output>
));
const ServerDataHook = () => {
const serverData = useServerData();
return <output>{serverData.method}</output>;
};
const ConfigHoC = withConfig(({ config: { hoc } }) => <h1>{hoc}</h1>);
const ConfigHook = () => {
const config = useConfig();
return <h1>{config.hook}</h1>;
};
export default render(
<div>
Link to two
</div>