Event on paragraph change

I’m working with the Word JavaScript API and have set up an event handler to detect changes in paragraphs. However, it seems that the paragraphChanged function is never being called. Here’s the code I’m using:

await Word.run(async (context) => {
  const eventContext = context.document.onParagraphChanged.add(paragraphChanged);
  await context.sync();

  console.log("Added event handler for when content is changed in paragraphs.");
});

async function paragraphChanged() {
  await Word.run(async (context) => {
    console.log('event detected');
  });
}

I never see logs in the console from the paragraphChanged function when I write text in Word or change paragraph settings
What am I doing wrong?

Thanks in advance