nextjsargentina / next.js-docs

Open-source Next.js v14 documentation project, aimed at enhancing AI training with LLMs and providing the latest updates on The React Framework for the Web.
https://nextjs.org/docs
MIT License
16 stars 3 forks source link

PDF document flaw - mixed content #3

Open myrddral opened 1 month ago

myrddral commented 1 month ago

I've been using the PDF docs in this repo as source of truth for LLMs to provide better coding assistance (currently using Cursor.sh).

Issue: I was not satisfied with the correctness of answers in relation to differentiating APIs for app/pages router. Even 4o and Claude 3.5 kept suggesting to use getStaticProps function for a project that uses the app router.

Source of problem: I was puzzled and wanted to get to the bottom of this. After I confirmed with the LLM that it has access to indexes of the entire codebase as well as the attached documentation referenced from your repo, I found that the PDF contains information for BOTH routers at the same time without any way to differentiate. The official docs website is correct though, because it parses the MDX content with its JSX components embedded, like . This component is crucial to determine the correct information to display for a given router, and it's just iignored by regular markdown parsers.

Proposed solution: Generate the PDF docs in a way that takes into account the appearance of and components in the MDX files.

getong commented 1 month ago

Nextjs 15.0.1 is relased, will it be updated?