How to import go-debug jointly with gojs-react?

I import go-debug in my file gojs.ts, which importing throughout project (I use DI).

import * as go from 'gojs/release/go-debug';

then I import in the same file

import { ReactDiagram } from 'gojs-react';

and then I get error in index file at render ReactDiagram

<>
  <ReactDiagram
    initDiagram={initDiagram}
    divClassName="diagram-component"
    nodeDataArray={[...examples, ...normalizeSchema]}
    onModelChange={handleModelChange}
    linkDataArray={linkDataArray}
    skipsDiagramUpdate
  />
</>

Error:

TS2769: No overload matches this call. 
Overload 1 of 2, '(props: DiagramProps | Readonly<DiagramProps>): ReactDiagram', gave the following error. 
Type '() => go.Diagram' is not assignable to type '() => import("C:/Users/user/Documents/projects/bot-ui/node_modules/gojs/release/go").Diagram'. 
Type 'go.Diagram' is not assignable to type 'import("C:/Users/user/Documents/projects/bot-ui/node_modules/gojs/release/go").Diagram'.
Property 'computeBounds' is protected but type 'Diagram' is not a class derived from 'Diagram'.
Overload 2 of 2, '(props: DiagramProps, context: any): ReactDiagram', gave the following error.
Type '() => go.Diagram' is not assignable to type '() => import("C:/Users/user/Documents/projects/bot-ui/node_modules/gojs/release/go").Diagram'. 

How to use go-debug jointly with gojs-react is absent in the tutorial. I don’t understand how to import right.

It might be easiest to leave the import statements as they were and instead temporarily swap out the go.js file with the go-debug.js file, wherever it is.

In other words, if you are using npm, rename node_modules/gojs/release/go.js to something safe and then copy node_modules/gojs/release/go-debug.js to node_modules/gojs/release/go.js.

Just remember to copy the original go.js file back when you are done debugging. Although if you forget, it shouldn’t break your app – but it will take more time and space.