grommet / grommet/react-formify
getResource changes value of strings with quotes
Open
- Dominant language
- JavaScript
- Stars
- 8
- Forks
- 2
- PR merge metrics
- No merged PRs in 30d
Description
`FormState.js` contains the function:
```
this.getResource = function () {
return JSON.parse(JSON.stringify(_this.obj).replace(/"\s+|\s+"/g, '"'));
};
```
The regex replace can change the value of a form element. For example, if you have a `textarea` with the value `foo "bar" foo` the regex will change it (remove last space) to `foo "bar"foo` which is not the desired string.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.