webdb icon indicating copy to clipboard operation
webdb copied to clipboard

pass options through to DatArchive; update readme

Open garbados opened this issue 7 years ago • 2 comments

Addresses issue https://github.com/beakerbrowser/webdb/issues/13 by passing the dat attribute of the opts parameter of indexArchive and unindexArchive to DatArchive as its second parameter. I've also updated the README to reflect this change.

garbados avatar Dec 23 '17 23:12 garbados

Even with this PR, you won't be able to pass options directly to Dat until this node-dat-archive PR is also merged. Even then, the interface will be a little clunky:

await webdb.indexArchive('dat://foo.com', {
  dat: {
    datOptions: { ... }
  }
})

garbados avatar Dec 23 '17 23:12 garbados

Appreciate the PR! I agree this is a bit clunky. I was thinking about ways to clean it up and then thought, why not instantiate and pass in the DatArchive instance yourself?

pfrazee avatar Dec 31 '17 20:12 pfrazee