Dependent task moving incorrectly


I’ve got a problem where a start_to_finish dependency is incorrectly being calculated when I resize a task and I can’t quite figure out what’s going on. I’ve put together an example that isn’t working:

The example has a very basic structure

  • Task 1
  • Task 2
    ---- Task 2.1

There is one link between Task 2.1 and Task 1. The link has a lag of 1 day.

  • If I move Task 2.1 forwards or backwards, Task 1 correctly moves forwards or backwards accordingly
  • If I resize Task 2.1 start date, Task 1 does not get moved at all (incorrect given the dependency type)

  • If I resize Task 2.1 end date, Task 1 does move even though it shouldn’t

It seems like there’s something going wrong when resizing tasks. I’ve tried changing the constraint type and various other configuration options but I’ve not had any luck


It seems to be related to the type of the link’s type property.
Gantt expects the String type:

In your case, it is Number, so, there is no guarantee that it will work correctly.

To use the Number type, you need to modify the gantt.config.links parameter:
Here is the updated snippet with the fixed link type:


Facepalm! Thanks for that, appears to be working correctly now. I wonder if it would be worth the gantt spitting out warning about things like this. I never would have found that or even considered that was an issue