Closed aizela closed 3 years ago
I use it by this:
import React, { Fragment, Component } from 'react' import CornerstoneViewport from 'react-cornerstone-viewport' import { initCornerstone} from './init' class DicomViewer extends Component { constructor(props) { super(props) this.state = { tools: [ { name: 'Magnify', mode: 'active', modeOptions: { mouseButtonMask: 1 } } ], imageIds: [ 'dicomweb://s3.amazonaws.com/lury/PTCTStudy/1.3.6.1.4.1.25403.52237031786.3872.20100510032220.11.dcm', 'dicomweb://s3.amazonaws.com/lury/PTCTStudy/1.3.6.1.4.1.25403.52237031786.3872.20100510032220.12.dcm' ], activeTool: '' } initCornerstone() } render() { return ( <Fragment> <div className='dicom-viewer-wrap'> <CornerstoneViewport tools={this.state.tools} imageIds={this.state.imageIds} activeTool={this.state.activeTool} style={{ width: '100%', height: '512px', flex: '1' }} /> </div> </Fragment> ) } } export default DicomViewer
but it doesn't work. the error is : Failed to execute 'removeEventListener' on 'EventTarget': parameter 2 is not of type 'Object'
I have already rolled back the version5.1.3, and it works.
I use it by this:
but it doesn't work. the error is : Failed to execute 'removeEventListener' on 'EventTarget': parameter 2 is not of type 'Object'