0
Fork 0
mirror of https://github.com/logto-io/logto.git synced 2025-03-31 22:51:25 -05:00

test(core): add cache tests

This commit is contained in:
Gao Sun 2023-04-07 17:41:22 +08:00
parent 1548e0732f
commit 45cc8f4fb0
No known key found for this signature in database
GPG key ID: 13EBE123E4773688
21 changed files with 380 additions and 149 deletions

View file

@ -90,6 +90,11 @@ jobs:
- name: Setup Postgres
uses: ikalnytskyi/action-setup-postgres@v4
- name: Setup Redis
uses: supercharge/redis-github-action@1.5.0
with:
redis-version: 6
- uses: actions/download-artifact@v3
with:
name: integration-test-${{ github.sha }}-${{ contains(matrix.target, 'cloud') && 'cloud' || 'oss' }}
@ -112,6 +117,8 @@ jobs:
- name: Run Logto
working-directory: logto/
run: nohup npm start > nohup.out 2> nohup.err < /dev/null &
env:
REDIS_URL: 1
- name: Run Logto Cloud
working-directory: logto/

View file

@ -31,7 +31,7 @@
"prepack": "pnpm build"
},
"devDependencies": {
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/ts-config": "3.0.0",
"@types/node": "^18.11.18",
"@types/react": "^18.0.31",

View file

@ -73,7 +73,7 @@
"zod": "^3.20.2"
},
"devDependencies": {
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/ts-config": "3.0.0",
"@types/inquirer": "^9.0.0",
"@types/jest": "^29.4.0",

View file

@ -44,7 +44,7 @@
"zod": "^3.20.2"
},
"devDependencies": {
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/jest-config": "3.0.0",
"@silverhand/ts-config": "3.0.0",
"@types/accepts": "^1.3.5",

View file

@ -34,7 +34,7 @@
"@rollup/plugin-json": "^6.0.0",
"@rollup/plugin-node-resolve": "^15.0.1",
"@rollup/plugin-typescript": "^10.0.1",
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/ts-config": "3.0.0",
"@types/jest": "^29.4.0",
"@types/node": "^18.11.18",

View file

@ -38,8 +38,8 @@
"@parcel/transformer-mdx": "2.8.3",
"@parcel/transformer-sass": "2.8.3",
"@parcel/transformer-svg-react": "2.8.3",
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config-react": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/eslint-config-react": "3.0.1",
"@silverhand/essentials": "^2.5.0",
"@silverhand/ts-config": "3.0.0",
"@silverhand/ts-config-react": "3.0.0",

View file

@ -81,7 +81,7 @@
"zod": "^3.20.2"
},
"devDependencies": {
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/ts-config": "3.0.0",
"@types/debug": "^4.1.7",
"@types/etag": "^1.8.1",

View file

@ -0,0 +1,67 @@
import { createMockUtils } from '@logto/shared/esm';
import Sinon from 'sinon';
import { EnvSet } from '#src/env-set/index.js';
const { jest } = import.meta;
const { mockEsm } = createMockUtils(jest);
const mockFunction = jest.fn();
mockEsm('redis', () => ({
createClient: () => ({
set: mockFunction,
get: mockFunction,
del: mockFunction,
connect: mockFunction,
disconnect: mockFunction,
on: mockFunction,
}),
}));
const { RedisCache } = await import('./index.js');
const stubRedisUrl = (url?: string) =>
Sinon.stub(EnvSet, 'values').value({
...EnvSet.values,
redisUrl: url,
});
describe('RedisCache', () => {
it('should successfully construct with no REDIS_URL', async () => {
stubRedisUrl();
const cache = new RedisCache();
expect(cache.client).toBeUndefined();
// Not to throw
await Promise.all([
cache.set('foo', 'bar'),
cache.get('foo'),
cache.delete('foo'),
cache.connect(),
cache.disconnect(),
]);
});
it('should successfully construct with a Redis client', async () => {
for (const url of ['1', 'redis://url']) {
jest.clearAllMocks();
stubRedisUrl(url);
const cache = new RedisCache();
expect(cache.client).toBeTruthy();
// eslint-disable-next-line no-await-in-loop
await Promise.all([
cache.set('foo', 'bar'),
cache.get('foo'),
cache.delete('foo'),
cache.connect(),
cache.disconnect(),
]);
// Do sanity check only
expect(mockFunction).toBeCalledTimes(6);
}
});
});

View file

@ -0,0 +1,165 @@
import { TtlCache } from '@logto/shared';
import { pick } from '@silverhand/essentials';
import { mockConnector0 } from '#src/__mocks__/connector-base-data.js';
import { mockSignInExperience } from '#src/__mocks__/sign-in-experience.js';
import { WellKnownCache } from './well-known.js';
const { jest } = import.meta;
const tenantId = 'mock_id';
const cacheStore = new TtlCache<string, string>(60_000);
afterEach(() => {
jest.clearAllMocks();
cacheStore.clear();
});
describe('Well-known cache basics', () => {
it('should be able to get, set, and delete values', async () => {
const cache = new WellKnownCache(tenantId, cacheStore);
await cache.set('sie', WellKnownCache.defaultKey, mockSignInExperience);
expect(await cache.get('sie', WellKnownCache.defaultKey)).toStrictEqual(mockSignInExperience);
await cache.set('connectors-well-known', '123', [mockConnector0]);
expect(await cache.get('connectors-well-known', '123')).toStrictEqual([
pick(mockConnector0, 'connectorId', 'id', 'metadata'),
]);
await cache.delete('sie', WellKnownCache.defaultKey);
expect(await cache.get('sie', WellKnownCache.defaultKey)).toBe(undefined);
});
it('should be able to set the value with wrong structure', async () => {
const cache = new WellKnownCache(tenantId, cacheStore);
// @ts-expect-error
await cache.set('custom-phrases-tags', WellKnownCache.defaultKey, 1);
expect(await cache.get('custom-phrases-tags', WellKnownCache.defaultKey)).toBe(undefined);
});
it('should be able to set and get when cache type is wrong', async () => {
const cache = new WellKnownCache(tenantId, cacheStore);
// @ts-expect-error
await cache.set('custom-phrases-tags-', WellKnownCache.defaultKey, []);
expect(
// @ts-expect-error
await cache.get('custom-phrases-tags-', WellKnownCache.defaultKey)
).toBe(undefined);
});
});
describe('Well-known cache function wrappers', () => {
it('can memoize function and cache the promise', async () => {
jest.useFakeTimers();
const runResult = Object.freeze({ foo: 'bar' });
const run = jest.fn(
async () =>
new Promise<Record<string, unknown>>((resolve) => {
setTimeout(() => {
resolve(runResult);
}, 0);
jest.runOnlyPendingTimers(); // Ensure this runs in fake timers
})
);
const cache = new WellKnownCache(tenantId, cacheStore);
const memoized = cache.memoize(run, ['custom-phrases']);
const [result1, result2] = await Promise.all([memoized(), memoized()]);
expect(result1).toStrictEqual(runResult);
expect(result2).toStrictEqual(runResult);
expect(await cache.get('custom-phrases', WellKnownCache.defaultKey)).toStrictEqual(runResult);
expect(run).toBeCalledTimes(1);
// Second call
expect(await memoized()).toStrictEqual(runResult);
expect(run).toBeCalledTimes(1);
// Cache expired
jest.setSystemTime(Date.now() + 100_000); // Ensure cache is expired
expect(await memoized()).toStrictEqual(runResult);
expect(run).toBeCalledTimes(2);
expect(await cache.get('custom-phrases', WellKnownCache.defaultKey)).toStrictEqual(runResult);
jest.useRealTimers();
});
it('can memoize function with customized cache key builder', async () => {
const run = jest.fn(
async (foo: string, bar: number) =>
new Promise<Record<string, unknown>>((resolve) => {
setTimeout(() => {
resolve({ foo, bar });
}, 0);
})
);
const cache = new WellKnownCache(tenantId, cacheStore);
const memoized = cache.memoize(run, ['custom-phrases', (foo, bar) => `${foo}+${bar}`]);
const [result1, result2] = await Promise.all([memoized('1', 1), memoized('2', 2)]);
expect(result1).toStrictEqual({ foo: '1', bar: 1 });
expect(result2).toStrictEqual({ foo: '2', bar: 2 });
expect(
await Promise.all([cache.get('custom-phrases', '1+1'), cache.get('custom-phrases', '2+2')])
).toStrictEqual([
{ foo: '1', bar: 1 },
{ foo: '2', bar: 2 },
]);
});
it('can create mutate function wrapper with default cache key builder', async () => {
const run = jest.fn(
async () =>
new Promise<Record<string, unknown>>((resolve) => {
setTimeout(() => {
resolve({});
}, 0);
})
);
const update = jest.fn(async () => true);
const cache = new WellKnownCache(tenantId, cacheStore);
const memoized = cache.memoize(run, ['custom-phrases']);
const mutate = cache.mutate(update, ['custom-phrases']);
await memoized();
await mutate();
expect(await cache.get('custom-phrases', WellKnownCache.defaultKey)).toBeUndefined();
await memoized();
expect(run).toBeCalledTimes(2);
});
it('can create mutate function wrapper with customized cache key builder', async () => {
const run = jest.fn(
async (foo: string, bar: number) =>
new Promise<Record<string, unknown>>((resolve) => {
setTimeout(() => {
resolve({ foo, bar });
}, 0);
})
);
const update = jest.fn(async (value: number) => value);
const cache = new WellKnownCache(tenantId, cacheStore);
const memoized = cache.memoize(run, ['custom-phrases', (foo, bar) => `${foo}+${bar}`]);
const mutate = cache.mutate(update, ['custom-phrases', (value) => `1+${value}`]);
await Promise.all([memoized('1', 1), memoized('2', 2)]);
await Promise.all([mutate(1), mutate(2)]);
expect(
await Promise.all([cache.get('custom-phrases', '1+1'), cache.get('custom-phrases', '2+2')])
).toStrictEqual([undefined, { foo: '2', bar: 2 }]);
expect(run).toBeCalledTimes(2);
const mutate2 = cache.mutate(update, ['custom-phrases', () => `2+2`]);
await mutate2(1);
expect(await cache.get('custom-phrases', '2+2')).toBeUndefined();
expect(run).toBeCalledTimes(2);
});
});

View file

@ -13,8 +13,6 @@ type WellKnownMap = {
'custom-phrases-tags': string[];
};
const defaultCacheKey = '#';
export type WellKnownCacheType = keyof WellKnownMap;
/**
@ -70,6 +68,8 @@ function getValueGuard(type: WellKnownCacheType): ZodType<WellKnownMap[typeof ty
* @see {@link getValueGuard} For how data will be guarded while getting from the cache.
*/
export class WellKnownCache {
static defaultKey = '#';
/**
* @param tenantId The tenant ID this cache is intended for.
* @param cacheStore The storage to use as the cache.
@ -85,7 +85,6 @@ export class WellKnownCache {
key: string
): Promise<Optional<WellKnownMap[Type]>> {
const data = await this.cacheStore.get(this.cacheKey(type, key));
return trySafe(() => getValueGuard(type).parse(JSON.parse(data ?? '')));
}
@ -128,7 +127,7 @@ export class WellKnownCache {
// only happens when the original function executed successfully
void Promise.all(
types.map(async ([type, cacheKey]) =>
trySafe(kvCache.delete(type, cacheKey?.(...args) ?? defaultCacheKey))
trySafe(kvCache.delete(type, cacheKey?.(...args) ?? WellKnownCache.defaultKey))
)
);
@ -158,7 +157,7 @@ export class WellKnownCache {
this: unknown,
...args: Args
): Promise<Readonly<WellKnownMap[Type]>> {
const promiseKey = cacheKey?.(...args) ?? defaultCacheKey;
const promiseKey = cacheKey?.(...args) ?? WellKnownCache.defaultKey;
const cachedPromise = promiseCache.get(promiseKey);
if (cachedPromise) {
@ -166,18 +165,21 @@ export class WellKnownCache {
}
const promise = (async () => {
// Wrap with `trySafe()` here to ignore Redis errors
const cachedValue = await trySafe(kvCache.get(type, promiseKey));
try {
// Wrap with `trySafe()` here to ignore Redis errors
const cachedValue = await trySafe(kvCache.get(type, promiseKey));
if (cachedValue) {
return cachedValue;
if (cachedValue) {
return cachedValue;
}
const value = await run.apply(this, args);
await trySafe(kvCache.set(type, promiseKey, value));
return value;
} finally {
promiseCache.delete(promiseKey);
}
const value = await run.apply(this, args);
await trySafe(kvCache.set(type, promiseKey, value));
promiseCache.delete(promiseKey);
return value;
})();
promiseCache.set(promiseKey, promise);

View file

@ -24,8 +24,8 @@
"@logto/schemas": "workspace:^",
"@parcel/core": "2.8.3",
"@parcel/transformer-sass": "2.8.3",
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config-react": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/eslint-config-react": "3.0.1",
"@silverhand/ts-config": "3.0.0",
"@silverhand/ts-config-react": "3.0.0",
"@types/react": "^18.0.31",

View file

@ -27,7 +27,7 @@
"@logto/node": "1.1.0",
"@logto/schemas": "workspace:^",
"@peculiar/webcrypto": "^1.3.3",
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/essentials": "^2.5.0",
"@silverhand/ts-config": "3.0.0",
"@types/expect-puppeteer": "^5.0.3",

View file

@ -38,7 +38,7 @@
"zod": "^3.20.2"
},
"devDependencies": {
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/ts-config": "3.0.0",
"buffer": "^5.7.1",
"eslint": "^8.34.0",

View file

@ -38,7 +38,7 @@
"zod": "^3.20.2"
},
"devDependencies": {
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/ts-config": "3.0.0",
"eslint": "^8.34.0",
"lint-staged": "^13.0.0",

View file

@ -40,7 +40,7 @@
"node": "^18.12.0"
},
"devDependencies": {
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/essentials": "^2.5.0",
"@silverhand/ts-config": "3.0.0",
"@types/inquirer": "^9.0.0",

View file

@ -43,7 +43,7 @@
},
"devDependencies": {
"@logto/connector-kit": "workspace:^",
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/ts-config": "3.0.0",
"@types/jest": "^29.4.0",
"@types/node": "^18.11.18",

View file

@ -39,7 +39,7 @@
"zod": "^3.20.2"
},
"devDependencies": {
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/ts-config": "3.0.0",
"@types/node": "^18.11.18",
"eslint": "^8.34.0",

View file

@ -48,7 +48,7 @@
},
"devDependencies": {
"@jest/types": "^29.0.3",
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/essentials": "^2.5.0",
"@silverhand/ts-config": "3.0.0",
"@silverhand/ts-config-react": "3.0.0",

View file

@ -39,7 +39,7 @@
},
"devDependencies": {
"@jest/types": "^29.0.3",
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/ts-config": "3.0.0",
"@types/jest": "^29.4.0",
"@types/node": "^18.11.18",

View file

@ -35,8 +35,8 @@
"@peculiar/webcrypto": "^1.3.3",
"@react-spring/shared": "^9.6.1",
"@react-spring/web": "^9.6.1",
"@silverhand/eslint-config": "3.0.0",
"@silverhand/eslint-config-react": "3.0.0",
"@silverhand/eslint-config": "3.0.1",
"@silverhand/eslint-config-react": "3.0.1",
"@silverhand/essentials": "^2.5.0",
"@silverhand/jest-config": "1.2.2",
"@silverhand/ts-config": "3.0.0",

220
pnpm-lock.yaml generated
View file

@ -49,8 +49,8 @@ importers:
version: 2.5.0
devDependencies:
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -170,8 +170,8 @@ importers:
version: 3.20.2
devDependencies:
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -276,8 +276,8 @@ importers:
version: 3.20.2
devDependencies:
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/jest-config':
specifier: 3.0.0
version: 3.0.0(jest@29.5.0)
@ -361,8 +361,8 @@ importers:
specifier: ^5.0.0
version: 5.0.0
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -449,8 +449,8 @@ importers:
specifier: ^5.0.0
version: 5.0.0
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -528,8 +528,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -607,8 +607,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -692,8 +692,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -777,8 +777,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -859,8 +859,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -938,8 +938,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -1017,8 +1017,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -1096,8 +1096,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -1178,8 +1178,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -1257,8 +1257,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -1336,8 +1336,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -1415,8 +1415,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -1494,8 +1494,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -1573,8 +1573,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -1652,8 +1652,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -1731,8 +1731,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -1810,8 +1810,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -1889,8 +1889,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -1968,8 +1968,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -2050,8 +2050,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -2138,8 +2138,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -2223,8 +2223,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -2302,8 +2302,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -2384,8 +2384,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -2466,8 +2466,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -2545,8 +2545,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -2624,8 +2624,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -2703,8 +2703,8 @@ importers:
specifier: ^10.0.1
version: 10.0.1(rollup@3.8.0)(typescript@5.0.2)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -2802,11 +2802,11 @@ importers:
specifier: 2.8.3
version: 2.8.3(@parcel/core@2.8.3)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/eslint-config-react':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(postcss@8.4.6)(prettier@2.8.4)(stylelint@15.0.0)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(postcss@8.4.6)(prettier@2.8.4)(stylelint@15.0.0)(typescript@5.0.2)
'@silverhand/essentials':
specifier: ^2.5.0
version: 2.5.0
@ -3166,8 +3166,8 @@ importers:
version: 3.20.2
devDependencies:
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -3292,11 +3292,11 @@ importers:
specifier: 2.8.3
version: 2.8.3(@parcel/core@2.8.3)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/eslint-config-react':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(postcss@8.4.14)(prettier@2.8.4)(stylelint@15.0.0)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(postcss@8.4.14)(prettier@2.8.4)(stylelint@15.0.0)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -3380,8 +3380,8 @@ importers:
specifier: ^1.3.3
version: 1.3.3
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/essentials':
specifier: ^2.5.0
version: 2.5.0
@ -3450,8 +3450,8 @@ importers:
version: 3.20.2
devDependencies:
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -3481,8 +3481,8 @@ importers:
version: 3.20.2
devDependencies:
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -3530,8 +3530,8 @@ importers:
version: 3.20.2
devDependencies:
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/essentials':
specifier: ^2.5.0
version: 2.5.0
@ -3606,8 +3606,8 @@ importers:
specifier: workspace:^
version: link:../toolkit/connector-kit
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -3647,8 +3647,8 @@ importers:
version: 3.20.2
devDependencies:
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -3691,8 +3691,8 @@ importers:
specifier: ^29.0.3
version: 29.3.1
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/essentials':
specifier: ^2.5.0
version: 2.5.0
@ -3749,8 +3749,8 @@ importers:
specifier: ^29.0.3
version: 29.3.1
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/ts-config':
specifier: 3.0.0
version: 3.0.0(typescript@5.0.2)
@ -3827,11 +3827,11 @@ importers:
specifier: ^9.6.1
version: 9.6.1(react-dom@18.2.0)(react@18.2.0)
'@silverhand/eslint-config':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/eslint-config-react':
specifier: 3.0.0
version: 3.0.0(eslint@8.34.0)(postcss@8.4.6)(prettier@2.8.4)(stylelint@15.0.0)(typescript@5.0.2)
specifier: 3.0.1
version: 3.0.1(eslint@8.34.0)(postcss@8.4.6)(prettier@2.8.4)(stylelint@15.0.0)(typescript@5.0.2)
'@silverhand/essentials':
specifier: ^2.5.0
version: 2.5.0
@ -5660,16 +5660,6 @@ packages:
postcss-selector-parser: 6.0.11
dev: true
/@eslint-community/eslint-utils@4.1.2(eslint@8.34.0):
resolution: {integrity: sha512-7qELuQWWjVDdVsFQ5+beUl+KPczrEDA7S3zM4QUd/bJl7oXgsmpXaEVqrRTnOBqenOV4rWf2kVZk2Ot085zPWA==}
engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0}
peerDependencies:
eslint: ^6.0.0 || ^7.0.0 || ^8.0.0
dependencies:
eslint: 8.34.0
eslint-visitor-keys: 3.3.0
dev: true
/@eslint-community/eslint-utils@4.4.0(eslint@8.34.0):
resolution: {integrity: sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==}
engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0}
@ -7582,13 +7572,13 @@ packages:
resolution: {integrity: sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ==}
dev: true
/@silverhand/eslint-config-react@3.0.0(eslint@8.34.0)(postcss@8.4.14)(prettier@2.8.4)(stylelint@15.0.0)(typescript@5.0.2):
resolution: {integrity: sha512-6d1I3BK5KoRT/yWsByYpqmHTMfCZakuGKR+sDNhBNCFaElZDaTHSizb3wN7dY2DVs6VDfTnZG1sva+U+VYk3zg==}
/@silverhand/eslint-config-react@3.0.1(eslint@8.34.0)(postcss@8.4.14)(prettier@2.8.4)(stylelint@15.0.0)(typescript@5.0.2):
resolution: {integrity: sha512-8roPq3t5qgi4pxYh3It2BhS91LVsp740vhNXVn56RTID0ZdW27LMrV2yp5uTT6kVzLdFYis4nIPlOVFCnv+VKA==}
engines: {node: ^18.12.0}
peerDependencies:
stylelint: ^15.0.0
dependencies:
'@silverhand/eslint-config': 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/eslint-config': 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
eslint-config-xo-react: 0.27.0(eslint-plugin-react-hooks@4.6.0)(eslint-plugin-react@7.31.10)(eslint@8.34.0)
eslint-plugin-jsx-a11y: 6.6.1(eslint@8.34.0)
eslint-plugin-react: 7.31.10(eslint@8.34.0)
@ -7604,13 +7594,13 @@ packages:
- typescript
dev: true
/@silverhand/eslint-config-react@3.0.0(eslint@8.34.0)(postcss@8.4.6)(prettier@2.8.4)(stylelint@15.0.0)(typescript@5.0.2):
resolution: {integrity: sha512-6d1I3BK5KoRT/yWsByYpqmHTMfCZakuGKR+sDNhBNCFaElZDaTHSizb3wN7dY2DVs6VDfTnZG1sva+U+VYk3zg==}
/@silverhand/eslint-config-react@3.0.1(eslint@8.34.0)(postcss@8.4.6)(prettier@2.8.4)(stylelint@15.0.0)(typescript@5.0.2):
resolution: {integrity: sha512-8roPq3t5qgi4pxYh3It2BhS91LVsp740vhNXVn56RTID0ZdW27LMrV2yp5uTT6kVzLdFYis4nIPlOVFCnv+VKA==}
engines: {node: ^18.12.0}
peerDependencies:
stylelint: ^15.0.0
dependencies:
'@silverhand/eslint-config': 3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
'@silverhand/eslint-config': 3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2)
eslint-config-xo-react: 0.27.0(eslint-plugin-react-hooks@4.6.0)(eslint-plugin-react@7.31.10)(eslint@8.34.0)
eslint-plugin-jsx-a11y: 6.6.1(eslint@8.34.0)
eslint-plugin-react: 7.31.10(eslint@8.34.0)
@ -7626,8 +7616,8 @@ packages:
- typescript
dev: true
/@silverhand/eslint-config@3.0.0(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2):
resolution: {integrity: sha512-vVcTniAfrLNhFBUebsTlcFxpJ0BttpDKRZ6lv6Z9PCOk4PyMSPPmNjEMLpaBekG1idLr1CDUJfKVZmtASBegXA==}
/@silverhand/eslint-config@3.0.1(eslint@8.34.0)(prettier@2.8.4)(typescript@5.0.2):
resolution: {integrity: sha512-ZjZehXlkjGXJlKQaJvFwSTalCo7dEgcoNTqVJoy2OAq7csCrEW4Q0lA8UHYjzJfDUefSCfwt+dcQfkA/cMrncw==}
engines: {node: ^18.12.0}
peerDependencies:
eslint: ^8.34.0
@ -10982,7 +10972,7 @@ packages:
eslint: '>=8.28.0'
dependencies:
'@babel/helper-validator-identifier': 7.19.1
'@eslint-community/eslint-utils': 4.1.2(eslint@8.34.0)
'@eslint-community/eslint-utils': 4.4.0(eslint@8.34.0)
ci-info: 3.8.0
clean-regexp: 1.0.0
eslint: 8.34.0