Skip to content

Latest commit

 

History

History
37 lines (25 loc) · 969 Bytes

CONTRIBUTING.md

File metadata and controls

37 lines (25 loc) · 969 Bytes

Contributing

Contributing issues and pull requests is highly appreciated!

Please follow these guidelines:

Development setup

Make sure that Node.js (at least version 12) is installed.
Install all development dependencies with npm install.

Run tests or type tests in watch mode:

npm run test:watch
npm run type-test:watch

Before you commit, run all following commands to ensure that all tests pass:

npm run test
npm run type-test
npm run lint
npm run build

Adding a new prop type

When adding a new prop type, you need to modify several files:

  1. src/prop-types/yourNewPropType.ts (in camelCase please!) – the implementation.
  2. src/index.ts – re-export the new prop type from the main entrypoint.
  3. tests/prop-types/yourNewPropType.spec.ts – the unit tests.
  4. type-tests/prop-types/yourNewPropType.type.spec.ts – the type tests.

Please use the existing files as a reference and follow the existing style.