create project

This commit is contained in:
ismailsosic
2022-12-27 12:05:56 +01:00
parent 2a33a2d3de
commit cd2143287c
16035 changed files with 2489703 additions and 0 deletions

View File

@@ -0,0 +1,16 @@
import { useContext } from 'react';
import { RouterContext } from '../../shared/lib/router-context';
/**
* useRouter from `next/compat/router` is designed to assist developers
* migrating from `pages/` to `app/`. Unlike `next/router`, this hook does not
* throw when the `NextRouter` is not mounted, and instead returns `null`. The
* more concrete return type here lets developers use this hook within
* components that could be shared between both `app/` and `pages/` and handle
* to the case where the router is not mounted.
*
* @returns The `NextRouter` instance if it's available, otherwise `null`.
*/ export function useRouter() {
return useContext(RouterContext);
}
//# sourceMappingURL=router.js.map

View File

@@ -0,0 +1 @@
{"version":3,"sources":["../../../client/compat/router.ts"],"names":["useContext","RouterContext","useRouter"],"mappings":"AAAA,SAASA,UAAU,QAAQ,OAAO,CAAA;AAClC,SAASC,aAAa,QAAQ,iCAAiC,CAAA;AAG/D;;;;;;;;;GASG,CACH,OAAO,SAASC,SAAS,GAAsB;IAC7C,OAAOF,UAAU,CAACC,aAAa,CAAC,CAAA;CACjC"}