-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Add API Reference and Guides for TypeScript in docs #2266
base: main
Are you sure you want to change the base?
Conversation
Created new markdown files for API Reference and Guides under TypeScript development. Updated sidebar configuration to include these new sections and added corresponding links and placeholders.
This guide covers prerequisites, type imports, and usage examples for working with Strapi documents and components using TypeScript. It includes detailed sections on generic and known entities, advanced use-cases, and type argument inference to enhance type safety and development efficiency.
Updated the tags in the TypeScript development documentation to include 'api reference' and 'guides' for better categorization and easier navigation. This helps users find relevant information more efficiently.
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
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.
Thank you, JS! Super useful changes.
I left lots of purely technical writing-oriented comments.
Happy to discuss things with you if you want, or just apply most of them, depending on what you prefer 🤗
docusaurus/docs/dev-docs/typescript/development/guides/documents-and-entries.md
Outdated
Show resolved
Hide resolved
docusaurus/docs/dev-docs/typescript/development/guides/documents-and-entries.md
Show resolved
Hide resolved
docusaurus/docs/dev-docs/typescript/development/guides/documents-and-entries.md
Outdated
Show resolved
Hide resolved
docusaurus/docs/dev-docs/typescript/development/guides/documents-and-entries.md
Outdated
Show resolved
Hide resolved
docusaurus/docs/dev-docs/typescript/development/guides/documents-and-entries.md
Show resolved
Hide resolved
- reference | ||
--- | ||
|
||
# API Reference |
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.
Until this page has some more content, I'd suggest we don't link to it from the sidebar and the TypeScript intro. page.
If you want to inform users that an API reference is in the works, I'd suggest you use the special :::strapi
callout in the TypeScript development intro. page.
See my comment in the TypeScript development file :)
|
||
--- | ||
|
||
import NotV5 from '/docs/snippets/_not-updated-to-v5.md' | ||
|
||
# TypeScript Development with Strapi |
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.
We should always introduce the page to readers, so they know what it is about (obvious with the title, I know), what the 'feature' or topic is about, but also what they can expect to find on the page, and who will find this page useful.
What do you think we could add here?
- guides | ||
--- | ||
|
||
# TypeScript Guides |
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.
Same comment about having at least a short introduction. We could link to other pages for context, for instance. At a minimum, we could have something like this:
# TypeScript Guides | |
# TypeScript guides | |
This page includes a curated list of common examples useful to use types while [developing a Strapi TypeScript application](/dev-docs/typescript/development). |
- entries | ||
--- | ||
|
||
# Manipulating documents and entries |
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.
It would also be nice to have a small introduction for this page, too 🙏
…ts-and-entries.md
…ts-and-entries.md
…ts-and-entries.md
…ts-and-entries.md
…ts-and-entries.md
…ts-and-entries.md
…ts-and-entries.md
…ts-and-entries.md
…ts-and-entries.md Co-authored-by: Pierre Wizla <[email protected]>
…ts-and-entries.md Co-authored-by: Pierre Wizla <[email protected]>
…ts-and-entries.md Co-authored-by: Pierre Wizla <[email protected]>
Co-authored-by: Pierre Wizla <[email protected]>
Co-authored-by: Pierre Wizla <[email protected]>
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.
Looks good so far, just had some of the same comments as Piwi had
What does it do?
Add the first version for the first typescript guide in the documentation
Why is it needed?
Part of our effort to ease the adoption of TypeScript in Strapi