Hello again, open web
Why I write on a site of my own, and what it is built with: MyST for the posts, permalinks for proper citations, and the AT Protocol for interactions.
I missed writing. I wanted to share thoughts, ideas, essays and projects for far too long.
Authoring is a crucial skill to me, for both work and personal expression. It’s a consuming exercise, sometimes emotional and introspective, but deeply human and always reflective. The journey of crafting a coherent piece of text is highly underrated. Now that AI and large language models are disrupting everything, I’ve come to value the exercise of writing more than ever.
Owning the space and the format
The best format will always be the one we shape to match our expression. The best space will always be safe and open. Own the format and the space, or your expression will be framed into someone else’s space, under someone else’s rules.
In this personal space, I’ll put out my thoughts, all under my control. No platform’s rules, no feed’s algorithm, no owner’s tantrums. Just web standards and a few effective lines of code.
I also had ideas and aspirations for experiments around publications, sharing and social networking. Some of the key starting points are MyST for publications, permalinks for accurate sharing of content, and Bluesky and the AT Protocol for networking, aka reactions.
MyST
MyST (Markedly Structured Text) is a brilliant open source project. In a nutshell, it is Markdown as CommonMark specifies it (MacFarlane, 2024), extended for technical and scientific authoring (Cockett et al., 2024).
The MyST project offers much more, but what really caught my attention is its parser and HTML transformers for this Markdown flavour.
MyST is great for technical writers, coders, academics, mathematicians, and more, but I believe the scientific and academic rigour it enables can also benefit many web publications, especially when it comes to referencing and citing other works and authors.
Plain Markdown has no syntax to cite a work, to number a figure or to refer to one, so every blog adds its own. MyST defines them once, and its parser takes new directives: the snippets and the linked quotes below are two that this site adds.
What follows is some of what this site renders using MyST, in this post itself, whose source is a Markdown file.
Citations
A post lists a BibTeX file in its frontmatter and cites its works by key. The cited works are listed under “References” at the end of the post, and each citation links to its entry:
Markdown as CommonMark specifies it [@commonmark].A key without brackets names the authors in the sentence: Van de Sompel et al. (2019) defined the link a page uses to say how it should be cited, which the permalinks of this site rely on.
Snippets
A snippet is a small piece of HTML, CSS and JavaScript, shown as it renders, then as it is typed. It is numbered like a figure, and a reference to its label takes the number: Example 1 highlights a passage of its own.
Example 1: A passage that a button highlights
The demo runs on the site: see it or edit its sources.
HTML
<p>
Acme ships on Tuesdays.
<span id="ex-highlight-passage">Orders placed after noon go out the week after.</span>
</p>
<button id="ex-highlight-button">Highlight the passage</button>CSS
button {
margin-top: 0.5rem;
padding: 0.25rem 0.75rem;
border: 1px solid currentColor;
border-radius: 0.25rem;
cursor: pointer;
}
.highlighted {
background: Mark;
color: MarkText;
}JavaScript
const passage = document.getElementById('ex-highlight-passage')
document.getElementById('ex-highlight-button').addEventListener('click', () => {
passage.classList.toggle('highlighted')
})The demo is part of the page, not a frame, so its text is the post’s: it can be selected, searched and linked to. Because it has a label, it also has a page of its own, and with ?source a bench where its sources can be edited. The two icons that end its caption lead there: to the bench and to the page.
Linked quotes
A linked quote is of a page on the web, and its link leads to the words quoted, not only to the page. Its address is the one a browser gives with “Copy link to highlight”, ending with a text fragment (#:~:text=…):
The core use case for text fragments is to allow URLs to serve as an exact text reference across the web.
URL Fragment Text Directives, wicg.github.io
What is shown is read from the page each time the site is built, and compared with what the post wrote. When the page no longer says it, the quote says so.
Permalinks
A post changes after it is published, and a link to it should still lead to what was read. Every commit of a post has a page of its own, its permalink. The post lists its versions, each with a link to its page, and an earlier version says that it is one. The permalink of the latest version leads to the post itself, for as long as the post shows it.
A snippet follows its post: each version has the pages of its snippets too, the demo and its bench as they were at that commit. As it should.
Each page says in its head what it is. A version names the post’s page as canonical, so that a search leads to the post. The post’s page names its latest version as cite-as (Van de Sompel et al., 2019), so that a reference can name the version it read. Each also names the history, the latest version and its neighbours in it, with the links made for that (Brown et al., 2010).
I think any authored content worth mentioning or referencing, scientific or not, owes its readers an immutable chain of its changes: something to reference, to cite, a minimum of traceability, so that we keep building on the foundations of hyperlinks as Tim Berners-Lee thought of them (1998):
Cool URIs don't change
Tim Berners-Lee, w3.org
Cooler content keeps its versions.
A link does not say when its page has changed. The quotes above tell me when a page moves under what I quoted; the least I can do is not to pull the same rug from under whoever links here.
A link to words of a version keeps finding them after the post moves on, which a link to the post cannot promise. That is what the #:~:text= at the end of the quote’s address above is about. It is a browser feature (Burris & Bokan, 2023): select some text, copy a link to the highlight, and the address carries the selection.
In the next posts I will delve much more into URL text fragments, as they are IMHO vastly underappreciated and a truly missing piece for fine-grained connected links on the World Wide Web.
Reactions on Bluesky
Social interactions, reactions, networking: none of it should happen in a silo. A comment system that lives only on this site would be dumb. Leaving it to an external social network that works as a centralised silo, where nobody owns their content or their relations and everybody is manipulated by obscure algorithmic rules, would be even dumber.
This is why the posts here rely on the AT Protocol, through Bluesky, for their reactions. The replies to a post on Bluesky are shown under the post here, with its counts of likes, reposts and quotes, and a link to reply there. Each reply is a record in its author’s own repository, which this site only reads: I hold my posts, not other people’s words.
The idea is not mine. I took it from Emily Liu (2024), whose post says it best:
Your blog's comment section can be pulled directly from Bluesky.
Emily Liu, emilyliu.me
She had its first lines of code from Samuel Newman, who had done the same on his own blog months earlier (2024).
Bluesky is not perfect. It is one opinionated implementation of the AT Protocol, with feeds of its own, even if they are open and chosen by whoever reads them. Most of the network’s servers are still run by one company, and a reader’s browser asks them for the replies. For now it is the least bad solution I have found.
And it leaves the conversation open: reply to this post on Bluesky, and your words, still yours, show up right below.
References
- Berners-Lee, T. (1998). Cool URIs don’t change. https://www.w3.org/Provider/Style/URI
- Brown, A., Clemm, G., & Reschke, J. (2010). Link Relation Types for Simple Version Navigation between Web Resources (RFC No. 5829). Internet Engineering Task Force. https://www.rfc-editor.org/rfc/rfc5829
- Burris, N., & Bokan, D. (2023). URL Fragment Text Directives [Draft Community Group Report]. Web Platform Incubator Community Group. https://wicg.github.io/scroll-to-text-fragment/
- Cockett, R., Purves, S., Koch, F., & Morrison, M. (2024). Continuous Tools for Scientific Publishing: Using MyST Markdown and Curvenote to encourage continuous science practices. Proceedings of the 23rd Python in Science Conference, 121–136. 10.25080/nkvc9349
- Liu, E. (2024). Using Bluesky posts as blog comments. https://emilyliu.me/blog/comments
- MacFarlane, J. (2024). CommonMark Spec. https://spec.commonmark.org/0.31.2/
- Newman, S. (2024). Adding comments to this blog. https://graysky.app/blog/2024-02-05-adding-blog-comments
- Van de Sompel, H., Nelson, M. L., Bilder, G., Kunze, J. A., & Warner, S. (2019). cite-as: A Link Relation to Convey a Preferred URI for Referencing (RFC No. 8574). RFC Editor. https://www.rfc-editor.org/rfc/rfc8574
Did you enjoy this article?
Recommend it — Standard Reader surfaces well-loved writing to more readers across the network.