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

@solid-primitives/event-listener

Package Overview
Dependencies
Maintainers
3
Versions
41
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@solid-primitives/event-listener - npm Package Compare versions

Comparing version 2.2.4 to 2.2.5

18

dist/index.d.ts
import { MaybeAccessor, Many, Directive } from '@solid-primitives/utils';
import { JSX, Accessor, Component } from 'solid-js';
declare type EventListenerOptions = boolean | AddEventListenerOptions;
declare type TargetWithEventMap = Window | Document | HTMLElement | MediaQueryList;
declare type EventMapOf<Target> = Target extends Window ? WindowEventMap : Target extends Document ? DocumentEventMap : Target extends HTMLElement ? HTMLElementEventMap : Target extends MediaQueryList ? MediaQueryListEventMap : never;
declare type EventListenerDirectiveProps = [
type EventListenerOptions = boolean | AddEventListenerOptions;
type TargetWithEventMap = Window | Document | HTMLElement | MediaQueryList;
type EventMapOf<Target> = Target extends Window ? WindowEventMap : Target extends Document ? DocumentEventMap : Target extends HTMLElement ? HTMLElementEventMap : Target extends MediaQueryList ? MediaQueryListEventMap : never;
type EventListenerDirectiveProps = [
type: string,

@@ -19,3 +19,3 @@ handler: (e: any) => void,

}
declare type E = JSX.Element;
type E = JSX.Element;

@@ -86,3 +86,3 @@ /**

declare type EventHandlersMap<EventMap> = {
type EventHandlersMap<EventMap> = {
[EventName in keyof EventMap]: (event: EventMap[EventName]) => void;

@@ -110,6 +110,6 @@ };

declare type WindowEventProps = {
type WindowEventProps = {
[K in keyof WindowEventMap as `on${Capitalize<K>}` | `on${K}`]?: (event: WindowEventMap[K]) => void;
};
declare type DocumentEventProps = {
type DocumentEventProps = {
[K in keyof DocumentEventMap as `on${Capitalize<K>}` | `on${K}`]?: (event: DocumentEventMap[K]) => void;

@@ -136,3 +136,3 @@ };

declare type EventListenerStackOn<EventMap extends Record<string, any>> = {
type EventListenerStackOn<EventMap extends Record<string, any>> = {
<T extends keyof EventMap>(type: T, handler: (event: EventMap[T]) => void, options?: EventListenerOptions): VoidFunction;

@@ -139,0 +139,0 @@ };

{
"name": "@solid-primitives/event-listener",
"version": "2.2.4",
"version": "2.2.5",
"description": "SolidJS Primitives to manage creating event listeners.",

@@ -36,4 +36,4 @@ "author": "David Di Biase <dave.dibiase@gmail.com>",

"browser": {
"./dist/server.cjs": "./dist/index.cjs",
"./dist/server.js": "./dist/index.js"
"./dist/server.js": "./dist/index.js",
"./dist/server.cjs": "./dist/index.cjs"
},

@@ -43,18 +43,33 @@ "types": "./dist/index.d.ts",

"worker": {
"import": "./dist/server.js",
"import": {
"types": "./dist/index.d.ts",
"default": "./dist/server.js"
},
"require": "./dist/server.cjs"
},
"browser": {
"import": "./dist/index.js",
"import": {
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
},
"require": "./dist/index.cjs"
},
"deno": {
"import": "./dist/server.js",
"import": {
"types": "./dist/index.d.ts",
"default": "./dist/server.js"
},
"require": "./dist/server.cjs"
},
"node": {
"import": "./dist/server.js",
"import": {
"types": "./dist/index.d.ts",
"default": "./dist/server.js"
},
"require": "./dist/server.cjs"
},
"import": "./dist/index.js",
"import": {
"types": "./dist/index.d.ts",
"default": "./dist/index.js"
},
"require": "./dist/index.cjs"

@@ -69,13 +84,12 @@ },

"dependencies": {
"@solid-primitives/utils": "^4.0.0"
"@solid-primitives/utils": "^4.0.1"
},
"devDependencies": {
"solid-js": "^1.6.0"
},
"peerDependencies": {
"solid-js": "^1.6.0"
},
"typesVersions": {},
"scripts": {
"start": "vite serve dev --host",
"dev": "vite serve dev",
"page": "vite build dev",
"build": "jiti ../../scripts/build.ts --ssr",

@@ -82,0 +96,0 @@ "test": "vitest -c ../../configs/vitest.config.ts",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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