Luma

Results 58 comments of Luma

memo Next.js uses `window.location` for asPath: - https://github.com/vercel/next.js/blob/canary/packages/next/client/index.tsx#L203 - https://github.com/vercel/next.js/blob/canary/packages/next/shared/lib/utils.ts#L285-L294 We should parse and replace by hand. - URL path params are parsed here https://github.com/vercel/next.js/blob/canary/packages/next/shared/lib/router/utils/sorted-routes.ts - https://github.com/vercel/next.js/blob/canary/packages/next/shared/lib/router/utils/route-regex.ts

```js const { isDynamicRoute } = require('next/dist/shared/lib/router/utils/is-dynamic') const { searchParamsToUrlQuery } = require('next/dist/shared/lib/router/utils/querystring') const { formatUrl } = require('next/dist/shared/lib/router/utils/format-url') const { interpolateAs } = require('next/dist/shared/lib/router/router.js') function omitParmsFromQuery(query, params) { const...

Another idea. ```js const str = '/[name]/[id]/bar/[[foo...]]' const f = str .replace(/\/\[\[/g, '/${') .replace(/\/\.\.\.\]\]/g, '/}') .replace(/\/\]\]/g, '/}') .replace(/\/\[/g, '/${') .replace(/\.\.\.\]\](\/|$)/g, '}$1') .replace(/\.\.\.\](\/|$)/g, '}$1') .replace(/\](\/|$)/g, '}$1') console.log(`\`${f}\``) ```

Please read, we need your vote. We're implemented solution for this as https://github.com/aspida/pathpida/pull/124, but this has disadvantage that this includes approx 40KB bundled parts. Current `$path.ts` takes approx 0.3KB per...

@ValentinH It bundles some of next.js utility functions. It is treeshaked but maybe it includes much more than what really needed. As an other option, we're planning to add option...

@ValentinH > If this is coming from Next then it should really increase the final size if we are already using Next.js. Or it's more complex than that? Next.js has...

request changes にしましたが、他の人の意見も聞きたいです。

v11が出た時期は9ヶ月前。10ヶ月以上前のnext.jsを使っているとdropすることになります。

Awaitedを使いたいがこれTS4.5か。

TS3.9は無視で良いんだっけ。対応バージョンはどこかに明記しておきたいな。codegenだし一層大事かもしれない。