frenic / csstype

Strict TypeScript and Flow types for style based on MDN data

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Idea to wrap types into element types?

joeprivettsmart opened this issue · comments

Hi there, nice work on the package :) We are composing element types like so:

export type TSInput = 
  Partial<Pick<HTMLInputElement, 'disabled' | 'min' | 'max' | 'size' | 'autocomplete'>> &
  Pick<StandardProperties, 'textAlign'> & {
    as?: 'input' | 'textarea' | 'div'
    onKeyDown?: (e: KeyboardEvent<HTMLInputElement>) => void
    onPaste?: (e: ClipboardEvent<HTMLInputElement>) => void
  }

I would imagine that every application would be doing the same for standard element attributes. Will this package look to export types for element?