I noticed that when I add files: [] in package.json, the following error appears:
Couldn't find a
pagesdirectory. Please create one under the project root
Is this a bug?
If not, it would be great to document this.
This is not a bug. What's happening is your files are not included in the project.
See: https://docs.npmjs.com/files/package.json#files
So, use the files wisely or remove it.
I put files: [] intentionally there, as I was planning to publish some files to npm later.
Why is publishing to npm bound to publishing via now?
Ideally, I'd like to publish only a subset of all my app files to npm.
What if now checked nextFiles rather than files in package.json?
@moroshko Actually this is not a Next.js issue. Try asking it from the now repo(or from the channel) for more info.
i have same issue using next.js in docker. how to resolve it ?
Hello, i have the same problem. I run npm as user, the owner is me, next.js do not create folder dist.
Thx
@to-kra How did you solve it with Docker?
This thread has been automatically locked because it has not had recent activity. Please open a new issue for related bugs and link to relevant comments in this thread.
Most helpful comment
i have same issue using next.js in docker. how to resolve it ?