Skip to content

Conversation

davedotdev
Copy link
Collaborator

This is a large update to 0.6.1. Read the commits for more information.

In essence it updates the dependencies to the latest that React 16.x supports. Some minor code modifications have been allowed for to keep ESlint happy too.

One test from Corti.js is breaking and that's been commented out for now. There is a deprecated event call which could be causing issues, but I've not had enough time yet to resolve that matter.

…n stepped through and updated accordingly. Two packages remain pinned to specific versions due to React versions and breaking API changes. These will need to be addressed in the future.

```bash
"sinon": "^13.0.1",
"react-test-renderer": "^16.14.0",
```

One test does not work. I don't have the know how to fix this.
I've also disabled eslint forbid-prop-types of 'any' affecting ChatBot.jsx along with jsx-props-no-spreading. These issues are to be resolved in another PR.

__Test Failure__

Test that fails in `recognitions.spec.js`:

    it('should call end after 1s', () => {
        const onChange = spy();
        const onEnd = spy();
        const recognition = new Recognition(onChange, onEnd);
        recognition.speak();
        recognition.recognition.say('hi, this is a test');
        setTimeout(() => {
        expect(onEnd.called).to.be.equal(true);
        }, 1000);
    });

It is commented out for this PR. This could be a breaking change for speech recognition.

---

react/forbid-prop-types
react/jsx-props-no-spreading

These two eslint exceptions are in ChatBot.jsx.

There are some `PropTypes` that look like the below which need to be specific. Ideally in the future, these is TS.

`PropTypes.objectOf(PropTypes.any)`

There is also an input which has some overrides. Eslint is unhappy about this.

```javascript
            <Input
            type="textarea"
            style={inputStyle}
            ref={this.setInputRef}
            className="rsc-input"
            placeholder={inputInvalid ? '' : inputPlaceholder}
            onKeyPress={this.handleKeyPress}
            onChange={this.onValueChange}
            value={inputValue}
            floating={floating}
            invalid={inputInvalid}
            disabled={disabled}
            hasButton={!hideSubmitButton}
            {...inputAttributesOverride}
            />
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant