Please use the question Tags instead of the question Title to state the name and full version number of your story format.
... import a library in JavaScript like this one
You can use code like the following within your story's Story Javascript area to programmatically load an external JavaScript file.
(function ($) {
$(document.createElement('script'))
.attr({
id : 'script-pouch-db',
type : 'text/javascript',
src : 'https://cdn.jsdelivr.net/npm/pouchdb@6.3.4/dist/pouchdb.min.js'
})
.appendTo(document.head);
})(jQuery);
Unfortunately the Harlowe story format (both 1.x and 2.x) has been deliberately designed in such a way that makes using Javascript to extend it's core functionality difficult, especially if you want to access or alter the values of story variables.
Could you give more details on exactly what you want to use the PounchDB library for so that anyone answering your question can give you better advice on how you might achieve those outcomes within Harlowe.