ngx-sortablejs
ngx-sortablejs copied to clipboard
Restricted ngOnChanges to only run when able
Fixes: #172
Added condition that the sortableInstance has already been instantiated, before it can be used in the ngOnChanges method. Should resolve the error from this issue where ngOnChanges executes and breaks before sortableInstance actually exists.
I didn't see a CONTRIBUTING.md or any contribution information in the README, so please let me know if this is at all welcome and if there's anything else you need me to update such as the version in package.json/package-lock.json (is 0, so I assume no) or the changelog.
@smnbbrv and @kamilchlebek Sorry to tag you two, but I see some other unmerged PRs with no maintainer discussion on them that have been open for some time. One of which is actually approved, but unmerged. You two are the most recently merged commits, so I hoped you might be able to help review this or find it a reviewer. I am currently blocked by this issue and would prefer not to have to wait for weeks or indefinitely on it.
Please have a look at #197
Ah dang, I see. We'll probably make a private fork then and work our way off the dependency. Thank you though 👍
@blackbaud-conorwright: Are you planning to make a fork and a npm release?
I am not planning on releasing and maintaining a public version, sorry. I made a private fork with my fixes and am actively working on moving away from the dependency altogether. If you need the fix, I'd recommend pulling down this PR's branch and doing the same unless you are willing to take over ownership/maintenance of this project.
@blackbaud-conorwright: Thanks for your reply? You said you're moving away from the dependency. Do you have an alternative npm package that you recommend or how will you do sorting in the future? Thanks in advance for your reply.
You can use @angular/cdk drag and drop implementation https://material.angular.io/cdk/drag-drop/overview
It is quite easy to use, very flexible and created by Angular team specifically for Angular. That's what I am using now.
SortableJS is quite old, has limited API and is really painful to support; especially when it comes to Angular. This, and the fact there is "official way" to do it, are the reasons I stopped developing this project.
You can use @angular/cdk drag and drop implementation https://material.angular.io/cdk/drag-drop/overview
It is quite easy to use, very flexible and created by Angular team specifically for Angular. That's what I am using now.
SortableJS is quite old, has limited API and is really painful to support; especially when it comes to Angular. This, and the fact there is "official way" to do it, are the reasons I stopped developing this project.
True but some things still can't be done easily with Angular Material drag and drop like flexbox wrapped lists. Whereas with sortableJS it's piece of cake.
Hi there, what's a status of this pr?