beefytech / Beef_website

BeefLang website
Other
21 stars 18 forks source link

"global" docs searching #32

Closed EinScott closed 2 years ago

EinScott commented 3 years ago

Searching for a string and getting the list of pages the string appears on (maybe with a few matches) would be pretty cool. I feel like this would improve the usability and usefulness of the docs a lot, as currently there is a STRG F like search bar at the top, but searching through all docs doesnt seem to be possible.

There is a pretty managable number of pages, which is great for getting into the language, but when you return to look up something specific, that can be very difficult since you may not know which pages details what you need.

For example, I never read the "projects and workspaces" page, and was searching for all available macros. Now, of course putting the macros into that page since they operate on these levels makes a lot of sense, but if you need to look that up, you may not know it and your brain might just filter the page out as unrelated (brain filtering can be pretty trash, wouldn't recommend). Similarly, someone wants to find out about how access modifiers work (for example, a c# guy's "how does internal work here? why can't my own assembly use their internals?"). It makes sense for them to be on the page about members, since thats the context in which they are useful, but it's hard to get there.

disarray2077 commented 2 years ago

I would like to mention the hugo theme "Docsy", this was mentioned by @Booklordofthedings in Discord and I think it would be a great solution to this issue. Website: https://themes.gohugo.io/themes/docsy/

EinScott commented 2 years ago

Yeah i've read that too. I also think it's a really good theme, but it's probably also a significant effort. Thing is, docsy needs a newer hugo version. I've invested one evening just to scout out the basics but i've got no clue about hugo (or web in general for that matter). I didn't look too far into it. The website uses two themes, one for the main page, another for the docs. Docsy requires a newer hugo version unless we get like some older version maybe, depending on how far the project goes back, dunno. Newer hugo doesn't like the old themes. We could go for just docsy but we'd lose the main page. We could get something different entirely or a newer version (if existant?) of the main page theme. Maybe there's a possibility of cobbling something together to get both. Either way, it's probably a matter of getting a clean theme, copying the markdown over to wherever it goes and trying to set up a the config to get something roughly equivalent.