kibana/packages/kbn-securitysolution-io-ts-utils/README.md
Frank Hassanabad 7dd29a56ad
[Security Solutions] Breaks down the io-ts packages to decrease plugin size (#100058)
## Summary

The io-ts package was too large and needed to broken down more by domain to decrease the lists plugin size and any other plugin wanting to use the packages will not incur big hits as well.

Before we had one large io-ts package:

```
@kbn/securitysolution-io-ts-utils
```

Now we have these broken down 4 packages:

```
@kbn/securitysolution-io-ts-utils
@kbn/securitysolution-io-ts-types
@kbn/securitysolution-io-ts-alerting-types
@kbn/securitysolution-io-ts-list-types   
```

Deps between these packages are:

```
@kbn/securitysolution-io-ts-utils (none)
@kbn/securitysolution-io-ts-types -> @kbn/securitysolution-io-ts-utils
@kbn/securitysolution-io-ts-alerting-types -> @kbn/securitysolution-io-ts-types, @kbn/securitysolution-io-ts-utils
@kbn/securitysolution-io-ts-list-types  -> @kbn/securitysolution-io-ts-types, @kbn/securitysolution-io-ts-utils
```

Short description and function of each (Also in each of their README.md):

```
@kbn/securitysolution-io-ts-utils, Smallest amount of utilities such as format, validate, etc...
@kbn/securitysolution-io-ts-types, Base types such as to_number, to_string, etc...
@kbn/securitysolution-io-ts-alerting-types, Alerting specific types such as severity, from, to, etc...
@kbn/securitysolution-io-ts-list-types, list specific types such as exception lists, exception list types, etc...
```

### Checklist

Delete any items that are not applicable to this PR.

- [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios
2021-05-13 15:36:06 -06:00

702 B

kbn-securitysolution-io-ts-utils

Very small set of utilities for io-ts which we use across plugins within security solutions such as securitysolution, lists, cases, etc... This folder should remain small and concise since it is pulled into front end and the more files we add the more weight will be added to all of the plugins. Also, any new dependencies added to this will add weight here and the other plugins, so be careful of what is added here.

You might consider making another package instead and putting a dependency on this one if needed, instead.

Related packages are

  • kbn-securitysolution-io-ts-alerting-types
  • kbn-securitysolution-io-ts-list-types
  • kbn-securitysolution-io-ts-types