editor-js/embed

window is not defined

minhhieu1612 opened this issue · 1 comments

I just install and import it through my component, not config or using any parameters yet.
And the react error popup shows the 'ReferenceError: window is not defined' message.
file-path: ~/node_modules/@editorjs/embed/dist/bundle.js
and my dependencies:
{
"@editorjs/checklist": "^1.3.0",
"@editorjs/code": "^2.7.0",
"@editorjs/delimiter": "^1.2.0",
"@editorjs/editorjs": "^2.23.2",
"@editorjs/embed": "^2.5.1",
"@editorjs/header": "^2.6.2",
"@editorjs/image": "^2.6.2",
"@editorjs/inline-code": "^1.3.1",
"@editorjs/link": "^2.4.0",
"@editorjs/list": "^1.7.0",
"@editorjs/marker": "^1.2.2",
"@editorjs/paragraph": "^2.8.0",
"@editorjs/quote": "^2.4.0",
"@editorjs/raw": "^2.3.0",
"@editorjs/simple-image": "^1.4.1",
"@editorjs/table": "^2.0.1",
"@editorjs/warning": "^1.2.0",
"autoprefixer": "^10.4.4",
"next": "12.1.4",
"postcss": "^8.4.12",
"react": "18.0.0",
"react-dom": "18.0.0",
"react-editor-js": "^2.0.6",
"react-icons": "^4.3.1"
}

Please check it and notify me if I miss any steps or you found a solution.
Many thanks,

It looks like this problem was caused by next.js, so just ignore it =))