files with an S. There's no mixing of files that have require() anywhere in them. When I fist read the above I was hoping I wouldn't have to refactor so much files. Renaming files to .mjs serves no purpose that I see. You are going to have to refactor all the require statements in the code no matter what. The additional labor of renaming files feels pointless.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
"or renaming your .js file to .mjs"
files with an S. There's no mixing of files that have require() anywhere in them. When I fist read the above I was hoping I wouldn't have to refactor so much files. Renaming files to .mjs serves no purpose that I see. You are going to have to refactor all the require statements in the code no matter what. The additional labor of renaming files feels pointless.