PlasmoHQ / docs

📘 Documentation site
https://docs.plasmo.com
12 stars 50 forks source link

docs throws an application error after enabling page translation #68

Open aiktb opened 1 year ago

aiktb commented 1 year ago

I use page translation to view plasmo documents, but when I turn on page translation and browse multiple pages, the page will throw an exception, and I have to refresh the page to continue browsing the document. I have this issue when translating web pages into Chinese or German. Only Chrome's web translation causes the issue, Edge doesn't have the issue.

Can you try to fix this bug?

Application error: a client-side exception has occurred (see the browser console for more information).

Snipaste_2023-08-01_19-52-11

framework-0a897eab13466586.js:9 DOMException: Failed to execute 'removeChild' on 'Node': The node to be removed is not a child of this node.
    at uH (https://docs.plasmo.com/_next/static/chunks/framework-0a897eab13466586.js:9:84988)
main-23c1aa3ceb058a6c.js:1 DOMException: Failed to execute 'removeChild' on 'Node': The node to be removed is not a child of this node.
    at uH (https://docs.plasmo.com/_next/static/chunks/framework-0a897eab13466586.js:9:84988)
main-23c1aa3ceb058a6c.js:1 A client-side exception has occurred, see here for more info: https://nextjs.org/docs/messages/client-side-exception-occurred

Snipaste_2023-08-01_19-54-17

louisgv commented 1 year ago

Interesting... I wonder if there's a nextjs setting we can enable to prevent this type of behavior :-d...

aiktb commented 1 year ago

Interesting... I wonder if there's a nextjs setting we can enable to prevent this type of behavior :-d...

It's strange, I try to deploy the main branch locally and on the server, but I can't reproduce the bug, use the following command:

pnpm install
pnpm build
pnpm start --port=8080

Is there something wrong with the way I'm deploying? Or maybe this is not a bug caused by React or Next programming, did you use the js/html Auto Minify function (provided by CDN)?

louisgv commented 1 year ago

@aiktb I don't think so. The docs is deployed on vercel :d.....