ngx-sortablejs icon indicating copy to clipboard operation
ngx-sortablejs copied to clipboard

Support Angular 12

Open nunoarruda opened this issue 3 years ago • 9 comments

Looks to be working ok with Angular 12 but there's a warning on npm install about peer dependencies:

npm WARN [email protected] requires a peer of @angular/common@^11.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN [email protected] requires a peer of @angular/core@^11.0.0 but none is installed. You must install peer dependencies yourself.

nunoarruda avatar Aug 24 '21 14:08 nunoarruda

pull request https://github.com/SortableJS/ngx-sortablejs/pull/246

Anikethana avatar Sep 18 '21 00:09 Anikethana

Node.js LTS version is now v16.x which includes npm v8.x. These versions will error out on npm install if there is an incorrect (and potentially broken) dependency resolution which looks to be the case with ngx-sortablejs:

npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR! 
npm ERR! While resolving: [email protected]
npm ERR! Found: @angular/[email protected]
npm ERR! node_modules/@angular/common
npm ERR!   @angular/common@"~12.2.11" from the root project
npm ERR! 
npm ERR! Could not resolve dependency:
npm ERR! peer @angular/common@"^11.0.0" from [email protected]
npm ERR! node_modules/ngx-sortablejs
npm ERR!   ngx-sortablejs@"^11.1.0" from the root project
npm ERR! 
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR! 
npm ERR! See /Users/nunoarruda/.npm/eresolve-report.txt for a full report.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/nunoarruda/.npm/_logs/2021-11-02T15_53_02_208Z-debug.log

Workaround: use npm install --force or npm install --legacy-peer-deps.

@smnbbrv can you please fix this when you have a chance?

nunoarruda avatar Nov 02 '21 16:11 nunoarruda

It might be appropriate to not depend on a specific version of Angular and do a greater than the min requirements as a peer dependency instead? Would prevent having to create new builds for every Angular release.

arimus avatar Nov 28 '21 05:11 arimus

is this project dead?

imtiazShakil avatar Nov 22 '22 10:11 imtiazShakil

At this stage, it looks like this project is pretty much dead and/or abandoned. I suggest you folks give these alternatives a try:

https://material.angular.io/cdk/drag-drop/overview (for mixed direction, follow MikaStark workaround) https://valor-software.com/ng2-dragula/ https://kreuzerk.github.io/ng-sortgrid/

nunoarruda avatar Nov 22 '22 12:11 nunoarruda

cdk doesn't work with grids dragula also dead sortgrid doesn't cut it

SortableJs is the best available, but it needs to be maintained :(

COBRASoft5 avatar Nov 22 '22 12:11 COBRASoft5

Yes, it's dead. I'd suggest https://github.com/ThibaultJanBeyer/DragSelect as alternative

Deitsch avatar Nov 23 '22 09:11 Deitsch

Holly shit it's too bad ....

SylvainUMI avatar Jul 28 '23 14:07 SylvainUMI

Hi, folks, I suggest you can try the ng-dnd library and it's very easy to solve the mixed direction issue (https://github.com/angular/components/issues/13372), please check the following example: https://stackblitz.com/edit/867pxw?file=src%2Fexample%2Fchips-drag-drop-example.html

nzbin avatar Aug 02 '23 10:08 nzbin