HingeJoint2D dynamic creation problem

I faced with problem while trying to connect nodes with HingeJoind2D dynamically from code. Using CC 3.8.1.
Simplest example. Created 4 nodes in CC editor, put RigidBody2D and BoxCollider2D components on every node.
Then connect 2 of them with HingeJoin2D with adding component in editor. This nodes are connected properly after run.

Other two nodes I am trying to connect from code:

start() {
PhysicsSystem2D.instance.debugDrawFlags =
EPhysics2DDrawFlags.CenterOfMass |
EPhysics2DDrawFlags.Joint |

const b1 = find('Canvas/body1');
const b2 = find('Canvas/body2');
const body1 = b1.getComponent(RigidBody2D);

const joint = b2.addComponent(HingeJoint2D);
joint.connectedBody = body1;



But it does not work. HingeJoint2D connects Node to center of physical world, how I understand. Checking nodes objects state in console showing everything setted properly.
Tryed to set anchors and change other parameters but nothing helps, it wont even change anchors in fact.
Also its not only HingeJoint2D problem, I have tried other types of Joint2D.
What is wrong here?

Find the solution in re-enabling of joint component. But as for me - its strange.

@Shishandr I think instead of putting in start method add same code on button event it will work.
Also if you put 0.1 second delay then also it might work.

I tried with scheduleOnce(), and also in original project I do it on gamepad button push, and it worked the same… so here I just present very simple example with start(). In all variants - only solution for me was to re-enable joint component after configuration… it looks like it implement all properties only while “enabling” process. But as component is enabled by default on creation - re-enabling helps.