├── .browserslistrc ├── .DS_Store ├── .babelrc ├── .editorconfig ├── .eslintignore ├── .eslintrc ├── .gitignore ├── .npmrc ├── .travis.yml ├── LICENSE ├── README.md ├── example └── src │ ├── components │ ├── AppLink │ │ └── index.tsx │ ├── Logger │ │ └── index.tsx │ ├── LoggerHOC │ │ └── index.tsx │ ├── LoggerHooks │ │ └── index.tsx │ ├── ManualHistory │ │ └── index.tsx │ └── PreviewLocation │ │ └── index.tsx │ ├── index.ejs │ ├── index.tsx │ ├── pages │ ├── About.tsx │ ├── Contact.tsx │ ├── FixedRedirect.tsx │ ├── FixedRedirectManual.tsx │ ├── Home.tsx │ ├── Page.tsx │ └── RegularRedirect.tsx │ └── styles.js ├── jest.config.json ├── package.json ├── src ├── LastLocationContext.ts ├── LastLocationProvider.tsx ├── RedirectWithoutLastLocation.spec.tsx ├── RedirectWithoutLastLocation.tsx ├── index.ts ├── prevent.ts ├── types.ts ├── useLastLocation.spec.tsx ├── useLastLocation.ts ├── withLastLocation.spec.tsx └── withLastLocation.tsx ├── tests └── setup.js ├── tsconfig.json ├── webpack.config.js └── yarn.lock / .browserslistrc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/ .browserslistrc -------------------------------------------------------------------------------- /.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/.DS_Store -------------------------------------------------------------------------------- /.babelrc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/.babelrc -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/.editorconfig -------------------------------------------------------------------------------- /.eslintignore: -------------------------------------------------------------------------------- 1 | /coverage/* 2 | /dist/* 3 | -------------------------------------------------------------------------------- /.eslintrc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/.eslintrc -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/.gitignore -------------------------------------------------------------------------------- /.npmrc: -------------------------------------------------------------------------------- 1 | scripts-prepend-node-path=true 2 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/.travis.yml -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/README.md -------------------------------------------------------------------------------- /example/src/components/AppLink/index.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/components/AppLink/index.tsx -------------------------------------------------------------------------------- /example/src/components/Logger/index.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/components/Logger/index.tsx -------------------------------------------------------------------------------- /example/src/components/LoggerHOC/index.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/components/LoggerHOC/index.tsx -------------------------------------------------------------------------------- /example/src/components/LoggerHooks/index.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/components/LoggerHooks/index.tsx -------------------------------------------------------------------------------- /example/src/components/ManualHistory/index.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/components/ManualHistory/index.tsx -------------------------------------------------------------------------------- /example/src/components/PreviewLocation/index.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/components/PreviewLocation/index.tsx -------------------------------------------------------------------------------- /example/src/index.ejs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/index.ejs -------------------------------------------------------------------------------- /example/src/index.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/index.tsx -------------------------------------------------------------------------------- /example/src/pages/About.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/pages/About.tsx -------------------------------------------------------------------------------- /example/src/pages/Contact.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/pages/Contact.tsx -------------------------------------------------------------------------------- /example/src/pages/FixedRedirect.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/pages/FixedRedirect.tsx -------------------------------------------------------------------------------- /example/src/pages/FixedRedirectManual.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/pages/FixedRedirectManual.tsx -------------------------------------------------------------------------------- /example/src/pages/Home.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/pages/Home.tsx -------------------------------------------------------------------------------- /example/src/pages/Page.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/pages/Page.tsx -------------------------------------------------------------------------------- /example/src/pages/RegularRedirect.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/pages/RegularRedirect.tsx -------------------------------------------------------------------------------- /example/src/styles.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/example/src/styles.js -------------------------------------------------------------------------------- /jest.config.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/jest.config.json -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/package.json -------------------------------------------------------------------------------- /src/LastLocationContext.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/src/LastLocationContext.ts -------------------------------------------------------------------------------- /src/LastLocationProvider.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/src/LastLocationProvider.tsx -------------------------------------------------------------------------------- /src/RedirectWithoutLastLocation.spec.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/src/RedirectWithoutLastLocation.spec.tsx -------------------------------------------------------------------------------- /src/RedirectWithoutLastLocation.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/src/RedirectWithoutLastLocation.tsx -------------------------------------------------------------------------------- /src/index.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/src/index.ts -------------------------------------------------------------------------------- /src/prevent.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/src/prevent.ts -------------------------------------------------------------------------------- /src/types.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/src/types.ts -------------------------------------------------------------------------------- /src/useLastLocation.spec.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/src/useLastLocation.spec.tsx -------------------------------------------------------------------------------- /src/useLastLocation.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/src/useLastLocation.ts -------------------------------------------------------------------------------- /src/withLastLocation.spec.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/src/withLastLocation.spec.tsx -------------------------------------------------------------------------------- /src/withLastLocation.tsx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/src/withLastLocation.tsx -------------------------------------------------------------------------------- /tests/setup.js: -------------------------------------------------------------------------------- 1 | import '@testing-library/jest-dom'; 2 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/tsconfig.json -------------------------------------------------------------------------------- /webpack.config.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/webpack.config.js -------------------------------------------------------------------------------- /yarn.lock: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hinok/react-router-last-location/HEAD/yarn.lock --------------------------------------------------------------------------------