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

@polymorphic-factory/solid

Package Overview
Dependencies
Maintainers
1
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@polymorphic-factory/solid - npm Package Compare versions

Comparing version 0.1.1 to 0.1.2

16

dist/index.d.ts
import { ComponentProps, ValidComponent, Component, JSX } from 'solid-js';
declare type DOMElements = keyof JSX.IntrinsicElements;
declare type ElementType = DOMElements | Component<any>;
type DOMElements = keyof JSX.IntrinsicElements;
type ElementType = DOMElements | Component<any>;
/**

@@ -11,19 +11,19 @@ * Assign property types from right to left.

*/
declare type Assign<Target, Source> = Omit<Target, keyof Source> & Source;
type Assign<Target, Source> = Omit<Target, keyof Source> & Source;
/**
* Extract the props of a solid element or component
*/
declare type PropsOf<T extends ElementType> = ComponentProps<T> & {
type PropsOf<T extends ElementType> = ComponentProps<T> & {
as?: ElementType;
};
declare type ComponentWithAs<T extends ValidComponent, Props = Record<never, never>> = Component<Assign<Assign<ComponentProps<T>, Props>, {
type ComponentWithAs<T extends ValidComponent, Props = Record<never, never>> = Component<Assign<Assign<ComponentProps<T>, Props>, {
as?: ElementType;
}>>;
declare type HTMLPolymorphicComponents = {
type HTMLPolymorphicComponents = {
[Tag in DOMElements]: ComponentWithAs<Tag>;
};
declare type HTMLPolymorphicProps<T extends ElementType> = Omit<ComponentProps<T>, 'ref'> & {
type HTMLPolymorphicProps<T extends ElementType> = Omit<ComponentProps<T>, 'ref'> & {
as?: ElementType;
};
declare type PolymorphFactory = {
type PolymorphFactory = {
<T extends ElementType, P extends Record<string, unknown> = Record<never, never>, Options = never>(component: T, option?: Options): ComponentWithAs<T, P>;

@@ -30,0 +30,0 @@ };

{
"name": "@polymorphic-factory/solid",
"version": "0.1.1",
"version": "0.1.2",
"description": "",
"keywords": [],
"keywords": [
"solid-js",
"typescript",
"jsx",
"headless",
"polymorphic",
"emotion",
"css-in-js",
"polymorphic-types"
],
"homepage": "https://github.com/chakra-ui/polymorphic",

@@ -10,2 +19,3 @@ "author": "Tim Kolberger <tim@kolberger.eu>",

"main": "dist/index.cjs.js",
"clean-package": "../../clean-package.config.json",
"sideEffects": false,

@@ -31,14 +41,14 @@ "files": [

"@types/testing-library__jest-dom": "5.14.5",
"@vitest/coverage-c8": "0.25.1",
"clean-package": "2.1.2",
"esbuild": "0.15.14",
"@vitest/coverage-c8": "0.25.3",
"clean-package": "2.2.0",
"esbuild": "0.15.17",
"esbuild-plugin-solid": "0.4.2",
"jsdom": "20.0.2",
"jsdom": "20.0.3",
"solid-js": "1.6.2",
"solid-testing-library": "0.5.0",
"tsup": "6.5.0",
"typescript": "4.8.4",
"typescript": "4.9.3",
"vite": "3.2.4",
"vite-plugin-solid": "2.4.0",
"vitest": "0.25.1"
"vitest": "0.25.3"
},

@@ -45,0 +55,0 @@ "peerDependencies": {

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