Open onmyway133 opened 11 months ago
It work till there but when i write JavaScript code in my page.js file it compiled it but when i uploaded that extension to chrome it shows CSP error and is not executing that script which is written in page.js file
We can develop Nextjs 13 apps and export it to a Chrome extension.
Start by init the project
Here is the project structure with app router and not using
src
directory. I put anextension
to the root of the project, where we can copy over the generatedout
folderHere is my script to build and copy over generated
out
and publicimages
toextension
folderpackage.json
We need to specify export mode in
next.config.js
so we can justnext build
We should also ignore generated content in
extension
. Add this to your.gitignore
file