I'm building NextJS chrome extension, the problem that I'm facing is that when I 'load unpacked' extension it say that "Cannot load extension with file or directory name _next. Filenames starting with _ are reserved for use by the system."
I have checked some solutions online which says that renaming '_next' to 'next' and then changing all '_next' to 'next' in the 'out' directory should work.
the commands for the above tasks are
rm -rf .next/ out/
rm extension.zip
npm run build
npm run export
mv ./out/_next ./out/next
cd ./out && grep -rli '_next' * | xargs -I@ sed -i '' 's/_next/next/g' @
zip -r -FS ../my-extension.zip *
I have checked the above commands but it changes my styles and routing doesn't work after that.
before changing '_next' to 'next' my extension looks like this in the browser

after moving '_next' to 'next' in the 'out' directory,
mv ./out/_next ./out/next
my extension looks like this in the browser.
Note: I know that i have to change all the chunks which include '_next' to 'next' in the 'out' directory, but I don't know how to do that, because when I run
cd ./out && grep -rli '_next' * | xargs -I@ sed -i '' 's/_next/next/g' @
the output it gives me is:
$ cd ./out && grep -rli '_next' * | xargs -I@ sed -i '' 's/_next/next/g' @
sed: can't read s/_next/next/g: No such file or directory
sed: can't read s/_next/next/g: No such file or directory
sed: can't read s/_next/next/g: No such file or directory
sed: can't read s/_next/next/g: No such file or directory
sed: can't read s/_next/next/g: No such file or directory
sed: can't read s/_next/next/g: No such file or directory
sed: can't read s/_next/next/g: No such file or directory
sed: can't read s/_next/next/g: No such file or directory
sed: can't read s/_next/next/g: No such file or directory
sed: can't read s/_next/next/g: No such file or directory
sed: can't read s/_next/next/g: No such file or directory
sed: can't read s/_next/next/g: No such file or directory
sed: can't read s/_next/next/g: No such file or directory
sed: can't read s/_next/next/g: No such file or directory
sed: can't read s/_next/next/g: No such file or directory
kindly guide me, how can I rename all '_next*' to 'next*' in the this directory.
Thank you for your precious time.