@mikelgo/ng-types
TypeScript icon, indicating that this package has built-in type declarations

10.0.0 • Public • Published

ng-types

Tired of writing e.g. @Input() arg: string | null | undefined over and over again when using Angular's strict mode?

ng-types to the rescue! This handy lib provides a collection of types which will reflect strict inputs.

Besides that it offers some coercion helpers to make your life easier.

Installation

npm i @mikelgo/ng-types

Supported types

  • StringInput
  • NumberInput
  • BooleanInput
  • DateInput
  • ArrayInput
  • ObjectInput
  • FunctionInput

Coercion helpers

  • coerceBoolean
  • coerceNumber
  • coerceObservable

Compatibility

  • Version 10.x.x is compatible with Angular >= 10.0.8

Package Sidebar

Install

npm i @mikelgo/ng-types

Weekly Downloads

1

Version

10.0.0

License

none

Unpacked Size

16 kB

Total Files

17

Last publish

Collaborators

  • mikelgo