Is there a way to get an event back from javascript to Delphi

Is there anyway to call an event from javascript back into Delphi ? I am using just a plain Web application, no FNC components or PWA, Electron or Miletus

I'm not sure I fully understand your question.
Do you mean something like AddEventListener() and call a Delphi proc from there?
This technique is used a lot in the WEB Core framework source code. Check in WEBLib.Controls.pas for example in the Core Source folder.

Thanks, that looks like it will do the trick. The only thing missing is the definition of the javascript event.

JavaScript can pass different objects. Either you know the type and define it in the param list or you define TJSEvent and cast to the correct object type.