Skip to content

Dropdown for doc on main page #1508

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

Merged
merged 4 commits into from
Sep 3, 2024
Merged

Conversation

NotTheDr01ds
Copy link
Contributor

Floating an idea ...

"Ref" is just too short and ambiguous to describe the "Language Reference Guide" on the main page navbar.

What about grouping the "Documentation" together into its own dropdown? This allows us to provide a full and descriptive name for each doc link.

@NotTheDr01ds
Copy link
Contributor Author

NotTheDr01ds commented Aug 18, 2024

Note - I haven't done this for the other language translations since they don't have the Command Reference nor the Language Reference Guide (yet). For now, I'd recommend leaving those as-is.

@NotTheDr01ds
Copy link
Contributor Author

@fdncred @sholderbach @hustcer

Thoughts?

@fdncred
Copy link
Contributor

fdncred commented Aug 20, 2024

I'm on the fence about it. I kind of like what we have but could be convinced to try a menu too.

@NotTheDr01ds
Copy link
Contributor Author

I'd be okay if we had more space to fit something other than "Ref" ;-)

@hustcer
Copy link
Contributor

hustcer commented Aug 21, 2024

How about change it to:

- Book
- Commands
- Blog
- Others
     - Contrib
     - Cookbook
     - Ref

?

@NotTheDr01ds
Copy link
Contributor Author

@hustcer It sounds like you want to keep the Book and Commands at the top level.

I kind of understand the Book link as a "Getting Started" top-level (and some more thoughts on that below), but I'm not sure that I understand wanting the Commands to be top-level? As someone who accesses the Commands reference at least once-a-day myself, I think having it behind the hover-dropdown is still really convenient.

Comparing other shells' and programming languages' top-level links

None of these put any actual documentation, other than install, at the top-level. Even "The Book" for Rust is on a separate page.

Let me know your thoughts, but I consider:

  • The primary purpose of the main page to be the best introduction possible for potential new users who are interested in learning about Nushell.
  • An important secondary purpose is to have quick-access to important information for established users.

As such, I'd propose:

- Get Nu!
- Getting Started
- Documentation
     - The Nushell Book
     - Command Reference
     - Cookbook
     - Language Reference Guide
     - Contributing Guide
- Blog

Thoughts:

  • The "Get Nu!" could also be called "Install" - Either way, I think it's important that this be a top-level link. It's position left-to-right isn't all that important, I don't believe.

    This would link to the Book chapter on Installation. I'd like to move that Chapter out of "Getting Started" and up to its own top-level chapter right after "Introduction" in the Book.

    Bonus: It still links to the Book, just a specific chapter.

    And yes, we have a brief section if you scroll down on how to "Get Nu", but IMHO this isn't visible enough. It also focuses on a bit of an odd "subset" of the installation methods. Nix, for example, is usually a few weeks behind on updating (even in Unstable) to the latest release. The latest Stable is 0.93.

  • The Book's "Getting Started" and subchapter "Quick Tour" are great (kudos to whoever wrote that). It hits just the right set of topics to get a new user introduced to Nushell. Putting it as a navbar top-level link would also jump someone into the book, but at the point where it most benefits new users.

Side-Note: I get that we're trying to style ourself after the "Book" in Rust, but even that isn't titled "The Book". It's "The Rust Programming Language" there. I think it's better to be explicit in the link/title, but then we can (as with Rust) informally refer to it as the Book. I'm probably treading on some "convention" that folks might be loathe to break, but I'm hoping "The Nushell Book" is a good middle-ground. We could always leave it "Book" in the link, but I'm just floating something more descriptive, especially (again) for new users who might not have the Rust background to appreciate the reference.

@NotTheDr01ds NotTheDr01ds marked this pull request as draft August 26, 2024 12:35
@hustcer
Copy link
Contributor

hustcer commented Aug 28, 2024

@NotTheDr01ds Thanks for the detailed explanation, I'm not very good at this, and these changes are acceptable to me, so it's better to see what everyone else has to say about it

@fdncred
Copy link
Contributor

fdncred commented Aug 28, 2024

IMO, it's just software. If we don't like it, we can revert/change it. I'd vote to land it and see how we like it.

@NotTheDr01ds
Copy link
Contributor Author

@hustcer No worries - I won't claim to be an expert here either, but I'm happy to help with some ideas and research.

@fdncred Agreed, but given our discussion during the weekly, I'll try to find a spot for "This week in Nu" before bringing this out of draft. I have one other related update I need to push first, then I'll come back to this one.

@NotTheDr01ds NotTheDr01ds marked this pull request as ready for review August 29, 2024 14:31
@NotTheDr01ds
Copy link
Contributor Author

Alright - I've added a link to "This Week in Nu". This probably means moving the Blog and ThisWeek under a dropdown for "News".

I'd love to keep the Blog at the top level, but grouping it with ThisWeek seemed the best fit. Open to other ideas, though.

@fdncred Up to you on whether you want to land it as suggested above or perhaps wait 24 hours for any feedback on the latest.

@fdncred
Copy link
Contributor

fdncred commented Aug 29, 2024

Seems like we wouldn't want to update the docs every week to point at this week's specific TWiN. Maybe it's better to point to a folder with all of the list by date in reverse?

@NotTheDr01ds
Copy link
Contributor Author

cc: @rgwood

Seems like we wouldn't want to update the docs every week to point at this week's specific TWiN. Maybe it's better to point to a folder with all of the list by date in reverse?

Right - I guess I should have gone into more detail on the issues and possible solutions here.

I'd love to be able to point to something static (eventually), but that's going to require some other changes. For now, I chose to link to the latest, and then once we come up with a better solution we can link to the static page.

So right now, "This Week in Nu" is, of course, a separate repo. All of the weekly files are simply tossed in the root of that repo, and given the numbering system, the only sorting possible is alphabetical.

I spent a few minutes looking at having a make_twin.nu script that would read the repo, find the latest add, and update the link to that. But that's still a weekly, manual process. Perhaps it could be automated through a GitHub action - not sure.

I'm thinking maybe the solution is to have some statically named file that represents this week's TWiN, perhaps the README.md in the repo. Each week, the latest update could simply be the README.md, with the link hardcoded to that (and never changing). Then on the subsequent week, README.md is renamed to "This week in Nu [nnn].md" and the new README.md is created.

Ideas welcome here.

@NotTheDr01ds
Copy link
Contributor Author

@rgwood Btw, in case no one mentioned it, during yesterday's weekly, someone brought up the idea of using This Week in Nu to potentially highlight some of the community work like Maxim's YouTube videos (after review). I mentioned that there was currently no link (that I'm aware of) from the main page or doc to TWiN, and everyone was in strong agreement that we should add a link so that your work is more prominent.

That's what I'm attempting to address in these latest commits.

@rgwood
Copy link
Contributor

rgwood commented Aug 30, 2024

Thanks for the context. I won't have time to work on this anytime soon, but yeah if we could automate something to have a static link to the latest TWiN that would be great.

@fdncred
Copy link
Contributor

fdncred commented Aug 30, 2024

We could also just move the TWiN into this repo if that makes it easier to put in the docs. We'd need to get some consensus though.

@rgwood
Copy link
Contributor

rgwood commented Aug 30, 2024

I don't feel strongly about where it lives; as long as the process of uploading it to GitHub stays easy, any repo is fine.

@NotTheDr01ds
Copy link
Contributor Author

We could also just move the TWiN into this repo if that makes it easier to put in the docs

The big advantage to having it in the repo directly would be that we could serve it through VuePress (or successor) and it can be formatted more nicely than just displaying it in the GitHub UI. It can also pick up things like ::: warning tags, etc.

Either way, though, it's going to require some automation in order to get a static link.

In the meantime, we have two options, I believe:

  • Update manually every week
  • Take out the link for now and revisit this when we move things over later

Which way do we want to go? I think that's the one remaining thing to lock down before this lands?

@fdncred
Copy link
Contributor

fdncred commented Sep 1, 2024

I don't want to put more burning on Reilly or his fill-in to update another thing for TWiN. So, my suggestion would be to leave it out now until we have a good, automated solution. I'd like to list them all by date with the most recent on top.

@NotTheDr01ds
Copy link
Contributor Author

Ok, I've dropped the link to TWiN and reverted "Blog" to the top level. Should be good to land based on previous comments.

@fdncred fdncred merged commit 23e1824 into nushell:main Sep 3, 2024
2 checks passed
@fdncred
Copy link
Contributor

fdncred commented Sep 3, 2024

Let's try it out

@fdncred
Copy link
Contributor

fdncred commented Sep 3, 2024

nice!
image

@NotTheDr01ds NotTheDr01ds deleted the navbar-dropdown branch October 1, 2024 02:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants