Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

move hook documentation (and others) into code, improve documentation components #11381

Merged
merged 69 commits into from
Jan 24, 2024
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
Show all changes
69 commits
Select commit Hold shift + click to select a range
a844cf4
move some docs to comments
phryneas Nov 22, 2023
cbb91f6
remove comments
phryneas Nov 22, 2023
fc6b0c1
fix missing space
phryneas Nov 22, 2023
ca5d76d
add api_doc
phryneas Nov 22, 2023
f78cdbf
tweak in file generation
phryneas Nov 27, 2023
ac0b4fe
build from docs branch
phryneas Nov 27, 2023
b47f8d2
switch docs branch back to `main`
phryneas Nov 27, 2023
f31b00a
Merge branch 'main' into pr/migrate-docs-to-docblocks-1
phryneas Jan 8, 2024
a7232d3
bump CI
phryneas Jan 8, 2024
9267869
Enum & PropertyDetails
phryneas Jan 9, 2024
1ff652c
WIP - see current state of `hooks.mdx`
phryneas Jan 10, 2024
daf8d70
Merge remote-tracking branch 'origin/release-3.9' into pr/migrate-doc…
phryneas Jan 11, 2024
528961c
completely remove `query-options` and `query-result` mdx
phryneas Jan 11, 2024
f647f8d
useMutation
phryneas Jan 11, 2024
41c6f4d
handle subscription docs
phryneas Jan 11, 2024
1ee952f
better function signature
phryneas Jan 11, 2024
680ebfd
more hooks
phryneas Jan 11, 2024
d34aff0
fix up import
phryneas Jan 11, 2024
d6fdad4
chores
phryneas Jan 12, 2024
a026cb6
formatting
phryneas Jan 12, 2024
4a1a7ad
suppress tsdoc warning
phryneas Jan 12, 2024
b784bd2
api explorer nitpicks
phryneas Jan 12, 2024
4581e67
support for @deprecated
phryneas Jan 16, 2024
19702dc
use prerendered markdown in comments
phryneas Jan 16, 2024
c5a6801
add propTypes
phryneas Jan 16, 2024
6b631f1
apply prettier
phryneas Jan 16, 2024
b45c1b6
fixup
phryneas Jan 16, 2024
2100454
also display interface details for slightly complex types
phryneas Jan 17, 2024
b33beaa
heading styling, do not use h6
phryneas Jan 17, 2024
117118c
since everywhere, styling, `link` defaults
phryneas Jan 17, 2024
312c074
add grouping, create documentation interface
phryneas Jan 18, 2024
088cbf7
`MutationOptionsDocumentation` interface
phryneas Jan 18, 2024
eb3b71f
api reports
phryneas Jan 18, 2024
f799df3
subscription options
phryneas Jan 18, 2024
a35b90f
api repots
phryneas Jan 18, 2024
f3f42bb
prettier
phryneas Jan 18, 2024
89f81a2
fix some references
phryneas Jan 18, 2024
7b92cf6
cleanup
phryneas Jan 18, 2024
e988341
fix up SubHeading links
phryneas Jan 18, 2024
c4cb277
don't add prefix to parameter properties
phryneas Jan 18, 2024
99b4b22
allow property deep linking
phryneas Jan 18, 2024
8f922a6
prettier
phryneas Jan 18, 2024
2e783d8
Merge remote-tracking branch 'origin/release-3.9' into pr/migrate-doc…
phryneas Jan 18, 2024
13b6480
more cleanup
phryneas Jan 18, 2024
b7241c2
also add result documentation
phryneas Jan 18, 2024
61e5d30
more doccomment work
phryneas Jan 18, 2024
1274a7e
fixup
phryneas Jan 18, 2024
ff19d5b
add missing import
phryneas Jan 18, 2024
2fd66e2
fixup
phryneas Jan 18, 2024
57c8526
remove `result` property (it's not a function)
phryneas Jan 18, 2024
c4c3a28
Revert "remove `result` property (it's not a function)"
phryneas Jan 18, 2024
1d05b70
functions adjustments
phryneas Jan 22, 2024
a4dbbb2
move heading out of example children
phryneas Jan 23, 2024
17c80aa
Update docs/shared/ApiDoc/EnumDetails.js
phryneas Jan 23, 2024
8510c18
remove obsolete props
phryneas Jan 23, 2024
119d3d9
address top padding for "smaller" headings
phryneas Jan 23, 2024
e91d070
review feedback
phryneas Jan 23, 2024
cf5a3e9
fixup codeblock
phryneas Jan 23, 2024
38afe2e
move `SourceLink` out of `Heading`
phryneas Jan 23, 2024
7938a5f
throw an error if both `as` and `headingLevel` are specified in `Head…
phryneas Jan 23, 2024
ec9e53d
move jsx
phryneas Jan 23, 2024
eb63d93
always link headings
phryneas Jan 23, 2024
9bab15c
move headings out of table components
phryneas Jan 23, 2024
23e463f
review comment
phryneas Jan 23, 2024
7bfd8d5
Update docs/shared/ApiDoc/Tuple.js
phryneas Jan 23, 2024
5a3a2fc
nit :)
phryneas Jan 23, 2024
c2c11f0
more updates
phryneas Jan 23, 2024
add09a1
fix link
phryneas Jan 24, 2024
81eab92
Merge branch 'release-3.9' into pr/migrate-docs-to-docblocks-1
phryneas Jan 24, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion docs/shared/apollo-provider.mdx

This file was deleted.

50 changes: 0 additions & 50 deletions docs/shared/document-transform-options.mdx

This file was deleted.

213 changes: 0 additions & 213 deletions docs/shared/useSuspenseQuery-options.mdx

This file was deleted.

22 changes: 11 additions & 11 deletions docs/source/api/core/ObservableQuery.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,18 @@ description: API reference

<TypescriptApiBox name="ObservableQuery.variables" />
jerelmiller marked this conversation as resolved.
Show resolved Hide resolved
<TypescriptApiBox name="ObservableQuery.result" />
phryneas marked this conversation as resolved.
Show resolved Hide resolved
<TypescriptApiBox name="ObservableQuery.getCurrentResult" />
<TypescriptApiBox name="ObservableQuery.refetch" />
<TypescriptApiBox name="ObservableQuery.setOptions" />
<TypescriptApiBox name="ObservableQuery.setVariables" />
<TypescriptApiBox name="ObservableQuery.fetchMore" />
<TypescriptApiBox name="ObservableQuery.updateQuery" />
<TypescriptApiBox name="ObservableQuery.startPolling" />
<TypescriptApiBox name="ObservableQuery.stopPolling" />
<TypescriptApiBox name="ObservableQuery.subscribeToMore" />
<FunctionDetails canonicalReference="@apollo/client!ObservableQuery#getCurrentResult:member(1)" />
<FunctionDetails canonicalReference="@apollo/client!ObservableQuery#refetch:member(1)" />
<FunctionDetails canonicalReference="@apollo/client!ObservableQuery#setOptions:member(1)" />
<FunctionDetails canonicalReference="@apollo/client!ObservableQuery#setVariables:member(1)" />
<FunctionDetails canonicalReference="@apollo/client!ObservableQuery#fetchMore:member(1)" />
<FunctionDetails canonicalReference="@apollo/client!ObservableQuery#updateQuery:member(1)" />
<FunctionDetails canonicalReference="@apollo/client!ObservableQuery#startPolling:member(1)" />
<FunctionDetails canonicalReference="@apollo/client!ObservableQuery#stopPolling:member(1)" />
<FunctionDetails canonicalReference="@apollo/client!ObservableQuery#subscribeToMore:member(1)" />


## Types

<TypescriptApiBox name="NetworkStatus" />
phryneas marked this conversation as resolved.
Show resolved Hide resolved
<TypescriptApiBox name="ApolloQueryResult" />
<TypescriptApiBox name="ApolloCurrentQueryResult" />
<InterfaceDetails canonicalReference="@apollo/client!ApolloQueryResult:interface" />
6 changes: 4 additions & 2 deletions docs/source/api/react/hooks.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ import SubscriptionOptions3 from '../../../shared/subscription-options.mdx';
import SubscriptionResult3 from '../../../shared/subscription-result.mdx';
import UseFragmentOptions from '../../../shared/useFragment-options.mdx';
import UseFragmentResult from '../../../shared/useFragment-result.mdx';
import UseSuspenseQueryOptions from '../../../shared/useSuspenseQuery-options.mdx';
import UseBackgroundQueryOptions from '../../../shared/useBackgroundQuery-options.mdx';
import UseSuspenseQueryResult from '../../../shared/useSuspenseQuery-result.mdx';
import UseBackgroundQueryResult from '../../../shared/useBackgroundQuery-result.mdx';
Expand Down Expand Up @@ -521,7 +520,10 @@ function useSuspenseQuery<TData, TVariables>(

Instead of passing a `SuspenseQueryHookOptions` object into the hook, you can also pass a [`skipToken`](#skiptoken) to prevent the `useSuspenseQuery` hook from executing the query or suspending.

<UseSuspenseQueryOptions />
<InterfaceDetails
canonicalReference="@apollo/client!SuspenseQueryHookOptions:interface"
customPropertyOrder={["variables", "errorPolicy", "skip"]}
/>

### Result

Expand Down
Loading
Loading