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

Seed a glossary #438

Merged
merged 5 commits into from
Nov 13, 2023
Merged

Seed a glossary #438

merged 5 commits into from
Nov 13, 2023

Conversation

dnadales
Copy link
Member

Motivation: we usually write documentation (both in the website, but also in our GitHub issues) that refers to frequently used concepts (eg Chain Growth Property, Active Slot Coefficient). Both readers and writers would benefit from having such a glossary: the writers can easily refer to these concepts without having to explain then over and over, and the readers can have a handy reference they can use when they find an unknown concept.

@dnadales dnadales requested a review from a team as a code owner October 13, 2023 16:49
@dnadales
Copy link
Member Author

Rendered pages:

image

image

In this example, one of the references links to the other.

Copy link
Contributor

@nfrisby nfrisby left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I posted a suggestion in a GitHub comment.

Also, the Tweag Genesis team developed a big glossary when @amesgen and I were onboarding the new members. I'm pretty confident we could just copy that over.

What do you think?

@@ -33,6 +33,13 @@ const sidebars = {
label: 'For Developers',
items: [
'for-developers/index',
{
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suspect that we'll end up with several tens of these terms.

So I propose a single Glossary.md file, in which people can use CTRL-F to find something. And hopefully HTML anchors will let us link to specific definitions within that file.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point. I'll add that file. The only problem is that linking to files not in the sidebar makes it disappear. So I'll see if I can figure out a way to solve this.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not great because people would need one extra click to access the index, but it's the only option I could find.

image

@dnadales
Copy link
Member Author

I posted a suggestion in a GitHub comment.

Also, the Tweag Genesis team developed a big glossary when @amesgen and I were onboarding the new members. I'm pretty confident we could just copy that over.

What do you think?

I think that's a great idea! Should we do it in a follow-up PR to keep the scope small?

@nfrisby
Copy link
Contributor

nfrisby commented Oct 16, 2023

I hope to open a PR with the lexicon ASAP---just waiting for the go ahead. I suspect it supersedes this PR (eg it has these two entries already), but I'll leave that for you to judge :)

@dnadales dnadales self-assigned this Oct 16, 2023
@dnadales
Copy link
Member Author

Waiting on Tweag glossary.

@nfrisby
Copy link
Contributor

nfrisby commented Oct 23, 2023

I sent you the Tweag lexicon, on Slack. (Clarke and Kowalsky on the Tweag side both said it'd be fine for me to do that.)

@dnadales dnadales force-pushed the dnadales/seed-a-glossary branch from 3b5abb0 to 0a2e075 Compare October 24, 2023 15:37
@dnadales dnadales force-pushed the dnadales/seed-a-glossary branch from 74f22b7 to 704ca17 Compare October 30, 2023 14:52
@dnadales dnadales changed the title Seed a glossary with two entries. Seed a glossary Oct 30, 2023
Copy link
Contributor

@nfrisby nfrisby left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great; thanks for reformatting.

One minor comment, about structure/maintainable as opposed to content.


## Anchor

A [chain fragment](#Prefix/tip/etc-and-fragment) always has an anchor [point](#point), which is the predecessor of the oldest [header](#header)/[block](#block) on the fragment.
Copy link
Contributor

@nfrisby nfrisby Nov 2, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor suggestion: If every wiki-ish links like the ones you've added is targeting this same document, then my intuition is that we don't need them.

  • They'll be a burden to maintain if we rename things, etc.
  • They make the Markdown itself less legible.
  • If someone is reading a description on this page and they see a word they don't recognize/etc, they should be able to CTRL-F to find its definition. To make this easier, we could add a symbol that's unique to the definition of the word, such as ## defn:Block and so on. So if you want to find the definition of a word foo, you CTRL-F for defn:foo. (A very tame JavaScript one-liner can automate this: document.querySelectorAll("h2").forEach(function (e) { e.innerHTML = "defn:" + e.innerHTML.trim(); }) eg at https://jsfiddle.net/c8ustjzh/.) Or maybe some cheeky symbol, such as ‡ instead of defn:?

That'd be much less noisy, easier to maintain, and only slightly less convenient to use.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They'll be a burden to maintain if we rename things, etc.

I think Docusaurus check for broken links. We still have to fix these, but I don't think we'll change headings such a ## Slots very often.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

they should be able to CTRL-F to find its definition

This might be a problem. For instance, consider the word "slot" or even the mention of k or scg. It might take ~1 minute to hit CTRL-F till they find the right definition. So we need at least at defn:foo in the headers, as you suggested.

Or maybe some cheeky symbol, such as ‡

I think it's better if we use something people can easily type :D

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

## :block
## :slot
## :header

would probably suffice IMO and not be too much visual noise.

I think it's better if we use something people can easily type :D

Good point! It will at least essentially always be on the screen and so possible to copy onto the clipboard 🤷

Copy link
Contributor

@nfrisby nfrisby Nov 9, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest: we use simply the leading colons.

Bonus script at the bottom of the file to make them visually softer than the word: document.querySelectorAll("h2").forEach(function (e) { e.innerHTML = e.innerHTML.replace(':','<span style="color: rgba(0, 0, 0, 0.5);">:</span>';) })

@dnadales dnadales enabled auto-merge November 13, 2023 10:52
@dnadales dnadales added this pull request to the merge queue Nov 13, 2023
Merged via the queue into main with commit 383cb71 Nov 13, 2023
12 checks passed
@dnadales dnadales deleted the dnadales/seed-a-glossary branch November 13, 2023 11:13
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.

2 participants