@quilted/quilt 0.5.157 → 0.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (171) hide show
  1. package/CHANGELOG.md +42 -0
  2. package/build/esm/graphql/testing/matchers/operations.mjs +1 -1
  3. package/build/esm/graphql/testing/matchers/utilities.mjs +1 -1
  4. package/build/esm/graphql/testing/matchers.mjs +4 -3
  5. package/build/esm/graphql/testing.mjs +5 -1
  6. package/build/esm/react/testing.mjs +5 -2
  7. package/build/esnext/globals.esnext +1 -1
  8. package/build/esnext/graphql/testing/matchers/operations.esnext +49 -19
  9. package/build/esnext/graphql/testing/matchers/utilities.esnext +18 -15
  10. package/build/esnext/graphql/testing/matchers.esnext +4 -3
  11. package/build/esnext/graphql/testing.esnext +4 -1
  12. package/build/esnext/html/HTML.esnext +6 -9
  13. package/build/esnext/react/testing.esnext +4 -2
  14. package/build/esnext/server/ServerContext.esnext +14 -2
  15. package/build/esnext/server/preload.esnext +9 -10
  16. package/build/esnext/server/request-router.esnext +138 -141
  17. package/build/esnext/utilities/react.esnext +1 -4
  18. package/build/tsconfig.tsbuildinfo +1 -1
  19. package/build/typescript/globals.d.ts +1 -0
  20. package/build/typescript/globals.d.ts.map +1 -1
  21. package/build/typescript/graphql/testing/matchers/utilities.d.ts +1 -1
  22. package/build/typescript/graphql/testing/matchers/utilities.d.ts.map +1 -1
  23. package/build/typescript/graphql/testing/matchers.d.ts +10 -8
  24. package/build/typescript/graphql/testing/matchers.d.ts.map +1 -1
  25. package/build/typescript/graphql/testing.d.ts +7 -1
  26. package/build/typescript/graphql/testing.d.ts.map +1 -1
  27. package/build/typescript/modules.d.ts +23 -0
  28. package/build/typescript/modules.d.ts.map +1 -0
  29. package/build/typescript/react/testing.d.ts +7 -2
  30. package/build/typescript/react/testing.d.ts.map +1 -1
  31. package/configuration/rollup.config.js +3 -0
  32. package/package.json +66 -197
  33. package/source/globals.ts +2 -0
  34. package/source/graphql/testing/matchers/operations.ts +1 -1
  35. package/source/graphql/testing/matchers/utilities.ts +1 -1
  36. package/source/graphql/testing/matchers.ts +15 -22
  37. package/source/graphql/testing.ts +11 -1
  38. package/source/modules.ts +31 -0
  39. package/source/react/testing.ts +10 -3
  40. package/tsconfig.json +1 -3
  41. package/build/cjs/assets.cjs +0 -39
  42. package/build/cjs/async.cjs +0 -32
  43. package/build/cjs/env.cjs +0 -7
  44. package/build/cjs/events.cjs +0 -46
  45. package/build/cjs/globals.cjs +0 -21
  46. package/build/cjs/graphql/server.cjs +0 -14
  47. package/build/cjs/graphql/testing/matchers/operations.cjs +0 -42
  48. package/build/cjs/graphql/testing/matchers/utilities.cjs +0 -43
  49. package/build/cjs/graphql/testing/matchers.cjs +0 -10
  50. package/build/cjs/graphql/testing.cjs +0 -18
  51. package/build/cjs/graphql.cjs +0 -21
  52. package/build/cjs/html/HTML.cjs +0 -21
  53. package/build/cjs/html.cjs +0 -133
  54. package/build/cjs/http.cjs +0 -146
  55. package/build/cjs/index.cjs +0 -2
  56. package/build/cjs/localize.cjs +0 -46
  57. package/build/cjs/magic/app.cjs +0 -2
  58. package/build/cjs/magic/assets.cjs +0 -2
  59. package/build/cjs/magic/request-router.cjs +0 -2
  60. package/build/cjs/navigate/testing.cjs +0 -12
  61. package/build/cjs/navigate.cjs +0 -70
  62. package/build/cjs/performance.cjs +0 -26
  63. package/build/cjs/polyfills/abort-controller.cjs +0 -4
  64. package/build/cjs/polyfills/base.cjs +0 -4
  65. package/build/cjs/polyfills/crypto.cjs +0 -4
  66. package/build/cjs/polyfills/fetch-get-set-cookie.cjs +0 -4
  67. package/build/cjs/polyfills/fetch.cjs +0 -4
  68. package/build/cjs/polyfills/noop.cjs +0 -4
  69. package/build/cjs/react/testing.cjs +0 -30
  70. package/build/cjs/react/tools.cjs +0 -19
  71. package/build/cjs/react.cjs +0 -15
  72. package/build/cjs/request-router/index.cjs +0 -12
  73. package/build/cjs/request-router/node.cjs +0 -12
  74. package/build/cjs/server/ServerContext.cjs +0 -20
  75. package/build/cjs/server/preload.cjs +0 -37
  76. package/build/cjs/server/request-router.cjs +0 -266
  77. package/build/cjs/server.cjs +0 -114
  78. package/build/cjs/signals.cjs +0 -51
  79. package/build/cjs/static/StaticContext.cjs +0 -20
  80. package/build/cjs/static/index.cjs +0 -261
  81. package/build/cjs/static/render.cjs +0 -44
  82. package/build/cjs/testing.cjs +0 -12
  83. package/build/cjs/threads.cjs +0 -117
  84. package/build/cjs/utilities/react.cjs +0 -12
  85. package/build/esm/magic/request-router.mjs +0 -1
  86. package/build/esm/polyfills/abort-controller.mjs +0 -1
  87. package/build/esm/polyfills/base.mjs +0 -1
  88. package/build/esm/polyfills/crypto.mjs +0 -1
  89. package/build/esm/polyfills/fetch-get-set-cookie.mjs +0 -1
  90. package/build/esm/polyfills/fetch.mjs +0 -1
  91. package/build/esm/polyfills/noop.mjs +0 -1
  92. package/build/esm/static/StaticContext.mjs +0 -18
  93. package/build/esm/static/index.mjs +0 -259
  94. package/build/esm/static/render.mjs +0 -42
  95. package/build/esm/testing.mjs +0 -1
  96. package/build/esnext/magic/app.esnext +0 -1
  97. package/build/esnext/magic/assets.esnext +0 -1
  98. package/build/esnext/magic/request-router.esnext +0 -1
  99. package/build/esnext/polyfills/abort-controller.esnext +0 -1
  100. package/build/esnext/polyfills/base.esnext +0 -1
  101. package/build/esnext/polyfills/crypto.esnext +0 -1
  102. package/build/esnext/polyfills/fetch-get-set-cookie.esnext +0 -1
  103. package/build/esnext/polyfills/fetch.esnext +0 -1
  104. package/build/esnext/polyfills/noop.esnext +0 -1
  105. package/build/esnext/static/StaticContext.esnext +0 -18
  106. package/build/esnext/static/index.esnext +0 -259
  107. package/build/esnext/static/render.esnext +0 -42
  108. package/build/esnext/testing.esnext +0 -1
  109. package/build/typescript/App.d.ts +0 -48
  110. package/build/typescript/App.d.ts.map +0 -1
  111. package/build/typescript/TestApp.d.ts +0 -17
  112. package/build/typescript/TestApp.d.ts.map +0 -1
  113. package/build/typescript/global.d.ts +0 -8
  114. package/build/typescript/global.d.ts.map +0 -1
  115. package/build/typescript/magic/app.d.ts +0 -4
  116. package/build/typescript/magic/app.d.ts.map +0 -1
  117. package/build/typescript/magic/assets.d.ts +0 -5
  118. package/build/typescript/magic/assets.d.ts.map +0 -1
  119. package/build/typescript/magic/request-router.d.ts +0 -4
  120. package/build/typescript/magic/request-router.d.ts.map +0 -1
  121. package/build/typescript/matchers/graphql/operations.d.ts +0 -7
  122. package/build/typescript/matchers/graphql/operations.d.ts.map +0 -1
  123. package/build/typescript/matchers/graphql/utilities.d.ts +0 -8
  124. package/build/typescript/matchers/graphql/utilities.d.ts.map +0 -1
  125. package/build/typescript/matchers/graphql.d.ts +0 -9
  126. package/build/typescript/matchers/graphql.d.ts.map +0 -1
  127. package/build/typescript/matchers.d.ts +0 -3
  128. package/build/typescript/matchers.d.ts.map +0 -1
  129. package/build/typescript/polyfills/abort-controller.d.ts +0 -2
  130. package/build/typescript/polyfills/abort-controller.d.ts.map +0 -1
  131. package/build/typescript/polyfills/base.d.ts +0 -2
  132. package/build/typescript/polyfills/base.d.ts.map +0 -1
  133. package/build/typescript/polyfills/crypto.d.ts +0 -2
  134. package/build/typescript/polyfills/crypto.d.ts.map +0 -1
  135. package/build/typescript/polyfills/fetch-get-set-cookie.d.ts +0 -2
  136. package/build/typescript/polyfills/fetch-get-set-cookie.d.ts.map +0 -1
  137. package/build/typescript/polyfills/fetch.d.ts +0 -2
  138. package/build/typescript/polyfills/fetch.d.ts.map +0 -1
  139. package/build/typescript/polyfills/noop.d.ts +0 -2
  140. package/build/typescript/polyfills/noop.d.ts.map +0 -1
  141. package/build/typescript/react/index.d.ts +0 -3
  142. package/build/typescript/react/index.d.ts.map +0 -1
  143. package/build/typescript/react-dom/index.d.ts +0 -3
  144. package/build/typescript/react-dom/index.d.ts.map +0 -1
  145. package/build/typescript/server/index.d.ts +0 -16
  146. package/build/typescript/server/index.d.ts.map +0 -1
  147. package/build/typescript/static/StaticContext.d.ts +0 -13
  148. package/build/typescript/static/StaticContext.d.ts.map +0 -1
  149. package/build/typescript/static/index.d.ts +0 -20
  150. package/build/typescript/static/index.d.ts.map +0 -1
  151. package/build/typescript/static/render.d.ts +0 -19
  152. package/build/typescript/static/render.d.ts.map +0 -1
  153. package/build/typescript/testing.d.ts +0 -2
  154. package/build/typescript/testing.d.ts.map +0 -1
  155. package/quilt.project.ts +0 -5
  156. package/source/magic/app.ts +0 -5
  157. package/source/magic/assets.ts +0 -8
  158. package/source/magic/request-router.ts +0 -5
  159. package/source/polyfills/README.md +0 -3
  160. package/source/polyfills/abort-controller.ts +0 -1
  161. package/source/polyfills/base.ts +0 -1
  162. package/source/polyfills/crypto.ts +0 -1
  163. package/source/polyfills/fetch-get-set-cookie.ts +0 -1
  164. package/source/polyfills/fetch.ts +0 -1
  165. package/source/polyfills/noop.ts +0 -1
  166. package/source/static/StaticContext.tsx +0 -39
  167. package/source/static/index.tsx +0 -315
  168. package/source/static/render.tsx +0 -40
  169. package/source/testing.ts +0 -1
  170. /package/build/esm/{magic/app.mjs → modules.mjs} +0 -0
  171. /package/build/{esm/magic/assets.mjs → esnext/modules.esnext} +0 -0
@@ -1,48 +0,0 @@
1
- import type { ComponentProps, PropsWithChildren, ReactNode } from 'react';
2
- import { Routing, type Routes, type Router } from '@quilted/react-router';
3
- import { type Performance } from '@quilted/react-performance';
4
- import { Localization } from '@quilted/react-localize';
5
- interface Props {
6
- /**
7
- * A React element that adds global HTTP headers to the page. Alternatively, you
8
- * can pass `false` to disable Quilt’s HTTP-related features.
9
- *
10
- * @see https://github.com/lemonmade/quilt/blob/main/documentation/features/http.md
11
- */
12
- http?: boolean | ReactNode;
13
- /**
14
- * A React element that add adjusts the HTML document, like adding global `head`
15
- * elements to the page or customizing the `html` and `body` elements. Alternatively,
16
- * you can pass `false` to disable Quilt’s HTML-related features.
17
- *
18
- * @see https://github.com/lemonmade/quilt/blob/main/documentation/features/html.md
19
- */
20
- html?: boolean | ReactNode;
21
- /**
22
- * Routes for your application. You can use this prop when you have a static set of routes
23
- * that do not depend on any React context. If you do need dynamic routes, you will need to
24
- * remove this prop, and instead use the `useRoutes()` hook from this library in a child
25
- * component.
26
- */
27
- routes?: Routes;
28
- /**
29
- * Customizes how routing is performed in this application. You can pass a `Router`
30
- * object, or the props of the `<Routing />` component from Quilt, which will be passed through
31
- * to that component. Alternatively, you can pass `false` to disable Quilt’s routing features.
32
- */
33
- routing?: boolean | Router | Pick<ComponentProps<typeof Routing>, 'isExternal' | 'prefix' | 'state' | 'url'>;
34
- /**
35
- * Customizes how localization is performed in this application. You can pass a string
36
- * to set the locale of the app directly, or an object with the props of the `<Localization />`
37
- * component. Alternatively, you can pass `false` to disable Quilt’s localization features.
38
- */
39
- localization?: boolean | string | Pick<ComponentProps<typeof Localization>, 'locale'>;
40
- /**
41
- * Customizes how performance tracking works in this application. You can pass a `Performance`
42
- * object, or `false` to disable Quilt’s performance features.
43
- */
44
- performance?: boolean | Performance;
45
- }
46
- export declare function QuiltApp({ http, html, routes, routing, localization, children, performance, }: PropsWithChildren<Props>): JSX.Element;
47
- export {};
48
- //# sourceMappingURL=App.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"App.d.ts","sourceRoot":"","sources":["../../source/App.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,cAAc,EAAE,iBAAiB,EAAE,SAAS,EAAC,MAAM,OAAO,CAAC;AAIxE,OAAO,EAAC,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,MAAM,EAAC,MAAM,uBAAuB,CAAC;AACxE,OAAO,EAAqB,KAAK,WAAW,EAAC,MAAM,4BAA4B,CAAC;AAChF,OAAO,EAAC,YAAY,EAAC,MAAM,yBAAyB,CAAC;AAErD,UAAU,KAAK;IACb;;;;;OAKG;IACH,IAAI,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAE3B;;;;;;OAMG;IACH,IAAI,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAE3B;;;;;OAKG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;;;OAIG;IACH,OAAO,CAAC,EACJ,OAAO,GACP,MAAM,GACN,IAAI,CACF,cAAc,CAAC,OAAO,OAAO,CAAC,EAC9B,YAAY,GAAG,QAAQ,GAAG,OAAO,GAAG,KAAK,CAC1C,CAAC;IAEN;;;;OAIG;IACH,YAAY,CAAC,EACT,OAAO,GACP,MAAM,GACN,IAAI,CAAC,cAAc,CAAC,OAAO,YAAY,CAAC,EAAE,QAAQ,CAAC,CAAC;IAExD;;;OAGG;IACH,WAAW,CAAC,EAAE,OAAO,GAAG,WAAW,CAAC;CACrC;AAID,wBAAgB,QAAQ,CAAC,EACvB,IAAW,EACX,IAAW,EACX,MAAM,EACN,OAAc,EACd,YAAmB,EACnB,QAAQ,EACR,WAAkB,GACnB,EAAE,iBAAiB,CAAC,KAAK,CAAC,eAkF1B"}
@@ -1,17 +0,0 @@
1
- import { type PropsWithChildren } from 'react';
2
- import { type Router } from '@quilted/react-router';
3
- interface Props {
4
- /**
5
- * Customizes how routing is handled during testing. You can provide a test router, or
6
- * you can pass `false` to disable Quilt’s routing features.
7
- */
8
- routing?: boolean | Router;
9
- /**
10
- * Customizes how localization is handled during testing. You can provide a string locale,
11
- * or you can pass `false` to disable Quilt’s localization features.
12
- */
13
- localization?: boolean | string;
14
- }
15
- export declare function QuiltAppTesting({ routing, localization, children, }: PropsWithChildren<Props>): JSX.Element;
16
- export {};
17
- //# sourceMappingURL=TestApp.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"TestApp.d.ts","sourceRoot":"","sources":["../../source/TestApp.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAC,KAAK,iBAAiB,EAAC,MAAM,OAAO,CAAC;AAE7C,OAAO,EAAC,KAAK,MAAM,EAAC,MAAM,uBAAuB,CAAC;AAIlD,UAAU,KAAK;IACb;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IAE3B;;;OAGG;IACH,YAAY,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;CACjC;AAID,wBAAgB,eAAe,CAAC,EAC9B,OAAc,EACd,YAAmB,EACnB,QAAQ,GACT,EAAE,iBAAiB,CAAC,KAAK,CAAC,eAM1B"}
@@ -1,8 +0,0 @@
1
- import { type AsyncModulesGlobal } from '@quilted/async';
2
- export interface QuiltGlobal {
3
- readonly AsyncModules: AsyncModulesGlobal;
4
- }
5
- declare const quilt: QuiltGlobal;
6
- export default quilt;
7
- export { quilt, quilt as global };
8
- //# sourceMappingURL=global.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"global.d.ts","sourceRoot":"","sources":["../../source/global.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,kBAAkB,EACxB,MAAM,gBAAgB,CAAC;AAExB,MAAM,WAAW,WAAW;IAC1B,QAAQ,CAAC,YAAY,EAAE,kBAAkB,CAAC;CAC3C;AAGD,QAAA,MAAM,KAAK,aAAuD,CAAC;AAanE,eAAe,KAAK,CAAC;AACrB,OAAO,EAAC,KAAK,EAAE,KAAK,IAAI,MAAM,EAAC,CAAC"}
@@ -1,4 +0,0 @@
1
- import type { ComponentType } from 'react';
2
- declare const App: ComponentType<Record<string, unknown>>;
3
- export default App;
4
- //# sourceMappingURL=app.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../../source/magic/app.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,aAAa,EAAC,MAAM,OAAO,CAAC;AAEzC,OAAO,CAAC,MAAM,GAAG,EAAE,aAAa,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;AAE1D,eAAe,GAAG,CAAC"}
@@ -1,5 +0,0 @@
1
- import type { AssetsCacheKey, BrowserAssets as BrowserAssetsType } from '@quilted/assets';
2
- export declare const BrowserAssets: {
3
- new <CacheKey = AssetsCacheKey>(): BrowserAssetsType<CacheKey>;
4
- };
5
- //# sourceMappingURL=assets.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"assets.d.ts","sourceRoot":"","sources":["../../../source/magic/assets.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,cAAc,EACd,aAAa,IAAI,iBAAiB,EACnC,MAAM,iBAAiB,CAAC;AAEzB,MAAM,CAAC,OAAO,CAAC,MAAM,aAAa,EAAE;IAClC,KAAK,QAAQ,GAAG,cAAc,KAAK,iBAAiB,CAAC,QAAQ,CAAC,CAAC;CAChE,CAAC"}
@@ -1,4 +0,0 @@
1
- import type { RequestRouter, RequestHandler } from '@quilted/request-router';
2
- declare const handleOrRouter: RequestRouter | RequestHandler;
3
- export default handleOrRouter;
4
- //# sourceMappingURL=request-router.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"request-router.d.ts","sourceRoot":"","sources":["../../../source/magic/request-router.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,aAAa,EAAE,cAAc,EAAC,MAAM,yBAAyB,CAAC;AAE3E,OAAO,CAAC,MAAM,cAAc,EAAE,aAAa,GAAG,cAAc,CAAC;AAE7D,eAAe,cAAc,CAAC"}
@@ -1,7 +0,0 @@
1
- import type { MatcherState } from 'expect';
2
- import type { GraphQLAnyOperation, GraphQLController } from '@quilted/graphql/testing';
3
- export declare function toHavePerformedGraphQLOperation<Variables>(this: MatcherState, graphql: GraphQLController, operation: GraphQLAnyOperation<any, Variables>, variables?: Variables): {
4
- pass: boolean;
5
- message: () => string;
6
- };
7
- //# sourceMappingURL=operations.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"operations.d.ts","sourceRoot":"","sources":["../../../../source/matchers/graphql/operations.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,YAAY,EAAC,MAAM,QAAQ,CAAC;AAOzC,OAAO,KAAK,EACV,mBAAmB,EACnB,iBAAiB,EAElB,MAAM,0BAA0B,CAAC;AAKlC,wBAAgB,+BAA+B,CAAC,SAAS,EACvD,IAAI,EAAE,YAAY,EAClB,OAAO,EAAE,iBAAiB,EAC1B,SAAS,EAAE,mBAAmB,CAAC,GAAG,EAAE,SAAS,CAAC,EAC9C,SAAS,CAAC,EAAE,SAAS;;;EAgEtB"}
@@ -1,8 +0,0 @@
1
- export declare function assertIsGraphQLController(graphql: unknown, { expectation, isNot }: {
2
- expectation: string;
3
- isNot: boolean;
4
- }): void;
5
- export declare function diffVariables(actual: Record<string, any>, expected: Record<string, any>, { expand }: {
6
- expand?: boolean | undefined;
7
- }): string | null;
8
- //# sourceMappingURL=utilities.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"utilities.d.ts","sourceRoot":"","sources":["../../../../source/matchers/graphql/utilities.ts"],"names":[],"mappings":"AAWA,wBAAgB,yBAAyB,CACvC,OAAO,EAAE,OAAO,EAChB,EAAC,WAAW,EAAE,KAAK,EAAC,EAAE;IAAC,WAAW,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAC,QAa5D;AAED,wBAAgB,aAAa,CAC3B,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAC3B,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAC7B,EAAC,MAAc,EAAC;;CAAA,iBAKjB"}
@@ -1,9 +0,0 @@
1
- import type { GraphQLAnyOperation, GraphQLController } from '@quilted/graphql/testing';
2
- declare global {
3
- namespace jest {
4
- interface Matchers<R, T = {}> {
5
- toHavePerformedGraphQLOperation<Variables>(graphql: GraphQLController, operation: GraphQLAnyOperation<any, Variables>, variables?: Variables): void;
6
- }
7
- }
8
- }
9
- //# sourceMappingURL=graphql.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"graphql.d.ts","sourceRoot":"","sources":["../../../source/matchers/graphql.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,mBAAmB,EACnB,iBAAiB,EAClB,MAAM,0BAA0B,CAAC;AAIlC,OAAO,CAAC,MAAM,CAAC;IAGb,UAAU,IAAI,CAAC;QACb,UAAU,QAAQ,CAAC,CAAC,EAAE,CAAC,GAAG,EAAE;YAC1B,+BAA+B,CAAC,SAAS,EACvC,OAAO,EAAE,iBAAiB,EAC1B,SAAS,EAAE,mBAAmB,CAAC,GAAG,EAAE,SAAS,CAAC,EAC9C,SAAS,CAAC,EAAE,SAAS,GACpB,IAAI,CAAC;SACT;KACF;CACF"}
@@ -1,3 +0,0 @@
1
- import '@quilted/react-testing/matchers';
2
- import './matchers/graphql.ts';
3
- //# sourceMappingURL=matchers.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"matchers.d.ts","sourceRoot":"","sources":["../../source/matchers.ts"],"names":[],"mappings":"AAAA,OAAO,iCAAiC,CAAC;AAEzC,OAAO,uBAAuB,CAAC"}
@@ -1,2 +0,0 @@
1
- import '@quilted/polyfills/abort-controller';
2
- //# sourceMappingURL=abort-controller.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"abort-controller.d.ts","sourceRoot":"","sources":["../../../source/polyfills/abort-controller.ts"],"names":[],"mappings":"AAAA,OAAO,qCAAqC,CAAC"}
@@ -1,2 +0,0 @@
1
- import '@quilted/polyfills/base';
2
- //# sourceMappingURL=base.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"base.d.ts","sourceRoot":"","sources":["../../../source/polyfills/base.ts"],"names":[],"mappings":"AAAA,OAAO,yBAAyB,CAAC"}
@@ -1,2 +0,0 @@
1
- import '@quilted/polyfills/crypto';
2
- //# sourceMappingURL=crypto.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"crypto.d.ts","sourceRoot":"","sources":["../../../source/polyfills/crypto.ts"],"names":[],"mappings":"AAAA,OAAO,2BAA2B,CAAC"}
@@ -1,2 +0,0 @@
1
- import '@quilted/polyfills/fetch-get-set-cookie';
2
- //# sourceMappingURL=fetch-get-set-cookie.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"fetch-get-set-cookie.d.ts","sourceRoot":"","sources":["../../../source/polyfills/fetch-get-set-cookie.ts"],"names":[],"mappings":"AAAA,OAAO,yCAAyC,CAAC"}
@@ -1,2 +0,0 @@
1
- import '@quilted/polyfills/fetch';
2
- //# sourceMappingURL=fetch.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"fetch.d.ts","sourceRoot":"","sources":["../../../source/polyfills/fetch.ts"],"names":[],"mappings":"AAAA,OAAO,0BAA0B,CAAC"}
@@ -1,2 +0,0 @@
1
- import '@quilted/polyfills/noop';
2
- //# sourceMappingURL=noop.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"noop.d.ts","sourceRoot":"","sources":["../../../source/polyfills/noop.ts"],"names":[],"mappings":"AAAA,OAAO,yBAAyB,CAAC"}
@@ -1,3 +0,0 @@
1
- export * from '@quilted/react';
2
- export { default } from '@quilted/react';
3
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../source/react/index.ts"],"names":[],"mappings":"AACA,cAAc,gBAAgB,CAAC;AAE/B,OAAO,EAAC,OAAO,EAAC,MAAM,gBAAgB,CAAC"}
@@ -1,3 +0,0 @@
1
- export * from '@quilted/react-dom';
2
- export { default } from '@quilted/react-dom';
3
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../source/react-dom/index.ts"],"names":[],"mappings":"AACA,cAAc,oBAAoB,CAAC;AAEnC,OAAO,EAAC,OAAO,EAAC,MAAM,oBAAoB,CAAC"}
@@ -1,16 +0,0 @@
1
- export { Html, Serialize, HtmlManager, HtmlContext, renderHtmlToString, SERVER_ACTION_ID as HTML_SERVER_ACTION_ID, } from '@quilted/react-html/server';
2
- export { ServerAction, useServerAction, ServerRenderManager, ServerRenderManagerContext, extract, } from '@quilted/react-server-render/server';
3
- export { styleAssetAttributes, styleAssetPreloadAttributes, scriptAssetAttributes, scriptAssetPreloadAttributes, createBrowserAssetsFromManifests, createBrowserAssetsEntryFromManifest, } from '@quilted/assets';
4
- export type { Asset, AssetsCacheKey, BrowserAssets, BrowserAssetsEntry, BrowserAssetSelector, BrowserAssetModuleSelector, AssetsBuildManifest, AssetsBuildManifestEntry, } from '@quilted/assets';
5
- export { useAssetsCacheKey, useModuleAssets, AssetsContext, AssetsManager, SERVER_ACTION_ID as ASSETS_SERVER_ACTION_ID, } from '@quilted/react-assets/server';
6
- export type { ServerActionKind, ServerActionOptions, ServerActionPerform, ServerRenderPass, } from '@quilted/react-server-render/server';
7
- export type { HttpState } from '@quilted/react-http/server';
8
- export { createRequestRouterLocalization } from '@quilted/react-localize/request-router';
9
- export type { RequestRouterLocalization, RouteLocalization, ResolvedRouteLocalization, } from '@quilted/react-localize/request-router';
10
- export { Request, Response, EnhancedRequest, EnhancedResponse, createRequestRouter, createHeaders, } from '@quilted/request-router';
11
- export type { Headers, BodyInit, ResponseInit, RequestInit, Cookies, CookieOptions, RequestRouter, RequestContext, RequestHandler, ResponseOrEnhancedResponse, CookieDefinition, RequestRegistration, RequestRegistrationOptions, } from '@quilted/request-router';
12
- export { parseAcceptLanguageHeader } from '@quilted/react-localize';
13
- export { ServerContext } from './ServerContext.tsx';
14
- export { createServerRender, renderAppToResponse, renderAppToStreamedResponse, } from './request-router.tsx';
15
- export { createAssetPreloader, type AssetPreloadOptions } from './preload.ts';
16
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../source/server/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,IAAI,EACJ,SAAS,EACT,WAAW,EACX,WAAW,EACX,kBAAkB,EAClB,gBAAgB,IAAI,qBAAqB,GAC1C,MAAM,4BAA4B,CAAC;AACpC,OAAO,EACL,YAAY,EACZ,eAAe,EACf,mBAAmB,EACnB,0BAA0B,EAC1B,OAAO,GACR,MAAM,qCAAqC,CAAC;AAE7C,OAAO,EACL,oBAAoB,EACpB,2BAA2B,EAC3B,qBAAqB,EACrB,4BAA4B,EAC5B,gCAAgC,EAChC,oCAAoC,GACrC,MAAM,iBAAiB,CAAC;AACzB,YAAY,EACV,KAAK,EACL,cAAc,EACd,aAAa,EACb,kBAAkB,EAClB,oBAAoB,EACpB,0BAA0B,EAC1B,mBAAmB,EACnB,wBAAwB,GACzB,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACL,iBAAiB,EACjB,eAAe,EACf,aAAa,EACb,aAAa,EACb,gBAAgB,IAAI,uBAAuB,GAC5C,MAAM,8BAA8B,CAAC;AACtC,YAAY,EACV,gBAAgB,EAChB,mBAAmB,EACnB,mBAAmB,EACnB,gBAAgB,GACjB,MAAM,qCAAqC,CAAC;AAC7C,YAAY,EAAC,SAAS,EAAC,MAAM,4BAA4B,CAAC;AAC1D,OAAO,EAAC,+BAA+B,EAAC,MAAM,wCAAwC,CAAC;AACvF,YAAY,EACV,yBAAyB,EACzB,iBAAiB,EACjB,yBAAyB,GAC1B,MAAM,wCAAwC,CAAC;AAChD,OAAO,EACL,OAAO,EACP,QAAQ,EACR,eAAe,EACf,gBAAgB,EAChB,mBAAmB,EACnB,aAAa,GACd,MAAM,yBAAyB,CAAC;AACjC,YAAY,EACV,OAAO,EACP,QAAQ,EACR,YAAY,EACZ,WAAW,EACX,OAAO,EACP,aAAa,EACb,aAAa,EACb,cAAc,EACd,cAAc,EACd,0BAA0B,EAC1B,gBAAgB,EAChB,mBAAmB,EACnB,0BAA0B,GAC3B,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAC,yBAAyB,EAAC,MAAM,yBAAyB,CAAC;AAElE,OAAO,EAAC,aAAa,EAAC,MAAM,qBAAqB,CAAC;AAClD,OAAO,EACL,kBAAkB,EAClB,mBAAmB,EACnB,2BAA2B,GAC5B,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAAC,oBAAoB,EAAE,KAAK,mBAAmB,EAAC,MAAM,cAAc,CAAC"}
@@ -1,13 +0,0 @@
1
- import type { PropsWithChildren } from 'react';
2
- import { type AssetsManager } from '@quilted/react-assets/server';
3
- import { type HTMLManager } from '@quilted/react-html/server';
4
- import { type HttpManager } from '@quilted/react-http/server';
5
- interface Props {
6
- url?: string | URL;
7
- html?: HTMLManager;
8
- http?: HttpManager;
9
- assets?: AssetsManager;
10
- }
11
- export declare function StaticContext({ url, html, http, assets, children, }: PropsWithChildren<Props>): import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>;
12
- export {};
13
- //# sourceMappingURL=StaticContext.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"StaticContext.d.ts","sourceRoot":"","sources":["../../../source/static/StaticContext.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,iBAAiB,EAAC,MAAM,OAAO,CAAC;AAE7C,OAAO,EAAgB,KAAK,aAAa,EAAC,MAAM,8BAA8B,CAAC;AAE/E,OAAO,EAAc,KAAK,WAAW,EAAC,MAAM,4BAA4B,CAAC;AACzE,OAAO,EAAoB,KAAK,WAAW,EAAC,MAAM,4BAA4B,CAAC;AAI/E,UAAU,KAAK;IACb,GAAG,CAAC,EAAE,MAAM,GAAG,GAAG,CAAC;IACnB,IAAI,CAAC,EAAE,WAAW,CAAC;IACnB,IAAI,CAAC,EAAE,WAAW,CAAC;IACnB,MAAM,CAAC,EAAE,aAAa,CAAC;CACxB;AAED,wBAAgB,aAAa,CAAC,EAC5B,GAAG,EACH,IAAI,EACJ,IAAI,EACJ,MAAM,EACN,QAAQ,GACT,EAAE,iBAAiB,CAAC,KAAK,CAAC,0FAgB1B"}
@@ -1,20 +0,0 @@
1
- import { type ComponentType } from 'react';
2
- import { type BrowserAssets } from '@quilted/assets';
3
- import type { HttpState } from '@quilted/react-http/server';
4
- export interface RenderDetails {
5
- readonly route: string;
6
- readonly hasChildren: boolean;
7
- readonly fallback: boolean;
8
- readonly content: string;
9
- readonly http: HttpState;
10
- }
11
- export interface Options {
12
- routes: string[];
13
- assets: BrowserAssets<any>;
14
- crawl?: boolean;
15
- baseUrl?: string;
16
- prettify?: boolean;
17
- onRender(details: RenderDetails): void | Promise<void>;
18
- }
19
- export declare function renderStatic(App: ComponentType<any>, { assets, routes: startingRoutes, onRender, crawl, baseUrl, prettify, }: Options): Promise<void>;
20
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../source/static/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAC,KAAK,aAAa,EAAC,MAAM,OAAO,CAAC;AAGzC,OAAO,EAAC,KAAK,aAAa,EAAC,MAAM,iBAAiB,CAAC;AAanD,OAAO,KAAK,EAAC,SAAS,EAAC,MAAM,4BAA4B,CAAC;AAI1D,MAAM,WAAW,aAAa;IAC5B,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,WAAW,EAAE,OAAO,CAAC;IAC9B,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC3B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,IAAI,EAAE,SAAS,CAAC;CAC1B;AAOD,MAAM,WAAW,OAAO;IACtB,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,MAAM,EAAE,aAAa,CAAC,GAAG,CAAC,CAAC;IAC3B,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,OAAO,EAAE,aAAa,GAAG,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CACxD;AAID,wBAAsB,YAAY,CAChC,GAAG,EAAE,aAAa,CAAC,GAAG,CAAC,EACvB,EACE,MAAM,EACN,MAAM,EAAE,cAAc,EACtB,QAAQ,EACR,KAAY,EACZ,OAAkB,EAClB,QAAe,GAChB,EAAE,OAAO,iBAuOX"}
@@ -1,19 +0,0 @@
1
- import type { ReactElement } from 'react';
2
- import type { Options as ExtractOptions } from '@quilted/react-server-render/server';
3
- import { HTMLManager } from '@quilted/react-html/server';
4
- import { HttpManager } from '@quilted/react-http/server';
5
- import { AssetsManager } from '@quilted/react-assets/server';
6
- import type { AssetsCacheKey } from '@quilted/assets';
7
- interface Options<CacheKey = AssetsCacheKey> extends ExtractOptions {
8
- url?: string | URL;
9
- cacheKey?: CacheKey;
10
- headers?: NonNullable<ConstructorParameters<typeof HttpManager>[0]>['headers'];
11
- }
12
- export declare function renderApp<CacheKey = AssetsCacheKey>(app: ReactElement<any>, { decorate, url, headers, cacheKey, ...rest }?: Options<CacheKey>): Promise<{
13
- markup: string | undefined;
14
- http: HttpManager;
15
- html: HTMLManager;
16
- assets: AssetsManager<CacheKey>;
17
- }>;
18
- export {};
19
- //# sourceMappingURL=render.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"render.d.ts","sourceRoot":"","sources":["../../../source/static/render.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,YAAY,EAAC,MAAM,OAAO,CAAC;AAGxC,OAAO,KAAK,EAAC,OAAO,IAAI,cAAc,EAAC,MAAM,qCAAqC,CAAC;AACnF,OAAO,EAAC,WAAW,EAAC,MAAM,4BAA4B,CAAC;AACvD,OAAO,EAAC,WAAW,EAAC,MAAM,4BAA4B,CAAC;AACvD,OAAO,EAAC,aAAa,EAAC,MAAM,8BAA8B,CAAC;AAC3D,OAAO,KAAK,EAAC,cAAc,EAAC,MAAM,iBAAiB,CAAC;AAIpD,UAAU,OAAO,CAAC,QAAQ,GAAG,cAAc,CAAE,SAAQ,cAAc;IACjE,GAAG,CAAC,EAAE,MAAM,GAAG,GAAG,CAAC;IACnB,QAAQ,CAAC,EAAE,QAAQ,CAAC;IACpB,OAAO,CAAC,EAAE,WAAW,CACnB,qBAAqB,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,CAAC,CAC7C,CAAC,SAAS,CAAC,CAAC;CACd;AAED,wBAAsB,SAAS,CAAC,QAAQ,GAAG,cAAc,EACvD,GAAG,EAAE,YAAY,CAAC,GAAG,CAAC,EACtB,EAAC,QAAQ,EAAE,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,GAAG,IAAI,EAAC,GAAE,OAAO,CAAC,QAAQ,CAAM;;;;;GAkBpE"}
@@ -1,2 +0,0 @@
1
- export * from '@quilted/testing';
2
- //# sourceMappingURL=testing.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"testing.d.ts","sourceRoot":"","sources":["../../source/testing.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC"}
package/quilt.project.ts DELETED
@@ -1,5 +0,0 @@
1
- import {createProject, quiltPackage} from '@quilted/craft';
2
-
3
- export default createProject((project) => {
4
- project.use(quiltPackage({react: true}));
5
- });
@@ -1,5 +0,0 @@
1
- import type {ComponentType} from 'react';
2
-
3
- declare const App: ComponentType<Record<string, unknown>>;
4
-
5
- export default App;
@@ -1,8 +0,0 @@
1
- import type {
2
- AssetsCacheKey,
3
- BrowserAssets as BrowserAssetsType,
4
- } from '@quilted/assets';
5
-
6
- export declare const BrowserAssets: {
7
- new <CacheKey = AssetsCacheKey>(): BrowserAssetsType<CacheKey>;
8
- };
@@ -1,5 +0,0 @@
1
- import type {RequestRouter, RequestHandler} from '@quilted/request-router';
2
-
3
- declare const handleOrRouter: RequestRouter | RequestHandler;
4
-
5
- export default handleOrRouter;
@@ -1,3 +0,0 @@
1
- # `@quilted/quilt/polyfills/*`
2
-
3
- This directory re-exports the polyfills provided by `@quilted/polyfills`. This is done because most consumers will have a dependency only on `@quilted/quilt`, not `@quilted/polyfills`, but we need to insert imports for polyfills into “app code”. Strict package managers, like `pnpm`, will then install `@quilted/polyfills` in such a way that imports of that package fail to resolve. To fix this, we re-export all the entry points that can be inserted in app code from `@quilted/quilt/polyfills/*`.
@@ -1 +0,0 @@
1
- import '@quilted/polyfills/abort-controller';
@@ -1 +0,0 @@
1
- import '@quilted/polyfills/base';
@@ -1 +0,0 @@
1
- import '@quilted/polyfills/crypto';
@@ -1 +0,0 @@
1
- import '@quilted/polyfills/fetch-get-set-cookie';
@@ -1 +0,0 @@
1
- import '@quilted/polyfills/fetch';
@@ -1 +0,0 @@
1
- import '@quilted/polyfills/noop';
@@ -1,39 +0,0 @@
1
- import type {PropsWithChildren} from 'react';
2
-
3
- import {AssetsContext, type AssetsManager} from '@quilted/react-assets/server';
4
- import {InitialUrlContext} from '@quilted/react-router';
5
- import {HTMLContext, type HTMLManager} from '@quilted/react-html/server';
6
- import {HttpServerContext, type HttpManager} from '@quilted/react-http/server';
7
-
8
- import {maybeWrapContext} from '../utilities/react.tsx';
9
-
10
- interface Props {
11
- url?: string | URL;
12
- html?: HTMLManager;
13
- http?: HttpManager;
14
- assets?: AssetsManager;
15
- }
16
-
17
- export function StaticContext({
18
- url,
19
- html,
20
- http,
21
- assets,
22
- children,
23
- }: PropsWithChildren<Props>) {
24
- const normalizedUrl = typeof url === 'string' ? new URL(url) : url;
25
-
26
- return maybeWrapContext(
27
- AssetsContext,
28
- assets,
29
- maybeWrapContext(
30
- HttpServerContext,
31
- http,
32
- maybeWrapContext(
33
- HTMLContext,
34
- html,
35
- maybeWrapContext(InitialUrlContext, normalizedUrl, children),
36
- ),
37
- ),
38
- );
39
- }