Writing to you after spending time for Chinese New Year with my family and friends. I hope all of you who celebrate Chinese New Year had a great time with your loved ones, too 💌. Also hope you’ll forgive that this issue was sent 2 days late due to the holiday 😛
Alright, now is my learnings in this week that you may find interesting and useful:
ntast (Notion Abstract Syntax Tree), is an open-source specification to define how Notion contents can be parsed and transformed to create different applications. It took me 2 days to finish the
Firstly, because syntax tree and Notion content processing are not popular, let me explain what value ntast provides:
Now, here is why I built it:
When I started building ntast, I set a goal to release it within 2 days so that I can quickly validate my assumption (above).
Thanks to my prior experience with unified and syntax trees while working on my website, I had a good understanding of the ecosystem. I went to 3 popular similar projects unist, mdast, and hast (special thanks to @wooorm and contributors for the awesome work), I quickly learned how they were written, then copied and pasted mdast to use as my initial work. mdast has a decent writing structure that helped my work look professional right from the beginning.
Next, I needed to build models for Notion contents. Again, I quickly skimmed over existing open-source projects to leverage as much existing work as possible and found notion-types, decent modeling of the current Notion API by Travis Fisher. I sent him a thank you and built ntast from there within a day.
The day after I created some testing examples and added screenshots to make the specification more self-explanatory.
Finally, I released it and shared it with my small Twitter network. Luckily, it got 10 stars after just 2 days without me posting other places. It was a small number but the reaction was good enough for me to be confident and develop it further.
ntast is ready for experimental work. You can now check out how a Notion page (public) can be represented in ntast at:
For example, go to http://notiontweet.app/api/v1/ntast/Basic-Blocks-0be6efce9daf42688f65c76b89f8eb27 to see the ntast tree of this Notion page.
Thanks to the fact that ntast is ready for experimental work, I can build an interactive demo of Notion Tweet this week and start to get more feedbacks from people, so it will be my primary goal. Other than that, if time allows, I want to test out 2 potential distribution channels that I didn’t touch, Reddit and Indie Hackers.
Alright, that’s it, wish you a great week ahead, and looking forward to sharing with you the interactive demo!
Ending with analytics of Notion Tweet landing page last week: