Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/qiwi/substrate
Common types, interfaces and abstracts
https://github.com/qiwi/substrate
types
Last synced: 4 days ago
JSON representation
Common types, interfaces and abstracts
- Host: GitHub
- URL: https://github.com/qiwi/substrate
- Owner: qiwi
- License: mit
- Created: 2019-01-25T12:27:59.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2024-10-31T08:03:24.000Z (15 days ago)
- Last Synced: 2024-10-31T09:17:17.111Z (15 days ago)
- Topics: types
- Language: TypeScript
- Homepage:
- Size: 16.9 MB
- Stars: 9
- Watchers: 4
- Forks: 0
- Open Issues: 16
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# substrate
Common types, interfaces and abstracts### Install
```bash
npm i @qiwi/substrate -D
yarn i @qiwi/substrate --dev
```### Usage
```typescript
import { IStringMap } from '@qiwi/substrate'const foo: IStringMap = {
bar: 'baz',
qux: 'quux'
}
```### Contract
##### Naming
Upper-camel-case with prefixes `I`, `T` and `A`.
* `IFoo` — Foo interface
* `TBar` — Bar type
* `ABaz` — Baz abstract##### Versioning
Type changes without backward compatibility should be complemented by a version suffix `Vx`, where [`x ∈ ℕ`](https://en.wikipedia.org/wiki/Natural_number).
* `IFooV1` — The first version of Foo interface
* `TBarV2` — Bar type version 2### Docs
* [@qiwi/substrate-types](https://qiwi.github.io/substrate/types)
* [@qiwi/substrate-abstract](https://qiwi.github.io/substrate/abstract)