Confusion with Script inside _document file and no-script-in-document-page ESLint rule #37413
|
I'm trying to add a Script with Does anyone know which is the correct way of using scripts with Some environment info: |
Replies: 2 comments 4 replies
|
Hi, The NextJS family of packages ought to be at the same version, otherwise this kind of thing happens. Please update to A bug 🐛In version 12.1.6, AFAIK, the |
|
@icyJoseph Thank you for the quick response. What would be the equivalent of |
Hi,
The NextJS family of packages ought to be at the same version, otherwise this kind of thing happens. Please update to
eslint-config-next12.1.6. The same applies if you have@next/bundle-analyzer.A bug 🐛
In version 12.1.6, AFAIK, the
beforeInteractivescripts in_document, are not really working... #37000, it has been fixed, but the fix was not as desired... #37225 (comment), there has been a bit of a back and forth... #37084, so for now, I'd say under 12.1.6, please use a regular script, and as soon as a new version comes out switch back tonext/scriptwithbeforeInteractiveset.