diff --git a/.eslintrc b/.eslintrc index 68b14f8..d202eb7 100644 --- a/.eslintrc +++ b/.eslintrc @@ -1,3 +1,12 @@ { - "extends": "@folio/eslint-config-stripes" + "extends": "@folio/eslint-config-stripes", + "overrides": [ + { + "files": ["**/*.d.ts"], + "rules": { + // eslint does not like .d.ts files without a corresponding .js file + "import/no-unresolved": "off" + } + } + ] } diff --git a/CHANGELOG.md b/CHANGELOG.md index 6353c70..97ea12c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,7 @@ * *BREAKING* `stripes-ui` `2.0.0` * *BREAKING* `react` `v18` * *BREAKING* `react-intl` `v6` +* `stripes-types` `v2` ## [8.0.0](https://github.com/folio-org/stripes/tree/v8.0.0) (2023-01-31) diff --git a/README.md b/README.md index be01da8..d186841 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,6 @@ Stripes is a toolkit for building single-page web applications that FOLIO UI mod * [Overview of Stripes](doc/overview.md) - Concepts that guided the design of Stripes * [Stripes entities](doc/modules-apps-etc.md) - Terminology of things pertaining to Stripes - ## Developing with Stripes Getting started and new environment setup @@ -39,6 +38,10 @@ Guides for development and testing * [Depending on unreleased features](doc/depending-on-unreleased-features.md) * [Troubleshooting guide](doc/troubleshooting.md) - An evolving troubleshooting guide +## TypeScript support + +Typings for the Stripes framework may be found in [stripes-types](https://github.com/folio-org/stripes-types) + ## Implementing Stripes Guides for dev-ops and platform implementors diff --git a/components/index.d.ts b/components/index.d.ts new file mode 100644 index 0000000..c500744 --- /dev/null +++ b/components/index.d.ts @@ -0,0 +1 @@ +export * from '@folio/stripes-types/components'; diff --git a/core/index.d.ts b/core/index.d.ts new file mode 100644 index 0000000..67ac7b8 --- /dev/null +++ b/core/index.d.ts @@ -0,0 +1 @@ +export * from '@folio/stripes-types/core'; diff --git a/final-form/index.d.ts b/final-form/index.d.ts new file mode 100644 index 0000000..cfdad6b --- /dev/null +++ b/final-form/index.d.ts @@ -0,0 +1,2 @@ +export { default } from '@folio/stripes-types/final-form'; +export * from '@folio/stripes-types/final-form'; diff --git a/package.json b/package.json index cdb9f25..ae68054 100644 --- a/package.json +++ b/package.json @@ -24,6 +24,7 @@ "@folio/stripes-form": "~9.0.0", "@folio/stripes-logger": "~1.0.0", "@folio/stripes-smart-components": "~9.0.0", + "@folio/stripes-types": "^2.0.0", "@folio/stripes-ui": "~2.0.0", "@folio/stripes-util": "~6.0.0", "redux": "^4.2.1" diff --git a/smart-components/index.d.ts b/smart-components/index.d.ts new file mode 100644 index 0000000..560ecc0 --- /dev/null +++ b/smart-components/index.d.ts @@ -0,0 +1,2 @@ +export { default } from '@folio/stripes-types/smart-components'; +export * from '@folio/stripes-types/smart-components';