@wtf/project-docs 1.0.1 → 1.1.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 (200) hide show
  1. package/README.md +2 -0
  2. package/api/.generated +49 -0
  3. package/api/@wtf/project-astro/README.md +68 -0
  4. package/api/@wtf/project-astro/config/README.md +38 -0
  5. package/api/@wtf/project-astro/config/functions/baseConfig.md +43 -0
  6. package/api/@wtf/project-astro/config/functions/baseOf.md +23 -0
  7. package/api/@wtf/project-astro/config/functions/siteOf.md +22 -0
  8. package/api/@wtf/project-astro/config/type-aliases/BaseOptions.md +73 -0
  9. package/api/@wtf/project-astro/config/type-aliases/Env.md +11 -0
  10. package/api/@wtf/project-astro/errors/README.md +16 -0
  11. package/api/@wtf/project-astro/errors/classes/BrokenLinksError.md +172 -0
  12. package/api/@wtf/project-astro/errors/classes/InvalidRedirectError.md +174 -0
  13. package/api/@wtf/project-astro/errors/classes/RedirectedLinksError.md +173 -0
  14. package/api/@wtf/project-astro/errors/classes/SiteError.md +192 -0
  15. package/api/@wtf/project-astro/index/README.md +19 -0
  16. package/api/@wtf/project-astro/index/type-aliases/BrokenLink.md +35 -0
  17. package/api/@wtf/project-astro/index/type-aliases/IgnoredLine.md +47 -0
  18. package/api/@wtf/project-astro/index/type-aliases/RedirectInput.md +17 -0
  19. package/api/@wtf/project-astro/index/type-aliases/RedirectMatch.md +35 -0
  20. package/api/@wtf/project-astro/index/type-aliases/RedirectRule.md +61 -0
  21. package/api/@wtf/project-astro/index/type-aliases/RedirectStatus.md +12 -0
  22. package/api/@wtf/project-astro/index/type-aliases/RedirectedLink.md +17 -0
  23. package/api/@wtf/project-astro/index/type-aliases/Redirects.md +35 -0
  24. package/api/@wtf/project-astro/links/README.md +27 -0
  25. package/api/@wtf/project-astro/links/functions/brokenLinksIn.md +27 -0
  26. package/api/@wtf/project-astro/links/functions/links.md +29 -0
  27. package/api/@wtf/project-astro/links/functions/redirectedLinksIn.md +27 -0
  28. package/api/@wtf/project-astro/links/variables/LINKS.md +11 -0
  29. package/api/@wtf/project-astro/pages/README.md +36 -0
  30. package/api/@wtf/project-astro/pages/functions/fixSearchUrlsIn.md +27 -0
  31. package/api/@wtf/project-astro/pages/functions/moveConflictingPages.md +23 -0
  32. package/api/@wtf/project-astro/pages/functions/pages.md +31 -0
  33. package/api/@wtf/project-astro/pages/functions/slashFolderLinksIn.md +35 -0
  34. package/api/@wtf/project-astro/pages/variables/PAGES.md +11 -0
  35. package/api/@wtf/project-astro/preview/README.md +34 -0
  36. package/api/@wtf/project-astro/preview/functions/files.md +39 -0
  37. package/api/@wtf/project-astro/preview/functions/listen.md +25 -0
  38. package/api/@wtf/project-astro/preview/functions/notFound.md +24 -0
  39. package/api/@wtf/project-astro/preview/functions/pagesOf.md +27 -0
  40. package/api/@wtf/project-astro/preview/type-aliases/FilesOptions.md +24 -0
  41. package/api/@wtf/project-astro/preview/type-aliases/Handler.md +21 -0
  42. package/api/@wtf/project-astro/preview/type-aliases/ListenOptions.md +35 -0
  43. package/api/@wtf/project-astro/preview/type-aliases/Listening.md +53 -0
  44. package/api/@wtf/project-astro/preview/type-aliases/Pages.md +35 -0
  45. package/api/@wtf/project-astro/redirects/README.md +28 -0
  46. package/api/@wtf/project-astro/redirects/functions/formatRedirects.md +28 -0
  47. package/api/@wtf/project-astro/redirects/functions/matchRedirect.md +35 -0
  48. package/api/@wtf/project-astro/redirects/functions/parseRedirects.md +32 -0
  49. package/api/@wtf/project-astro/redirects/variables/MAX_PARTS.md +11 -0
  50. package/api/@wtf/project-astro/redirects/variables/MAX_RULES.md +11 -0
  51. package/api/@wtf/project-astro/redirects/variables/MAX_SIZE.md +11 -0
  52. package/api/@wtf/project-oxfmt/variables/default.md +6 -6
  53. package/api/@wtf/project-oxlint/variables/default.md +17 -17
  54. package/api/@wtf/project-resolve/condition/variables/SOURCE_CONDITION.md +1 -1
  55. package/api/@wtf/project-resolve/env/functions/isHook.md +1 -1
  56. package/api/@wtf/project-resolve/env/functions/optionsWithoutHook.md +1 -1
  57. package/api/@wtf/project-resolve/env/functions/withoutHook.md +1 -1
  58. package/api/@wtf/project-resolve/env/type-aliases/Env.md +1 -1
  59. package/api/@wtf/project-resolve/errors/classes/ResolveError.md +4 -4
  60. package/api/@wtf/project-resolve/errors/classes/UnreadableWorkspaceError.md +6 -6
  61. package/api/@wtf/project-resolve/errors/classes/WorkspaceError.md +5 -5
  62. package/api/@wtf/project-resolve/hooks/functions/candidatesOf.md +1 -1
  63. package/api/@wtf/project-resolve/hooks/functions/sourcesHookOf.md +1 -1
  64. package/api/@wtf/project-resolve/hooks/functions/sourcesOf.md +1 -1
  65. package/api/@wtf/project-resolve/hooks/variables/resolveTypeScript.md +1 -1
  66. package/api/@wtf/project-resolve/node/functions/nodePlatform.md +5 -5
  67. package/api/@wtf/project-resolve/register/variables/REGISTERED.md +1 -1
  68. package/api/@wtf/project-resolve/workspace/functions/filesOf.md +1 -1
  69. package/api/@wtf/project-resolve/workspace/functions/packagesOf.md +1 -1
  70. package/api/@wtf/project-resolve/workspace/functions/workspaceAt.md +1 -1
  71. package/api/@wtf/project-resolve/workspace/functions/workspaceOf.md +1 -1
  72. package/api/@wtf/project-resolve/workspace/functions/workspaceRootAbove.md +1 -1
  73. package/api/@wtf/project-resolve/workspace/functions/workspaceRootOf.md +1 -1
  74. package/api/@wtf/project-resolve/workspace/type-aliases/Agent.md +1 -1
  75. package/api/@wtf/project-resolve/workspace/type-aliases/DirectoryEntry.md +4 -4
  76. package/api/@wtf/project-resolve/workspace/type-aliases/FileContents.md +3 -3
  77. package/api/@wtf/project-resolve/workspace/type-aliases/PackageManager.md +4 -4
  78. package/api/@wtf/project-resolve/workspace/type-aliases/PackageManagerName.md +1 -1
  79. package/api/@wtf/project-resolve/workspace/type-aliases/ProcessWorkspaceOptions.md +1 -1
  80. package/api/@wtf/project-resolve/workspace/type-aliases/Workspace.md +5 -5
  81. package/api/@wtf/project-resolve/workspace/type-aliases/WorkspaceDirectoryHandle.md +6 -6
  82. package/api/@wtf/project-resolve/workspace/type-aliases/WorkspaceFileHandle.md +3 -3
  83. package/api/@wtf/project-resolve/workspace/type-aliases/WorkspaceFiles.md +6 -6
  84. package/api/@wtf/project-resolve/workspace/type-aliases/WorkspaceOptions.md +2 -2
  85. package/api/@wtf/project-resolve/workspace/type-aliases/WorkspacePackage.md +4 -4
  86. package/api/@wtf/project-resolve/workspace/type-aliases/WorkspacePaths.md +7 -7
  87. package/api/@wtf/project-typedoc/config/functions/gitRevisionOf.md +1 -1
  88. package/api/@wtf/project-typedoc/config/functions/typedocConfig.md +1 -1
  89. package/api/@wtf/project-typedoc/config/type-aliases/RevisionSources.md +3 -3
  90. package/api/@wtf/project-typedoc/config/type-aliases/TypedocConfig.md +1 -1
  91. package/api/@wtf/project-typedoc/config/type-aliases/TypedocOptions.md +6 -6
  92. package/api/@wtf/project-typedoc/config/variables/nodeRun.md +1 -1
  93. package/api/@wtf/project-typedoc/plugins/functions/cleanGeneratedMarkdown.md +1 -1
  94. package/api/@wtf/project-typedoc/plugins/functions/linkTrackedSources.md +1 -1
  95. package/api/@wtf/project-typedoc/plugins/functions/preventMediaFiles.md +1 -1
  96. package/api/@wtf/project-typedoc/plugins/type-aliases/CleanGeneratedMarkdownOptions.md +3 -3
  97. package/api/@wtf/project-typedoc/plugins/type-aliases/LinkTrackedSourcesOptions.md +3 -3
  98. package/api/@wtf/project-typedoc/plugins/type-aliases/PreventMediaFilesOptions.md +3 -3
  99. package/api/@wtf/project-typedoc/plugins/type-aliases/Run.md +1 -1
  100. package/api/@wtf/project-typedoc/plugins/type-aliases/TypedocPlugin.md +1 -1
  101. package/api/@wtf/project-vite/functions/baseConfig.md +4 -4
  102. package/api/@wtf/project-vite/functions/buildsSite.md +1 -1
  103. package/api/@wtf/project-vite/functions/compress.md +1 -1
  104. package/api/@wtf/project-vite/functions/conditionsOf.md +1 -1
  105. package/api/@wtf/project-vite/type-aliases/BaseOptions.md +2 -2
  106. package/api/@wtf/project-vite/type-aliases/CompressOptions.md +4 -4
  107. package/api/@wtf/project-vite/variables/CLIENT_CONDITIONS.md +1 -1
  108. package/api/@wtf/project-vite/variables/COMPRESSIBLE.md +1 -1
  109. package/api/@wtf/project-vite/variables/FROM_DIST.md +1 -1
  110. package/api/@wtf/project-vite/variables/THRESHOLD.md +1 -1
  111. package/api/@wtf/project-vitest/browser/functions/browserConfig.md +1 -1
  112. package/api/@wtf/project-vitest/browser/functions/browserRootConfig.md +1 -1
  113. package/api/@wtf/project-vitest/browser/type-aliases/BrowserOptions.md +3 -3
  114. package/api/@wtf/project-vitest/config/functions/integrationConfig.md +1 -1
  115. package/api/@wtf/project-vitest/config/functions/packageConfig.md +1 -1
  116. package/api/@wtf/project-vitest/config/functions/rootConfig.md +1 -1
  117. package/api/@wtf/project-vitest/config/type-aliases/RootConfigOptions.md +2 -2
  118. package/api/@wtf/project-vitest/config/type-aliases/RootOptions.md +7 -7
  119. package/api/@wtf/project-vitest/config/variables/FROM_DIST.md +1 -1
  120. package/api/@wtf/project-vitest/config/variables/GUARD_TIMEOUT.md +1 -1
  121. package/api/@wtf/project-vitest/config/variables/integration.md +9 -9
  122. package/api/@wtf/project-vitest/process/functions/childEnv.md +1 -1
  123. package/api/@wtf/project-vitest/process/type-aliases/Env.md +1 -1
  124. package/api/@wtf/project-vitest/storybook/functions/storybookConfig.md +1 -1
  125. package/api/@wtf/project-vitest/storybook/type-aliases/StorybookOptions.md +2 -2
  126. package/api/@wtf/project-wpt/builtins/functions/builtins.md +1 -1
  127. package/api/@wtf/project-wpt/builtins/functions/intrinsics.md +1 -1
  128. package/api/@wtf/project-wpt/checkout/functions/checkoutFolderOf.md +1 -1
  129. package/api/@wtf/project-wpt/checkout/functions/checkoutTests.md +1 -1
  130. package/api/@wtf/project-wpt/checkout/functions/checkoutWpt.md +1 -1
  131. package/api/@wtf/project-wpt/checkout/functions/fileOf.md +1 -1
  132. package/api/@wtf/project-wpt/checkout/type-aliases/CheckedOutTests.md +3 -3
  133. package/api/@wtf/project-wpt/checkout/type-aliases/CheckoutOptions.md +8 -8
  134. package/api/@wtf/project-wpt/checkout/type-aliases/CheckoutTestsOptions.md +2 -2
  135. package/api/@wtf/project-wpt/checkout/variables/HARNESS.md +1 -1
  136. package/api/@wtf/project-wpt/checkout/variables/REWRITES.md +1 -1
  137. package/api/@wtf/project-wpt/checkout/variables/WPT_REPOSITORY.md +1 -1
  138. package/api/@wtf/project-wpt/errors/classes/HarnessFailedError.md +4 -4
  139. package/api/@wtf/project-wpt/errors/classes/InvalidCommitError.md +4 -4
  140. package/api/@wtf/project-wpt/errors/classes/InvalidExpectationsError.md +4 -4
  141. package/api/@wtf/project-wpt/errors/classes/NoSuiteError.md +4 -4
  142. package/api/@wtf/project-wpt/errors/classes/NotInWptError.md +5 -5
  143. package/api/@wtf/project-wpt/errors/classes/StaleExpectationError.md +4 -4
  144. package/api/@wtf/project-wpt/errors/classes/SubtestFailedError.md +4 -4
  145. package/api/@wtf/project-wpt/errors/classes/UnexpectedPassError.md +4 -4
  146. package/api/@wtf/project-wpt/errors/classes/WptError.md +4 -4
  147. package/api/@wtf/project-wpt/errors/classes/WptFetchError.md +4 -4
  148. package/api/@wtf/project-wpt/expectations/functions/checkHarness.md +1 -1
  149. package/api/@wtf/project-wpt/expectations/functions/checkSubtest.md +1 -1
  150. package/api/@wtf/project-wpt/expectations/functions/expectationOf.md +1 -1
  151. package/api/@wtf/project-wpt/expectations/functions/expectationsIssues.md +1 -1
  152. package/api/@wtf/project-wpt/expectations/functions/readExpectations.md +1 -1
  153. package/api/@wtf/project-wpt/expectations/functions/staleOf.md +1 -1
  154. package/api/@wtf/project-wpt/expectations/type-aliases/ReadExpectations.md +3 -3
  155. package/api/@wtf/project-wpt/index/type-aliases/ClearTimeout.md +1 -1
  156. package/api/@wtf/project-wpt/index/type-aliases/CreateRealm.md +1 -1
  157. package/api/@wtf/project-wpt/index/type-aliases/Env.md +1 -1
  158. package/api/@wtf/project-wpt/index/type-aliases/Exec.md +1 -1
  159. package/api/@wtf/project-wpt/index/type-aliases/Expectations.md +1 -1
  160. package/api/@wtf/project-wpt/index/type-aliases/FileExpectation.md +4 -4
  161. package/api/@wtf/project-wpt/index/type-aliases/FileResult.md +4 -4
  162. package/api/@wtf/project-wpt/index/type-aliases/Globals.md +1 -1
  163. package/api/@wtf/project-wpt/index/type-aliases/HarnessResult.md +4 -4
  164. package/api/@wtf/project-wpt/index/type-aliases/HarnessStatus.md +1 -1
  165. package/api/@wtf/project-wpt/index/type-aliases/HoldRejections.md +1 -1
  166. package/api/@wtf/project-wpt/index/type-aliases/Performance.md +3 -3
  167. package/api/@wtf/project-wpt/index/type-aliases/Realm.md +3 -3
  168. package/api/@wtf/project-wpt/index/type-aliases/SetTimeout.md +1 -1
  169. package/api/@wtf/project-wpt/index/type-aliases/SubtestResult.md +5 -5
  170. package/api/@wtf/project-wpt/index/type-aliases/SubtestStatus.md +1 -1
  171. package/api/@wtf/project-wpt/index/type-aliases/WptFile.md +3 -3
  172. package/api/@wtf/project-wpt/index/type-aliases/WptFiles.md +9 -9
  173. package/api/@wtf/project-wpt/index/type-aliases/WptPaths.md +4 -4
  174. package/api/@wtf/project-wpt/index/type-aliases/WptPlatform.md +6 -6
  175. package/api/@wtf/project-wpt/index/type-aliases/WptSystem.md +6 -6
  176. package/api/@wtf/project-wpt/index/type-aliases/WptTest.md +3 -3
  177. package/api/@wtf/project-wpt/meta/functions/idOf.md +1 -1
  178. package/api/@wtf/project-wpt/meta/functions/metaOf.md +1 -1
  179. package/api/@wtf/project-wpt/meta/functions/runsOutsideWindow.md +1 -1
  180. package/api/@wtf/project-wpt/meta/functions/scriptPathsOf.md +1 -1
  181. package/api/@wtf/project-wpt/meta/functions/testsOf.md +1 -1
  182. package/api/@wtf/project-wpt/meta/type-aliases/Meta.md +6 -6
  183. package/api/@wtf/project-wpt/node/functions/nodePlatform.md +1 -1
  184. package/api/@wtf/project-wpt/node/functions/nodeSystem.md +1 -1
  185. package/api/@wtf/project-wpt/node/variables/nodeExec.md +1 -1
  186. package/api/@wtf/project-wpt/node/variables/nodeFiles.md +1 -1
  187. package/api/@wtf/project-wpt/node/variables/nodeRealm.md +1 -1
  188. package/api/@wtf/project-wpt/node/variables/nodeRejections.md +1 -1
  189. package/api/@wtf/project-wpt/run/functions/runTest.md +1 -1
  190. package/api/@wtf/project-wpt/run/type-aliases/RunOptions.md +8 -8
  191. package/api/@wtf/project-wpt/run/type-aliases/RunPlatform.md +1 -1
  192. package/api/@wtf/project-wpt/run/variables/LONG_TIMEOUT.md +1 -1
  193. package/api/@wtf/project-wpt/run/variables/TIMEOUT.md +1 -1
  194. package/api/@wtf/project-wpt/run/variables/WPT_ORIGIN.md +1 -1
  195. package/api/@wtf/project-wpt/suite/functions/wptSuite.md +1 -1
  196. package/api/@wtf/project-wpt/suite/type-aliases/WptSuiteOptions.md +8 -8
  197. package/api/README.md +1 -0
  198. package/api/trains.json +3 -0
  199. package/guides/astro.md +173 -0
  200. package/package.json +3 -2
@@ -0,0 +1,174 @@
1
+ [Documentation](../../../../README.md) / [@wtf/project-astro](../../README.md) / [errors](../README.md) / InvalidRedirectError
2
+
3
+ # Class: InvalidRedirectError
4
+
5
+ Defined in: [packages/project-astro/src/errors.ts:64](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L64)
6
+
7
+ A rule of `_redirects` that GitLab Pages would ignore, and why, as it is written.
8
+
9
+ ## Extends
10
+
11
+ - [`SiteError`](SiteError.md)
12
+
13
+ ## Constructors
14
+
15
+ ### Constructor
16
+
17
+ ```ts
18
+ new InvalidRedirectError(rule, reason): InvalidRedirectError;
19
+ ```
20
+
21
+ Defined in: [packages/project-astro/src/errors.ts:70](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L70)
22
+
23
+ #### Parameters
24
+
25
+ | Parameter | Type |
26
+ | ------ | ------ |
27
+ | `rule` | `string` |
28
+ | `reason` | `string` |
29
+
30
+ #### Returns
31
+
32
+ `InvalidRedirectError`
33
+
34
+ #### Overrides
35
+
36
+ [`SiteError`](SiteError.md).[`constructor`](SiteError.md#constructor)
37
+
38
+ ## Properties
39
+
40
+ | Property | Modifier | Type | Default value | Description | Inherited from | Defined in |
41
+ | ------ | ------ | ------ | ------ | ------ | ------ | ------ |
42
+ | <a id="property-cause"></a> `cause?` | `public` | `unknown` | `undefined` | - | [`SiteError`](SiteError.md).[`cause`](SiteError.md#property-cause) | - |
43
+ | <a id="property-code"></a> `code` | `readonly` | `string` | `undefined` | - | [`SiteError`](SiteError.md).[`code`](SiteError.md#property-code) | [packages/project-astro/src/errors.ts:17](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L17) |
44
+ | <a id="property-exitcode"></a> `exitCode` | `readonly` | `number` | `1` | What a command that fails by it exits with. | [`SiteError`](SiteError.md).[`exitCode`](SiteError.md#property-exitcode) | [packages/project-astro/src/errors.ts:19](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L19) |
45
+ | <a id="property-message"></a> `message` | `public` | `string` | `undefined` | - | [`SiteError`](SiteError.md).[`message`](SiteError.md#property-message) | - |
46
+ | <a id="property-name"></a> `name` | `public` | `string` | `undefined` | - | [`SiteError`](SiteError.md).[`name`](SiteError.md#property-name) | - |
47
+ | <a id="property-reason"></a> `reason` | `readonly` | `string` | `undefined` | Why GitLab Pages would ignore it. | - | [packages/project-astro/src/errors.ts:68](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L68) |
48
+ | <a id="property-rule"></a> `rule` | `readonly` | `string` | `undefined` | The rule, as a line of the file, or what is too much of the file. | - | [packages/project-astro/src/errors.ts:66](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L66) |
49
+ | <a id="property-stack"></a> `stack?` | `public` | `string` | `undefined` | - | [`SiteError`](SiteError.md).[`stack`](SiteError.md#property-stack) | - |
50
+ | <a id="property-stacktracelimit"></a> `stackTraceLimit` | `static` | `number` | `undefined` | The `Error.stackTraceLimit` property specifies the number of stack frames collected by a stack trace (whether generated by `new Error().stack` or `Error.captureStackTrace(obj)`). The default value is `10` but may be set to any valid JavaScript number. Changes will affect any stack trace captured _after_ the value has been changed. If set to a non-number value, or set to a negative number, stack traces will not capture any frames. | [`SiteError`](SiteError.md).[`stackTraceLimit`](SiteError.md#property-stacktracelimit) | - |
51
+
52
+ ## Methods
53
+
54
+ ### captureStackTrace()
55
+
56
+ ```ts
57
+ static captureStackTrace(targetObject, constructorOpt?): void;
58
+ ```
59
+
60
+ Defined in: `@types/node`
61
+
62
+ Creates a `.stack` property on `targetObject`, which when accessed returns
63
+ a string representing the location in the code at which
64
+ `Error.captureStackTrace()` was called.
65
+
66
+ ```js
67
+ const myObject = {};
68
+ Error.captureStackTrace(myObject);
69
+ myObject.stack; // Similar to `new Error().stack`
70
+ ```
71
+
72
+ The first line of the trace will be prefixed with
73
+ `${myObject.name}: ${myObject.message}`.
74
+
75
+ The optional `constructorOpt` argument accepts a function. If given, all frames
76
+ above `constructorOpt`, including `constructorOpt`, will be omitted from the
77
+ generated stack trace.
78
+
79
+ The `constructorOpt` argument is useful for hiding implementation
80
+ details of error generation from the user. For instance:
81
+
82
+ ```js
83
+ function a() {
84
+ b();
85
+ }
86
+
87
+ function b() {
88
+ c();
89
+ }
90
+
91
+ function c() {
92
+ // Create an error without stack trace to avoid calculating the stack trace twice.
93
+ const { stackTraceLimit } = Error;
94
+ Error.stackTraceLimit = 0;
95
+ const error = new Error();
96
+ Error.stackTraceLimit = stackTraceLimit;
97
+
98
+ // Capture the stack trace above function b
99
+ Error.captureStackTrace(error, b); // Neither function c, nor b is included in the stack trace
100
+ throw error;
101
+ }
102
+
103
+ a();
104
+ ```
105
+
106
+ #### Parameters
107
+
108
+ | Parameter | Type |
109
+ | ------ | ------ |
110
+ | `targetObject` | `object` |
111
+ | `constructorOpt?` | `Function` |
112
+
113
+ #### Returns
114
+
115
+ `void`
116
+
117
+ #### Inherited from
118
+
119
+ [`SiteError`](SiteError.md).[`captureStackTrace`](SiteError.md#capturestacktrace)
120
+
121
+ ***
122
+
123
+ ### isError()
124
+
125
+ ```ts
126
+ static isError(error): error is Error;
127
+ ```
128
+
129
+ Defined in: `typescript`
130
+
131
+ Indicates whether the argument provided is a built-in Error instance or not.
132
+
133
+ #### Parameters
134
+
135
+ | Parameter | Type |
136
+ | ------ | ------ |
137
+ | `error` | `unknown` |
138
+
139
+ #### Returns
140
+
141
+ `error is Error`
142
+
143
+ #### Inherited from
144
+
145
+ [`SiteError`](SiteError.md).[`isError`](SiteError.md#iserror)
146
+
147
+ ***
148
+
149
+ ### prepareStackTrace()
150
+
151
+ ```ts
152
+ static prepareStackTrace(err, stackTraces): any;
153
+ ```
154
+
155
+ Defined in: `@types/node`
156
+
157
+ #### Parameters
158
+
159
+ | Parameter | Type |
160
+ | ------ | ------ |
161
+ | `err` | `Error` |
162
+ | `stackTraces` | `CallSite`[] |
163
+
164
+ #### Returns
165
+
166
+ `any`
167
+
168
+ #### See
169
+
170
+ https://v8.dev/docs/stack-trace-api#customizing-stack-traces
171
+
172
+ #### Inherited from
173
+
174
+ [`SiteError`](SiteError.md).[`prepareStackTrace`](SiteError.md#preparestacktrace)
@@ -0,0 +1,173 @@
1
+ [Documentation](../../../../README.md) / [@wtf/project-astro](../../README.md) / [errors](../README.md) / RedirectedLinksError
2
+
3
+ # Class: RedirectedLinksError
4
+
5
+ Defined in: [packages/project-astro/src/errors.ts:48](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L48)
6
+
7
+ Each internal link of a build that leads to its page only through a redirect, which costs each
8
+ reader a round trip: link to where it leads instead.
9
+
10
+ ## Extends
11
+
12
+ - [`SiteError`](SiteError.md)
13
+
14
+ ## Constructors
15
+
16
+ ### Constructor
17
+
18
+ ```ts
19
+ new RedirectedLinksError(links): RedirectedLinksError;
20
+ ```
21
+
22
+ Defined in: [packages/project-astro/src/errors.ts:52](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L52)
23
+
24
+ #### Parameters
25
+
26
+ | Parameter | Type |
27
+ | ------ | ------ |
28
+ | `links` | readonly [`RedirectedLink`](../../index/type-aliases/RedirectedLink.md)[] |
29
+
30
+ #### Returns
31
+
32
+ `RedirectedLinksError`
33
+
34
+ #### Overrides
35
+
36
+ [`SiteError`](SiteError.md).[`constructor`](SiteError.md#constructor)
37
+
38
+ ## Properties
39
+
40
+ | Property | Modifier | Type | Default value | Description | Inherited from | Defined in |
41
+ | ------ | ------ | ------ | ------ | ------ | ------ | ------ |
42
+ | <a id="property-cause"></a> `cause?` | `public` | `unknown` | `undefined` | - | [`SiteError`](SiteError.md).[`cause`](SiteError.md#property-cause) | - |
43
+ | <a id="property-code"></a> `code` | `readonly` | `string` | `undefined` | - | [`SiteError`](SiteError.md).[`code`](SiteError.md#property-code) | [packages/project-astro/src/errors.ts:17](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L17) |
44
+ | <a id="property-exitcode"></a> `exitCode` | `readonly` | `number` | `1` | What a command that fails by it exits with. | [`SiteError`](SiteError.md).[`exitCode`](SiteError.md#property-exitcode) | [packages/project-astro/src/errors.ts:19](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L19) |
45
+ | <a id="property-links"></a> `links` | `readonly` | readonly [`RedirectedLink`](../../index/type-aliases/RedirectedLink.md)[] | `undefined` | The links, each with its page and where it leads. | - | [packages/project-astro/src/errors.ts:50](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L50) |
46
+ | <a id="property-message"></a> `message` | `public` | `string` | `undefined` | - | [`SiteError`](SiteError.md).[`message`](SiteError.md#property-message) | - |
47
+ | <a id="property-name"></a> `name` | `public` | `string` | `undefined` | - | [`SiteError`](SiteError.md).[`name`](SiteError.md#property-name) | - |
48
+ | <a id="property-stack"></a> `stack?` | `public` | `string` | `undefined` | - | [`SiteError`](SiteError.md).[`stack`](SiteError.md#property-stack) | - |
49
+ | <a id="property-stacktracelimit"></a> `stackTraceLimit` | `static` | `number` | `undefined` | The `Error.stackTraceLimit` property specifies the number of stack frames collected by a stack trace (whether generated by `new Error().stack` or `Error.captureStackTrace(obj)`). The default value is `10` but may be set to any valid JavaScript number. Changes will affect any stack trace captured _after_ the value has been changed. If set to a non-number value, or set to a negative number, stack traces will not capture any frames. | [`SiteError`](SiteError.md).[`stackTraceLimit`](SiteError.md#property-stacktracelimit) | - |
50
+
51
+ ## Methods
52
+
53
+ ### captureStackTrace()
54
+
55
+ ```ts
56
+ static captureStackTrace(targetObject, constructorOpt?): void;
57
+ ```
58
+
59
+ Defined in: `@types/node`
60
+
61
+ Creates a `.stack` property on `targetObject`, which when accessed returns
62
+ a string representing the location in the code at which
63
+ `Error.captureStackTrace()` was called.
64
+
65
+ ```js
66
+ const myObject = {};
67
+ Error.captureStackTrace(myObject);
68
+ myObject.stack; // Similar to `new Error().stack`
69
+ ```
70
+
71
+ The first line of the trace will be prefixed with
72
+ `${myObject.name}: ${myObject.message}`.
73
+
74
+ The optional `constructorOpt` argument accepts a function. If given, all frames
75
+ above `constructorOpt`, including `constructorOpt`, will be omitted from the
76
+ generated stack trace.
77
+
78
+ The `constructorOpt` argument is useful for hiding implementation
79
+ details of error generation from the user. For instance:
80
+
81
+ ```js
82
+ function a() {
83
+ b();
84
+ }
85
+
86
+ function b() {
87
+ c();
88
+ }
89
+
90
+ function c() {
91
+ // Create an error without stack trace to avoid calculating the stack trace twice.
92
+ const { stackTraceLimit } = Error;
93
+ Error.stackTraceLimit = 0;
94
+ const error = new Error();
95
+ Error.stackTraceLimit = stackTraceLimit;
96
+
97
+ // Capture the stack trace above function b
98
+ Error.captureStackTrace(error, b); // Neither function c, nor b is included in the stack trace
99
+ throw error;
100
+ }
101
+
102
+ a();
103
+ ```
104
+
105
+ #### Parameters
106
+
107
+ | Parameter | Type |
108
+ | ------ | ------ |
109
+ | `targetObject` | `object` |
110
+ | `constructorOpt?` | `Function` |
111
+
112
+ #### Returns
113
+
114
+ `void`
115
+
116
+ #### Inherited from
117
+
118
+ [`SiteError`](SiteError.md).[`captureStackTrace`](SiteError.md#capturestacktrace)
119
+
120
+ ***
121
+
122
+ ### isError()
123
+
124
+ ```ts
125
+ static isError(error): error is Error;
126
+ ```
127
+
128
+ Defined in: `typescript`
129
+
130
+ Indicates whether the argument provided is a built-in Error instance or not.
131
+
132
+ #### Parameters
133
+
134
+ | Parameter | Type |
135
+ | ------ | ------ |
136
+ | `error` | `unknown` |
137
+
138
+ #### Returns
139
+
140
+ `error is Error`
141
+
142
+ #### Inherited from
143
+
144
+ [`SiteError`](SiteError.md).[`isError`](SiteError.md#iserror)
145
+
146
+ ***
147
+
148
+ ### prepareStackTrace()
149
+
150
+ ```ts
151
+ static prepareStackTrace(err, stackTraces): any;
152
+ ```
153
+
154
+ Defined in: `@types/node`
155
+
156
+ #### Parameters
157
+
158
+ | Parameter | Type |
159
+ | ------ | ------ |
160
+ | `err` | `Error` |
161
+ | `stackTraces` | `CallSite`[] |
162
+
163
+ #### Returns
164
+
165
+ `any`
166
+
167
+ #### See
168
+
169
+ https://v8.dev/docs/stack-trace-api#customizing-stack-traces
170
+
171
+ #### Inherited from
172
+
173
+ [`SiteError`](SiteError.md).[`prepareStackTrace`](SiteError.md#preparestacktrace)
@@ -0,0 +1,192 @@
1
+ [Documentation](../../../../README.md) / [@wtf/project-astro](../../README.md) / [errors](../README.md) / SiteError
2
+
3
+ # Class: SiteError
4
+
5
+ Defined in: [packages/project-astro/src/errors.ts:16](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L16)
6
+
7
+ What this package throws: an Error with a stable SCREAMING_SNAKE `code` to match on in place of
8
+ its message, and the `exitCode` a command that fails by it exits with, 1.
9
+
10
+ ## Extends
11
+
12
+ - `Error`
13
+
14
+ ## Extended by
15
+
16
+ - [`BrokenLinksError`](BrokenLinksError.md)
17
+ - [`RedirectedLinksError`](RedirectedLinksError.md)
18
+ - [`InvalidRedirectError`](InvalidRedirectError.md)
19
+
20
+ ## Constructors
21
+
22
+ ### Constructor
23
+
24
+ ```ts
25
+ new SiteError(
26
+ code,
27
+ message,
28
+ options?
29
+ ): SiteError;
30
+ ```
31
+
32
+ Defined in: [packages/project-astro/src/errors.ts:21](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L21)
33
+
34
+ #### Parameters
35
+
36
+ | Parameter | Type |
37
+ | ------ | ------ |
38
+ | `code` | `string` |
39
+ | `message` | `string` |
40
+ | `options?` | `ErrorOptions` |
41
+
42
+ #### Returns
43
+
44
+ `SiteError`
45
+
46
+ #### Overrides
47
+
48
+ ```ts
49
+ Error.constructor
50
+ ```
51
+
52
+ ## Properties
53
+
54
+ | Property | Modifier | Type | Default value | Description | Inherited from | Defined in |
55
+ | ------ | ------ | ------ | ------ | ------ | ------ | ------ |
56
+ | <a id="property-cause"></a> `cause?` | `public` | `unknown` | `undefined` | - | `Error.cause` | - |
57
+ | <a id="property-code"></a> `code` | `readonly` | `string` | `undefined` | - | - | [packages/project-astro/src/errors.ts:17](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L17) |
58
+ | <a id="property-exitcode"></a> `exitCode` | `readonly` | `number` | `1` | What a command that fails by it exits with. | - | [packages/project-astro/src/errors.ts:19](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/errors.ts#L19) |
59
+ | <a id="property-message"></a> `message` | `public` | `string` | `undefined` | - | `Error.message` | - |
60
+ | <a id="property-name"></a> `name` | `public` | `string` | `undefined` | - | `Error.name` | - |
61
+ | <a id="property-stack"></a> `stack?` | `public` | `string` | `undefined` | - | `Error.stack` | - |
62
+ | <a id="property-stacktracelimit"></a> `stackTraceLimit` | `static` | `number` | `undefined` | The `Error.stackTraceLimit` property specifies the number of stack frames collected by a stack trace (whether generated by `new Error().stack` or `Error.captureStackTrace(obj)`). The default value is `10` but may be set to any valid JavaScript number. Changes will affect any stack trace captured _after_ the value has been changed. If set to a non-number value, or set to a negative number, stack traces will not capture any frames. | `Error.stackTraceLimit` | - |
63
+
64
+ ## Methods
65
+
66
+ ### captureStackTrace()
67
+
68
+ ```ts
69
+ static captureStackTrace(targetObject, constructorOpt?): void;
70
+ ```
71
+
72
+ Defined in: `@types/node`
73
+
74
+ Creates a `.stack` property on `targetObject`, which when accessed returns
75
+ a string representing the location in the code at which
76
+ `Error.captureStackTrace()` was called.
77
+
78
+ ```js
79
+ const myObject = {};
80
+ Error.captureStackTrace(myObject);
81
+ myObject.stack; // Similar to `new Error().stack`
82
+ ```
83
+
84
+ The first line of the trace will be prefixed with
85
+ `${myObject.name}: ${myObject.message}`.
86
+
87
+ The optional `constructorOpt` argument accepts a function. If given, all frames
88
+ above `constructorOpt`, including `constructorOpt`, will be omitted from the
89
+ generated stack trace.
90
+
91
+ The `constructorOpt` argument is useful for hiding implementation
92
+ details of error generation from the user. For instance:
93
+
94
+ ```js
95
+ function a() {
96
+ b();
97
+ }
98
+
99
+ function b() {
100
+ c();
101
+ }
102
+
103
+ function c() {
104
+ // Create an error without stack trace to avoid calculating the stack trace twice.
105
+ const { stackTraceLimit } = Error;
106
+ Error.stackTraceLimit = 0;
107
+ const error = new Error();
108
+ Error.stackTraceLimit = stackTraceLimit;
109
+
110
+ // Capture the stack trace above function b
111
+ Error.captureStackTrace(error, b); // Neither function c, nor b is included in the stack trace
112
+ throw error;
113
+ }
114
+
115
+ a();
116
+ ```
117
+
118
+ #### Parameters
119
+
120
+ | Parameter | Type |
121
+ | ------ | ------ |
122
+ | `targetObject` | `object` |
123
+ | `constructorOpt?` | `Function` |
124
+
125
+ #### Returns
126
+
127
+ `void`
128
+
129
+ #### Inherited from
130
+
131
+ ```ts
132
+ Error.captureStackTrace
133
+ ```
134
+
135
+ ***
136
+
137
+ ### isError()
138
+
139
+ ```ts
140
+ static isError(error): error is Error;
141
+ ```
142
+
143
+ Defined in: `typescript`
144
+
145
+ Indicates whether the argument provided is a built-in Error instance or not.
146
+
147
+ #### Parameters
148
+
149
+ | Parameter | Type |
150
+ | ------ | ------ |
151
+ | `error` | `unknown` |
152
+
153
+ #### Returns
154
+
155
+ `error is Error`
156
+
157
+ #### Inherited from
158
+
159
+ ```ts
160
+ Error.isError
161
+ ```
162
+
163
+ ***
164
+
165
+ ### prepareStackTrace()
166
+
167
+ ```ts
168
+ static prepareStackTrace(err, stackTraces): any;
169
+ ```
170
+
171
+ Defined in: `@types/node`
172
+
173
+ #### Parameters
174
+
175
+ | Parameter | Type |
176
+ | ------ | ------ |
177
+ | `err` | `Error` |
178
+ | `stackTraces` | `CallSite`[] |
179
+
180
+ #### Returns
181
+
182
+ `any`
183
+
184
+ #### See
185
+
186
+ https://v8.dev/docs/stack-trace-api#customizing-stack-traces
187
+
188
+ #### Inherited from
189
+
190
+ ```ts
191
+ Error.prepareStackTrace
192
+ ```
@@ -0,0 +1,19 @@
1
+ [Documentation](../../../README.md) / [@wtf/project-astro](../README.md) / index
2
+
3
+ # index
4
+
5
+ The types of `@wtf/project-astro`: the rules of a `_redirects` file ([RedirectRule](type-aliases/RedirectRule.md),
6
+ [IgnoredLine](type-aliases/IgnoredLine.md), [Redirects](type-aliases/Redirects.md), [RedirectMatch](type-aliases/RedirectMatch.md)), and the links of a built site
7
+ that lead to no page, or only through a redirect ([BrokenLink](type-aliases/BrokenLink.md), [RedirectedLink](type-aliases/RedirectedLink.md)).
8
+ Types only, with no code.
9
+
10
+ ## Type Aliases
11
+
12
+ - [BrokenLink](type-aliases/BrokenLink.md)
13
+ - [IgnoredLine](type-aliases/IgnoredLine.md)
14
+ - [RedirectedLink](type-aliases/RedirectedLink.md)
15
+ - [RedirectInput](type-aliases/RedirectInput.md)
16
+ - [RedirectMatch](type-aliases/RedirectMatch.md)
17
+ - [RedirectRule](type-aliases/RedirectRule.md)
18
+ - [Redirects](type-aliases/Redirects.md)
19
+ - [RedirectStatus](type-aliases/RedirectStatus.md)
@@ -0,0 +1,35 @@
1
+ [Documentation](../../../../README.md) / [@wtf/project-astro](../../README.md) / [index](../README.md) / BrokenLink
2
+
3
+ # Type Alias: BrokenLink
4
+
5
+ ```ts
6
+ type BrokenLink = object;
7
+ ```
8
+
9
+ Defined in: [packages/project-astro/src/index.ts:66](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/index.ts#L66)
10
+
11
+ An internal link of a built page that leads to no page.
12
+
13
+ ## Properties
14
+
15
+ ### href
16
+
17
+ ```ts
18
+ readonly href: string;
19
+ ```
20
+
21
+ Defined in: [packages/project-astro/src/index.ts:70](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/index.ts#L70)
22
+
23
+ The link, as the page's `href` writes it.
24
+
25
+ ***
26
+
27
+ ### page
28
+
29
+ ```ts
30
+ readonly page: string;
31
+ ```
32
+
33
+ Defined in: [packages/project-astro/src/index.ts:68](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/index.ts#L68)
34
+
35
+ The page, from the folder of the build, such as `/en/blog/hello.html`.
@@ -0,0 +1,47 @@
1
+ [Documentation](../../../../README.md) / [@wtf/project-astro](../../README.md) / [index](../README.md) / IgnoredLine
2
+
3
+ # Type Alias: IgnoredLine
4
+
5
+ ```ts
6
+ type IgnoredLine = object;
7
+ ```
8
+
9
+ Defined in: [packages/project-astro/src/index.ts:40](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/index.ts#L40)
10
+
11
+ A line of a `_redirects` file that is no rule GitLab Pages supports, and why.
12
+
13
+ ## Properties
14
+
15
+ ### line
16
+
17
+ ```ts
18
+ readonly line: number;
19
+ ```
20
+
21
+ Defined in: [packages/project-astro/src/index.ts:42](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/index.ts#L42)
22
+
23
+ The line, from 1; `0` for the whole file.
24
+
25
+ ***
26
+
27
+ ### reason
28
+
29
+ ```ts
30
+ readonly reason: string;
31
+ ```
32
+
33
+ Defined in: [packages/project-astro/src/index.ts:46](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/index.ts#L46)
34
+
35
+ Why GitLab Pages ignores it, and what it supports instead.
36
+
37
+ ***
38
+
39
+ ### text
40
+
41
+ ```ts
42
+ readonly text: string;
43
+ ```
44
+
45
+ Defined in: [packages/project-astro/src/index.ts:44](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/index.ts#L44)
46
+
47
+ The text of the line, trimmed; empty for the whole file.
@@ -0,0 +1,17 @@
1
+ [Documentation](../../../../README.md) / [@wtf/project-astro](../../README.md) / [index](../README.md) / RedirectInput
2
+
3
+ # Type Alias: RedirectInput
4
+
5
+ ```ts
6
+ type RedirectInput = Pick<RedirectRule, "from" | "to"> & object;
7
+ ```
8
+
9
+ Defined in: [packages/project-astro/src/index.ts:34](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/index.ts#L34)
10
+
11
+ A rule to write into a `_redirects` file: its status `301` by default, and of no line.
12
+
13
+ ## Type Declaration
14
+
15
+ | Name | Type | Description | Defined in |
16
+ | ------ | ------ | ------ | ------ |
17
+ | `status?` | [`RedirectStatus`](RedirectStatus.md) | What the rule answers with: `301` by default, as GitLab Pages reads a rule of none. | [packages/project-astro/src/index.ts:36](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/index.ts#L36) |
@@ -0,0 +1,35 @@
1
+ [Documentation](../../../../README.md) / [@wtf/project-astro](../../README.md) / [index](../README.md) / RedirectMatch
2
+
3
+ # Type Alias: RedirectMatch
4
+
5
+ ```ts
6
+ type RedirectMatch = object;
7
+ ```
8
+
9
+ Defined in: [packages/project-astro/src/index.ts:58](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/index.ts#L58)
10
+
11
+ The rule of `_redirects` that answers a path, and where it sends it.
12
+
13
+ ## Properties
14
+
15
+ ### location
16
+
17
+ ```ts
18
+ readonly location: string;
19
+ ```
20
+
21
+ Defined in: [packages/project-astro/src/index.ts:62](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/index.ts#L62)
22
+
23
+ The rule's `to`, its placeholders and `:splat` put in: the `Location` of a redirect.
24
+
25
+ ***
26
+
27
+ ### rule
28
+
29
+ ```ts
30
+ readonly rule: RedirectRule;
31
+ ```
32
+
33
+ Defined in: [packages/project-astro/src/index.ts:60](https://gitlab.com/wetryfun/project/project/-/blob/docs-v1.1.0/packages/project-astro/src/index.ts#L60)
34
+
35
+ The first rule whose path matches.