showing results for - "getstaticpaths with redux"
Noah
03 May 2017
1import store from '.../store';
2
3export const getStaticPaths: GetStaticPaths = async () => {
4  const state = store.getState();
5
6  const paths = state.user.users.map((user) => {
7    return (
8      {params: {username: user.username}}
9    );
10  });
11
12  return {paths, fallback: false}
13};