zenoamaro / react-quill

A Quill component for React.
https://zenoamaro.github.io/react-quill
MIT License
6.79k stars 925 forks source link

Getting error on first load - Error Details: TypeError: Cannot read properties of undefined (reading 'getStackAddendum') #1001

Open makarandkeer opened 2 months ago

makarandkeer commented 2 months ago

I am using "react-quill": "^2.0.0" But I get following error first time when I set value. Following is my React code

<ReactQuill
      theme={"snow"}
      modules={readonly ? { toolbar: false } : modules}
      readOnly={readonly}
      value={value}
      onChange={handleOnChange}
      style={{ height: "90%", position: "relative" }}
    />

I am getting following error. This error goes off when I refresh the page.


Error Details: TypeError: Cannot read properties of undefined (reading 'getStackAddendum')
    at printWarning (webpack://pcf_tools_652ac3f36e1e4bca82eb3c1dc44e6fad/./node_modules/react-dom/cjs/react-dom.development.js?:16:106)
    at error (webpack://pcf_tools_652ac3f36e1e4bca82eb3c1dc44e6fad/./node_modules/react-dom/cjs/react-dom.development.js?:14:369)
    at Object.findDOMNode (webpack://pcf_tools_652ac3f36e1e4bca82eb3c1dc44e6fad/./node_modules/react-dom/cjs/react-dom.development.js?:4933:228)
    at t.getEditingArea (webpack://pcf_tools_652ac3f36e1e4bca82eb3c1dc44e6fad/./node_modules/@sidekick/sidekick-ui/dist/esm/index.js?:51:255404)
    at t.instantiateEditor (webpack://pcf_tools_652ac3f36e1e4bca82eb3c1dc44e6fad/./node_modules/@sidekick/sidekick-ui/dist/esm/index.js?:51:253058)
    at t.componentDidMount (webpack://pcf_tools_652ac3f36e1e4bca82eb3c1dc44e6fad/./node_modules/@sidekick/sidekick-ui/dist/esm/index.js?:51:252256)
    at pu (https://content.powerapps.com/resource/uci-infra-bus/scripts/vendor.fc80bee60c1e78756db7208ca67f34b7.js:9:85614)
    at Nl (https://content.powerapps.com/resource/uci-infra-bus/scripts/vendor.fc80bee60c1e78756db7208ca67f34b7.js:9:102672)
    at t.unstable_runWithPriority (https://content.powerapps.com/resource/uci-infra-bus/scripts/app.7cfa05fae26ee87406cebe5572f461ee.js:14:3768)
    at Wo (https://content.powerapps.com/resource/uci-infra-bus/scripts/vendor.fc80bee60c1e78756db7208ca67f34b7.js:9:44549)
    at Tl (https://content.powerapps.com/resource/uci-infra-bus/scripts/vendor.fc80bee60c1e78756db7208ca67f34b7.js:9:99217)
    at pl (https://content.powerapps.com/resource/uci-infra-bus/scripts/vendor.fc80bee60c1e78756db7208ca67f34b7.js:9:95328)
    at https://content.powerapps.com/resource/uci-infra-bus/scripts/vendor.fc80bee60c1e78756db7208ca67f34b7.js:9:44772
    at t.unstable_runWithPriority (https://content.powerapps.com/resource/uci-infra-bus/scripts/app.7cfa05fae26ee87406cebe5572f461ee.js:14:3768)
    at Wo (https://content.powerapps.com/resource/uci-infra-bus/scripts/vendor.fc80bee60c1e78756db7208ca67f34b7.js:9:44549)
    at Qo (https://content.powerapps.com/resource/uci-infra-bus/scripts/vendor.fc80bee60c1e78756db7208ca67f34b7.js:9:44717)

Can someone help me to resolve this issue?

Ezreal09 commented 1 month ago

Are you using an array? You need to add a key to each element.