-
-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Document file path String methods in File paths in Godot projects #9908
Document file path String methods in File paths in Godot projects #9908
Conversation
Calinou
commented
Sep 5, 2024
- See tutorials/io/data_paths godot-docs-user-notes#106 (comment).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mild approval, because I wonder if just that sentence (and maybe one example) is enough, with a link to the class ref.
I'm not a big fan of reproducing the class ref like this, because it tends to produce lots of additional effort with the list getting outdated, people creating issues and PRs, us reviewing + merging + cherrypicking etc. If we can, we should have information once and link to it, instead of duplicating. That said, it can be worth it if its especially important, I'm just not sure thats the case here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with mhilbrunner that this isn't ideal. I think it would be better to just say something like "The string class offers several methods to work with strings that represent file paths, you can find a list of it's class reference page here" and link to the class reference page.
The String class has a lot of methods unrelated to path manipulation, which is why I opted to explicitly list all relevant methods. Otherwise, you'd need to slowly comb through the class to find them all. |
@Calinou That makes sense. Do we maybe want to maintain the list in the class reference for |
As a user of the engine, a list in the File Paths page is clearly the right place for this information. Whether the maintenance burden is worth it is up to you. Putting the list in the class reference page (presumably in the intro section?) and linking also seems fine, but is there any real precedent for listing a subset of methods like that in the class reference? It means that there is a redundant list of the same methods twice (once as a subset, and once in the main methods list), and it clutters the class reference for String if you're looking at it for other reasons. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Given the discussion I'm in favor of merging this as is. I'd also recommend that instead of copying this list in the class reference we should link to this page in the "tutorials" section of the string class.
Merging as per the above. Thank you! |