Skip to content

Commit 37cb59b

Browse files
authored
Merge pull request #1581 from City-of-Helsinki/HDS-2882-fix-useTokenizedFetch-export
fix: add missing hooks' exports from TokenizedFetchModule
2 parents ee93bd6 + 3c5cd6a commit 37cb59b

File tree

4 files changed

+6
-4
lines changed

4 files changed

+6
-4
lines changed

CHANGELOG.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8-
## [4.10.0] - Month, XX, 202X
8+
## [4.10.0] - January, XX, 2026
99

1010
### React
1111

@@ -25,7 +25,7 @@ Changes that are not related to specific components
2525

2626
#### Fixed
2727

28-
- [Component] What bugs/typos are fixed?
28+
- [Login] Fixed missing export for `useTokenizedFetch` and related hooks (`useTokenizedFetchModule`, `useTokenizedFetchWithSignals`, `useTokenizedFetchTracking`, `useTokenizedFetchResponseTracking`) in the build output. These hooks are now properly exported and available when importing from `hds-react`.
2929

3030
#### Deprecated
3131

@@ -73,6 +73,7 @@ Changes that are not related to specific components
7373

7474
- [Component] What bugs/typos are fixed?
7575
- [Checkbox] Stories to include full interactivities.
76+
- [Login] Fixed incorrect hook name in documentation: `useTokenizedFetchModuleTracking` should be `useTokenizedFetchTracking`.
7677

7778
### Figma
7879

packages/react/src/components/login/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ export * from './apiTokensClient/hooks';
1515
export * from './sessionPoller/hooks';
1616
export * from './graphQLModule/hooks';
1717
export * from './apolloClient/hooks';
18+
export * from './tokenizedFetch/hooks';
1819

1920
// vanilla js code
2021
export * from './index.vanilla-js';

site/src/docs/components/login/api.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -999,7 +999,7 @@ The usage of the `ApolloClient module` hooks is described in the <UsagePageAncho
999999
| --------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------- |
10001000
| `useTokenizedFetchModule` | Returns the `TokenizedFetch module`. | `TokenizedFetch` |
10011001
| `useTokenizedFetch` | Returns a function identical to the native `fetch` function.. | The native `fetch` function |
1002-
| `useTokenizedFetchModuleTracking` | Returns `[Signal, resetFunction, TokenizedFetch module instance]`. The hook forces the component using it to re-render each time the listener is triggered. | `[signal, reset function, TokenizedFetch module instance]` |
1002+
| `useTokenizedFetchTracking` | Returns `[Signal, resetFunction, TokenizedFetch module instance]`. The hook forces the component using it to re-render each time the listener is triggered. | `[signal, reset function, TokenizedFetch module instance]` |
10031003
| `useTokenizedFetchWithSignals` | This hook works just like the `useTokenizedFetch` except it emits signals so individual fetches can be tracked. | `Promise<Response>` |
10041004
| `useTokenizedFetchResponseTracking` | This hook works just like the `useTokenizedFetchModuleTracking` except it tracks only signals emitted by the module **and** with given identifier. | `Signal` |
10051005
| [Table 61: TokenizedFetch module hooks] |

site/src/docs/components/login/usage.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -484,7 +484,7 @@ More detailed information about <AnchorLink>TokenizedFetch module</AnchorLink> h
484484

485485
Returns the <AnchorLink>TokenizedFetch module</AnchorLink>.
486486

487-
#### useTokenizedFetchModuleTracking
487+
#### useTokenizedFetchTracking
488488

489489
Returns an array of `[signal, reset function, TokenizedFetch module instance]`. The hook re-renders the component each time the module emits a signal.
490490

0 commit comments

Comments
 (0)