p5.js-web-editor
p5.js-web-editor copied to clipboard
Fix : [#2986] Add ref callback
Fixes #2986
Changes:
- Added ref callback function to resolve the issue
I have verified that this pull request:
- [x] has no linting errors (
npm run lint) - [x] has no test errors (
npm run test) - [x] is from a uniquely-named feature branch and is up to date with the
developbranch. - [x] is descriptively named and links to an issue number.
If we have this problem in the
CollectionListRowthen odds are that we also have it in theSketchListRow. Those components are very similar and I don't like the current system where we have to make analogous changes in both places when we see an issue like this.
The SketchListRow is working fine and the problem only exists with the collections. I think this is because the SketchListRow uses class components where as the CollectionListRow uses funtional component and for some reason same logic is working for the classes but not for the functions.