Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

direct-vuex

Package Overview
Dependencies
Maintainers
1
Versions
67
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

direct-vuex - npm Package Compare versions

Comparing version 0.2.4 to 0.2.5

2

package.json
{
"name": "direct-vuex",
"version": "0.2.4",
"version": "0.2.5",
"description": "Just Vuex with typing. Compatible with the Vue 3 composition API.",

@@ -5,0 +5,0 @@ "author": "Paleo",

@@ -14,4 +14,4 @@ import { Store } from "vuex"

export type DirectState<O extends StoreOrModuleOptions> =
O["state"]
type DirectState<O extends StoreOrModuleOptions> =
ToStateObj<O["state"]>
& GetStateInModules<OrEmpty<O["modules"]>>

@@ -23,5 +23,7 @@

type ToStateObj<T> = T extends () => any ? ReturnType<T> : T;
// Getters
export type DirectGetters<O extends StoreOrModuleOptions> =
type DirectGetters<O extends StoreOrModuleOptions> =
ToDirectGetters<OrEmpty<O["getters"]>>

@@ -35,3 +37,3 @@ & GetGettersInModules<FilterNamespaced<OrEmpty<O["modules"]>>>

export type ToDirectGetters<T extends GettersImpl> = {
type ToDirectGetters<T extends GettersImpl> = {
[K in keyof T]: ReturnType<T[K]>

@@ -44,3 +46,3 @@ }

export type DirectMutations<O extends StoreOrModuleOptions> =
type DirectMutations<O extends StoreOrModuleOptions> =
ToDirectMutations<OrEmpty<O["mutations"]>>

@@ -54,3 +56,3 @@ & GetMutationsInModules<FilterNamespaced<OrEmpty<O["modules"]>>>

export type ToDirectMutations<T extends MutationsImpl> = {
type ToDirectMutations<T extends MutationsImpl> = {
[K in keyof T]: Parameters<T[K]>[1] extends undefined

@@ -65,3 +67,3 @@ ? (() => void)

export type DirectActions<O extends StoreOrModuleOptions> =
type DirectActions<O extends StoreOrModuleOptions> =
ToDirectActions<OrEmpty<O["actions"]>>

@@ -75,3 +77,3 @@ & GetActionsInModules<FilterNamespaced<OrEmpty<O["modules"]>>>

export type ToDirectActions<T extends ActionsImpl> = {
type ToDirectActions<T extends ActionsImpl> = {
[K in keyof T]: Parameters<T[K]>[1] extends undefined

@@ -78,0 +80,0 @@ ? (() => PromiseOf<ReturnType<T[K]>>)

@@ -10,3 +10,3 @@ import { ToDirectStore } from "./direct-types"

export interface StoreOrModuleOptions {
state?: any,
state?: (() => any) | any,
getters?: GettersImpl

@@ -13,0 +13,0 @@ mutations?: MutationsImpl

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc