Version 2.x.x is a major rewrite of the plugin, with a focus on implementing a deduplication logic, more atomic upgrades (keeping existing additional or protected frontmatter intact) and handling of special characters in filenames.
Warning
If you update to 2.0.0 without following these steps, you will likely end up with duplicate notes for the same Readwise item or, if you delete the whole Readwise folder in your Obsidian vault first, will likely lose any existing internal links to notes created by the plugin.
If you plan to upgrade the plugin from v1.x.x to v2.0.0, and want to make sure any internal links in your Obsidian vault to notes created by the plugin remain intact, then you should ensure all your notes have the file tracking property in their frontmatter before the upgrade.
Below is a step-by-step guide how you can prepare an existing Readwise library by adding the uri tracking property to your items before upgrading to ensure links to items in your Readwise library will be updated after an upgrade.
-
Make sure you have a backup of your Obsidian vault (or at least your Readwise mirror folder with the notes created by this plugin).
-
In the plugin settings in v1.x.x, add the
uritracking property (or whatever property key you plan to use for file tracking) to the Frontmatter template. You can replace (recommended) the frontmatter template with the following, and enable Frontmatter1:--- uri: {{ highlights_url }} ---
-
Run a full sync to establish proper tracking properties (this will overwrite your local changes based on the current settings for the colon, but it will preserve the filenames of your existing files according to the way v1.4.11 of the plugin creates these. In consequence, all internal links will remain valid).
-
Upgrade the plugin to
2.0.0and enable file tracking (this will ensure the tracking property will always be added to newly created or updated notes). -
Rebuild the frontmatter templates and adjust the filename settings to your liking (you can also reset the templates to their default: simply delete the whole template value).
-
Run a full sync to rebuild all the notes according to the new settings and enjoy the new features of Readwise mirror 2.x.x.
Your subsequent syncs will then use the uri property to track unique files and ensure links to items in your Readwise library will be updated, even if the note filenames change with the new version of the plugin.
Tip
If you are unsure what the plugin will do to your Obsidian Obsidian vault after the upgrade, we would recommend that you create a copy of the Obsidian vault and run a test upgrade according to the steps described above.
- Switched to using Readwise's "export" API, providing access to document summaries and additional metadata (implements #39)
- Completely rewrote the deduplication logic to handle edge cases like special characters and items with identical titles
- Implemented consistent use of
normalizedPath()throughout for better filename generation and handling (BREAKING CHANGE) - Added robust frontmatter creation, validation and preservation during note creation and updates, resulting in more reliable generation of valid frontmatter (precondition for using frontmatter as reliable basis for file tracking)
- Introduced file tracking using unique Readwise URLs for reliable deduplication and internal linking in your Obsidian vault
- Implemented
/api_authendpoint for token retrieval, you can now retrieve your token from the plugin settings page
- Added Q&A parsing with new
is_qaandqanunjucks filters for.qaaction tags in Readwise - Added
datefilter to format dates (e.g. for filenames) - Added
bqfilter to ensure notes or highlights with multiple paragraphs are properly escaped as one blockquote - Improved title, author, and frontmatter template handling and error reporting to persistently create valid frontmatter
- Added slugify option for filenames (implements #27)
- Implemented
filenamifyfor valid filenames with 255 character limit (implements #37) - Enhanced documentation and settings UI with template explanations
- Added options to clean-up author names from Readwise
- Introduced debug option in UI to control console logging
- Added proper escaping for arrays of strings in frontmatter (authors, tags)
- Implemented semantic-release workflow using
brianrodri/semantic-release-obsidian-plugin - Added local deploy and release actions (
npm run deploy:local)) - Restructured codebase
- Added GitHub workflow for automated releases
- Separated settings from main class
BREAKING CHANGE: This is a major rewrite that changes how filenames are generated and validated. Please consult the documentation for migrating existing libraries, particularly regarding the new URL-based tracking system.
- UI: Update "Open in Readwise" text to "View Highlight", to better align with official plugin expected behavior
This update adds better support for Readwise article highlighting and default tag template additions. Thanks to first time contributor @tdznr for adding to this release!
- Feature: Add "Open in Readwise" link when Readwise url field is present.
-The url field contains the link to Readwise's website showing the highlighted snippet in its source context.
- The url field is not available for book types, but is available for other content types such as Articles.
- Feature: Show tags in default highlight template
Thanks to @johannrichard for the following contributions:
- Feature: ✨ add frontmatter tag field
- Feature: ✨ roll-up of highlight tags into frontmatter
- a rolled-up (deduplicated) list highlight tags can be used in frontmatter via the field
quoted_highlight_tags
- a rolled-up (deduplicated) list highlight tags can be used in frontmatter via the field
- Feature: ✨ user setting for "colon" (:) replacement
- The colon in a title is a special character which by default is replaced witha a dash (-) in filenames. With this change, users can choose what string to use as a replacement.
- Feature: ✨ Multi-line text can be filtered with the
bqfilter-
The filter adds the
>character after each line-break -
With this, you can get multi-line text blockquotes in your templates working correctly
The following highlight
Multi-line text in blockquotes This is an example of a multi-line highlight with line-breaks.... with this template
> [!quote] > {{ text | bq }}will turn into
> [!quote] > Multi-line text in blockquotes > > This is an example of a multi-line highlight with line-breaks.
-
- Change field names to reflect their use in frontmatter
- Introduce option for quotes in tag format
- make tag formatting more flexible
- avoid adding quotes all the time
- differentiate nohas from quoting
- Introduce option for quotes in tag format
- Sort Highlights by Location (instead of date highlighted).
- This will display highlights in order of page location, from least to greatest.
- Combine with Sort Highlights from Oldest to Newest to reverse the sort order.
- Filter Discarded Highlights.
- With this option enabled, highlights that have been discarded in Readwise will not be displayed in the Obsidian library.
- Added Sync Log functionality. Creates a file (configurable, with a default filename of
Sync.md) in the Readwise library root folder, which stores a time-based log listing when Readwise sources have synced new highlights
- Added tag support, both in highlights and sources (books, articles, etc)
- Fixed linking bug when illegal characters were stripped in filename, but not in Note title (#4)
- Starting default sort order preference now sorts highlights chronologically from oldest to newest
- Added new checkbox in settings to allow highlights to be listed in reverse chronological order
- Fixes plugin breaking when there is no author (thanks @shabegom!)
- Added Prettier configuration for project style consistency
Footnotes
-
You might want to ensure that properties like
authorare omitted from the template as these have a tendency to break frontmatter. Alternatively, you can use theauthorStrvariable, or run a plugin like "Linter" to check and fix all your Readwise notes before upgrading. ↩