react-datasheet-grid
react-datasheet-grid copied to clipboard
Fix an error when pasting from .xls file
This fixes #267
this error happens when pasting value from .xls file (.xlsx is fine)
Deploy Preview for react-datasheet-grid canceled.
| Name | Link |
|---|---|
| Latest commit | 4e7e56e12c458dfa67dc6278a8856ede4fa6aa71 |
| Latest deploy log | https://app.netlify.com/sites/react-datasheet-grid/deploys/662b7072f6e5b60008753f5f |
I have the same issue, but I don't see how the commit here fixes the issue. As I understand it, value is undefined, therefore you can't call value.replace at all. A better option might be:
((value?.replace(/[\n\r]+/g, ' ') ?? '').trim() || (null as unknown)) as T,