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

Improve the docs: add npm examples #1756

Closed
1 task done
edodusi opened this issue Jan 4, 2024 · 3 comments
Closed
1 task done

Improve the docs: add npm examples #1756

edodusi opened this issue Jan 4, 2024 · 3 comments
Labels
documentation Improvements or additions to documentation enhancement New feature or request

Comments

@edodusi
Copy link

edodusi commented Jan 4, 2024

Proposal

In the wiki section, the documentation is clear and exhaustive, but all the examples are done with yarn.

It would be great to add examples using npm as well, and give the reader a way to switch between the two: for many snippets, simply replacing yarn with npm is not enough, as it's clear from the init command that using npm becomes npm exec init-test-app.

Alternatives

I don't know all the possibilities offered by the GitHub wiki, but the ideal solution would be a snippet widget with tabs to switch between yarn and npm, like the react-native docs.

An alternative would be to just present the two snippets one after the other.

Implementation Details

This requires a change to the wiki docs, unfortunately I cannot do a PR 🥲.

Additional Context

example 1

example 2

(PS: it would also be great to have an additional template for GH issues for the docs or general feedback!)

Code of Conduct

  • I agree to follow this project's Code of Conduct
@edodusi edodusi added the enhancement New feature or request label Jan 4, 2024
@kelset
Copy link
Contributor

kelset commented Jan 4, 2024

Thanks for the feedback Edo! We'll look into it :)

@kelset kelset added the documentation Improvements or additions to documentation label Jan 4, 2024
@tido64
Copy link
Member

tido64 commented Jan 8, 2024

I had a look around and it doesn't look like GitHub supports tabs today. It has been requested though (see [1][2]). For now, I've added npm instructions right after the Yarn ones.

Really appreciate that you took the time to file this. Let us know if you find other issues. ❤️

@tido64 tido64 closed this as completed Jan 8, 2024
@edodusi
Copy link
Author

edodusi commented Jan 10, 2024

Thanks @tido64!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants