[[Readwise]] is a service that provides a central place to store highlights and notes in different documents like articles, books or podcasts and YouTube videos. I enjoy the simplicity of it, and how easy it is to integrate with other services like an [[Obsidian]] vault. For the [[Digital Garden]], [[Readwise]] acts as a bridge to include all relevant parts of articles, podcasts and books I consume to store in [[Obsidian]]. ## Set up The integration is quite simple, and for a basic setup is as easy as installing the [Readwise plugin for Obsidian](https://github.com/readwiseio/obsidian-readwise) and enabling it via browser using your [[Readwise]] account. The configuration below is simply used to address some nitpicks and customize the structure of my files. ### Modifying the file format In the browser, you can edit the way the notes are generated based on your highlights. The configuration below is the one I use for the _Reference_ folder in the [[Digital Garden]]. #### Page title First off, I like the Readwise folder to be called _Reference_, and I use a custom file name to remove new lines in the titles: `{{ title|replace("\n", " ") }}`. This is a strange occurrence and should be sanitized in Reader most of the times, but I like to account for it in the plugin as well. #### Highlight I like to move the location outside of the highlight text, and set the tags as code blocks instead of regular [[Obsidian]] tags. ``` > {{ highlight_text }} {% if highlight_location and highlight_location_url %} - [{{highlight_location}}]({{highlight_location_url}}){% elif highlight_location %} - {{highlight_location}}{% endif %}{% if highlight_tags %} - _Tags_: {% for tag in highlight_tags %} `{{tag}}` {% endfor %}{% endif %}{% if highlight_note %} - _Note_: {{ highlight_note }}{% endif %}{% if highlight_location or highlight_tags or highlight_note %} {% endif %} --- ``` A lot of effort has been put on the newlines being applied correctly after the highlight – much more than what was worth it. #### YAML front matter In the front matter, I try to add as much data as possible, since the [[Obsidian Bases Plugin|Bases plugin]] does take advantage of the files metadata. ``` {% set type_map = {"books": "book", "articles": "article", "tweets": "tweet", "podcasts": "podcast"} %} type: {{ type_map.get(category, "") }} aliases: - "{{ full_title.replace('"', '\"').replace("'", "\'").replace("\n", " ") }}" - "\"{{ full_title.replace('"', '').replace("'", "\'").replace("\n", " ") }}\" by {{author}}" tags: resource, highlights url: {{url}} author: {%- for author in author.split(',') %} - "[[{{author.strip().strip('"')}}]]" {%- endfor %} source: {{source}} date: {{published_date}} ``` ## Usage ### Annotations The idea of the _Reference_ folder is that is completely managed by [[Readwise]] – **I don't write anything there at all**. All ideas, relations and complements are: - Added straight to [[Readwise]] as highlight notes, - Added as a separate note to the [[Digital Garden]]. That way, I can easily delete the whole folder to force a re-sync with Readwise if I want to change the format at any given time. ### [[Obsidian Bases Plugin|Bases plugin]] [[Obsidian Bases Plugin|Bases]] allows me to have a dynamic list of all the reference material, that is possible to filter and view at a glance. This is stored in the [[Reference.base]] file, that can be embedded in different places by using different views.