diff --git a/packages/vue/src/composables/useAppSharedState/index.test.ts b/packages/vue/src/composables/useAppSharedState/index.test.ts index d3d4829..6d290ae 100644 --- a/packages/vue/src/composables/useAppSharedState/index.test.ts +++ b/packages/vue/src/composables/useAppSharedState/index.test.ts @@ -3,7 +3,7 @@ import { ref, reactive } from 'vue'; import { useAppSharedState } from '.'; describe('useAppSharedState', () => { - it('should initialize state only once', () => { + it('initialize state only once', () => { const stateFactory = (initValue?: number) => { const count = ref(initValue ?? 0); return { count }; @@ -19,7 +19,7 @@ describe('useAppSharedState', () => { expect(state1).toBe(state2); }); - it('should return the same state object across different calls', () => { + it('return the same state object across different calls', () => { const stateFactory = () => { const state = reactive({ count: 0 }); const increment = () => state.count++; diff --git a/packages/vue/src/composables/useAppSharedState/index.ts b/packages/vue/src/composables/useAppSharedState/index.ts index 321282c..69b74a9 100644 --- a/packages/vue/src/composables/useAppSharedState/index.ts +++ b/packages/vue/src/composables/useAppSharedState/index.ts @@ -1,5 +1,5 @@ import type { AnyFunction } from '@robonen/stdlib'; -import { effectScope, onScopeDispose } from 'vue'; +import { effectScope } from 'vue'; // TODO: maybe we should control subscriptions and dispose them when the child scope is disposed @@ -8,8 +8,8 @@ import { effectScope, onScopeDispose } from 'vue'; * @category State * @description Provides a shared state object for use across Vue instances * - * @param {Function} stateFactory The factory function to create the shared state - * @returns {Function} The shared state object + * @param {Function} stateFactory A factory function that returns the shared state object + * @returns {Function} A function that returns the shared state object * * @example * const useSharedState = useAppSharedState((initValue?: number) => {