Skip to content
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

Update the examples folder with a real example #1556

Closed
Gerrit0 opened this issue Mar 29, 2021 · 4 comments · Fixed by #1726
Closed

Update the examples folder with a real example #1556

Gerrit0 opened this issue Mar 29, 2021 · 4 comments · Fixed by #1726

Comments

@Gerrit0
Copy link
Collaborator

Gerrit0 commented Mar 29, 2021

The examples/basic folder might have originally contained an example, but has been used for UI tests for a really long time. Conflating these two things was a bad idea, since it means that the examples folder that ~80 people look at every week contains almost useless info.

@Gerrit0 Gerrit0 added the docs label Mar 29, 2021
@Gerrit0 Gerrit0 added this to To do in Version 0.22 via automation Mar 29, 2021
@Gerrit0 Gerrit0 added this to To Do in Version 0.22 Aug 1, 2021
@Gerrit0 Gerrit0 removed this from To Do in Version 0.22 Sep 5, 2021
@Gerrit0 Gerrit0 added this to To do in Guides (#247) - v0.24 via automation Sep 5, 2021
@srmagura
Copy link
Contributor

I could work on this if you want @Gerrit0.

What should the existing examples folder be renamed to? testProjects?

What would you like to see in the new example? I have a variety of already-commented code that I could pull from. Or I could write some new code just for this.

@Gerrit0
Copy link
Collaborator Author

Gerrit0 commented Sep 24, 2021

That would be great! I'm not too particular about what to call the visual tests - it might actually be best to move it into src/test/renderer.

Ideally what I'd like to see in an example is something that shows how TypeDoc handles language constructs, so something with exported variables, classes, functions, overloaded functions, etc...

I'd also like to include features which people might not immediately think about, like a class X extends Array<string> which resolves the type parameters in inherited methods, and other special casing, like changing as const variables into enums with @enum (#1675), detecting variable-functions and displaying them as functions, exporting the same variable under an alternative name... probably other stuff I'm missing.

Once this is done, I'd really like to prominently link to both the example folder and generated documentation on the website.

@srmagura
Copy link
Contributor

Thanks for the guidance 🙂. I will probably work on this this weekend.

  • I think the example folder should have its own package.json and tsconfig.json. I was planning on adding React as a dependency of the example project so that I can show how to document a React component.
  • Do you want the generated documentation to be committed or gitignored?

@Gerrit0
Copy link
Collaborator Author

Gerrit0 commented Sep 25, 2021

Separate package/config - I agree. React sounds fine.

The generated output should be .gitignored, it will be published on typedoc-site, but I think rebuilding it like /api is done today is the right way to go about it.

srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 2, 2021
srmagura added a commit to srmagura/typedoc that referenced this issue Oct 3, 2021
Guides (#247) - v0.24 automation moved this from To do to Done Oct 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

2 participants