feat(typescript): Add typescript support for UI components library (#43541)

* Add TS configs and improve dir structure

* Add TS configs and improve dir structure

* Fix components exports from index

* chore: prettier

* Add tsconfig and then fix the linter warnings

* Add @babel/preset-typescript

* Fix eslint rule and update btn component to fix storybook

* Fix TS and Jest configs

Converted all remaining files to TS as well

* Remove TS ignored rules and fixed some TS & jest stuff

* Revert to old directory structure

* Use absolute versions in package.json

* enable ts strict to infer types

Co-authored-by: Hamza Waleed <hamza.waleed@arbisoft.com>
This commit is contained in:
Hamza Waleed
2021-09-28 16:06:21 +05:00
committed by GitHub
parent cc13291ca6
commit ebec6705a3
15 changed files with 480 additions and 142 deletions

View File

@ -0,0 +1,15 @@
module.exports = {
"presets": [
"@babel/preset-react",
"@babel/preset-typescript",
[
"@babel/preset-env",
{
"targets": {
"browsers": [">0.25%", "not dead"]
}
}
]
],
"plugins": [["transform-react-remove-prop-types", { "removeImport": true }]]
}