In cursor settings, click features and then add the documentation URL for each framework or library you are using so they can be indexed.
It would be best if you did this regardless of how well trained a model is on certain code - it helps immensely.
FastHTML has markdown formatted docs which can be used by Claude, just add .md to the end of the URL:
https://docs.fastht.ml/ref/handlers.html.md
You can find markdown docs for most libraries on GiHub, where you can have Cursor index.
I suspect that with the increased use of LLM-aware code editors, single-page markdown-formatted documentation will become more common (even better would be if Cursor hosted an external vector db with up-to-date docs and tutorials for all the most popular libraries and frameworks).