Farmbot-Web-App/webpack/history.tsx

8 lines
233 B
TypeScript

import { browserHistory } from "react-router";
export let history = browserHistory;
export let push = (url: string) => history.push(url);
export function getPathArray() {
return history.getCurrentLocation().pathname.split("/");
}