Skip to content

build(deps): bump usehooks-ts from 2.9.1 to 3.1.1 #2333

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -116,7 +116,7 @@
"two.js": "^0.8.12",
"typed-redux-saga": "^1.5.0",
"typescript": "~4.9.5",
"usehooks-ts": "^2.9.1",
"usehooks-ts": "^3.1.1",
"user-agent-data-types": "^0.4.2",
"web-vitals": "^3.5.2",
"webpack": "^5.90.0",
15 changes: 8 additions & 7 deletions yarn.lock
Original file line number Diff line number Diff line change
@@ -3092,7 +3092,7 @@ __metadata:
two.js: ^0.8.12
typed-redux-saga: ^1.5.0
typescript: ~4.9.5
usehooks-ts: ^2.9.1
usehooks-ts: ^3.1.1
user-agent-data-types: ^0.4.2
web-vitals: ^3.5.2
webpack: ^5.90.0
@@ -16989,13 +16989,14 @@ __metadata:
languageName: node
linkType: hard

"usehooks-ts@npm:^2.9.1":
version: 2.9.1
resolution: "usehooks-ts@npm:2.9.1"
"usehooks-ts@npm:^3.1.1":
version: 3.1.1
resolution: "usehooks-ts@npm:3.1.1"
dependencies:
lodash.debounce: ^4.0.8
peerDependencies:
react: ^16.8.0 || ^17.0.0 || ^18.0.0
react-dom: ^16.8.0 || ^17.0.0 || ^18.0.0
checksum: 36f1e4142ce23bc019b81d2e93aefd7f2c350abcf255598c21627114a69a2f2f116b35dc3a353375f09c6e4c9b704a04f104e3d10e98280545c097feca66c30a
react: ^16.8.0 || ^17 || ^18 || ^19 || ^19.0.0-rc
checksum: ecc8a678f7f08b1e8caaeeb4601b1cd32709e30f73db65441d09808a5f1488f8d2c38a5bc908aa0c67b6dc35379e4b6b7bcd581df57845f91ab6d95256d765ca
languageName: node
linkType: hard


Unchanged files with check annotations Beta

);
// avoid test environment errors by providing fixed response to useFetch()
jest.spyOn(useHooks, 'useFetch').mockImplementation(() => ({}));

Check failure on line 30 in src/about/AboutDialog.test.tsx

GitHub Actions / test

No overload matches this call.

Check failure on line 30 in src/about/AboutDialog.test.tsx

GitHub Actions / test

Property 'mockImplementation' does not exist on type 'never'.
expect(
dialog.queryByRole('dialog', { name: 'Open Source Software Licenses' }),
// Copyright (c) 2022 The Pybricks Authors
import { useEffect } from 'react';
import { useEffectOnce, useLocalStorage, useSessionStorage } from 'usehooks-ts';

Check failure on line 5 in src/activities/hooks.ts

GitHub Actions / test

Module '"usehooks-ts"' has no exported member 'useEffectOnce'.
/** Indicates the selected activity. */
export enum Activity {
setLastSelectedActivity(selectedActivity);
}, [selectedActivity, setLastSelectedActivity]);
return [selectedActivity, setSelectedActivity];

Check failure on line 44 in src/activities/hooks.ts

GitHub Actions / test

Type '[Activity, Dispatch<SetStateAction<Activity>>]' is not assignable to type '[Activity, Dispatch<SetStateAction<Activity>>, () => void]'.
}
import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react';
import { useId } from 'react-aria';
import { useDispatch } from 'react-redux';
import { useEffectOnce, useTernaryDarkMode } from 'usehooks-ts';

Check failure on line 35 in src/editor/Editor.tsx

GitHub Actions / test

Module '"usehooks-ts"' has no exported member 'useEffectOnce'.
import { UUID } from '../fileStorage';
import { useFileStoragePath } from '../fileStorage/hooks';
import { compile } from '../mpy/actions';
beforeEach(() => {
// avoid test environment errors by providing fixed response to useFetch()
jest.spyOn(useHooks, 'useFetch').mockImplementation(() => ({

Check failure on line 13 in src/licenses/LicenseDialog.test.tsx

GitHub Actions / test

No overload matches this call.

Check failure on line 13 in src/licenses/LicenseDialog.test.tsx

GitHub Actions / test

Property 'mockImplementation' does not exist on type 'never'.
data: [
{
name: 'super-duper',
import classNames from 'classnames';
import React, { useCallback, useState } from 'react';
import { mergeProps, useFocusRing, useListBox, useOption } from 'react-aria';
import { useFetch } from 'usehooks-ts';

Check failure on line 24 in src/licenses/LicenseDialog.tsx

GitHub Actions / test

Module '"usehooks-ts"' has no exported member 'useFetch'.
import { appName } from '../app/constants';
import { useI18n } from './i18n';
return;
}
onItemSelected(data.find((item) => keys.has(item.name)));

Check failure on line 154 in src/licenses/LicenseDialog.tsx

GitHub Actions / test

Parameter 'item' implicitly has an 'any' type.
},
[data, onItemSelected],
);
// Copyright (c) 2022 The Pybricks Authors
import { useCallback, useEffect } from 'react';
import { useEffectOnce, useLocalStorage, useSessionStorage } from 'usehooks-ts';

Check failure on line 5 in src/settings/hooks.ts

GitHub Actions / test

Module '"usehooks-ts"' has no exported member 'useEffectOnce'.
/** Hook for "showDocs" setting. */
export function useSettingIsShowDocsEnabled(): {