braid-text 0.2.96 → 0.2.98

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.js CHANGED
@@ -140,7 +140,7 @@ function create_braid_text() {
140
140
  if (closed) return
141
141
  disconnect()
142
142
  var delay = waitTime * 1000
143
- console.log(`disconnected, retrying in ${waitTime} second${waitTime > 1 ? 's' : ''}`)
143
+ console.log(`disconnected from ${b}, retrying in ${waitTime} second${waitTime > 1 ? 's' : ''}`)
144
144
  setTimeout(connect, delay)
145
145
  waitTime = Math.min(waitTime + 1, 3)
146
146
  }
@@ -697,7 +697,8 @@ function create_braid_text() {
697
697
  var params = {
698
698
  signal: options.signal,
699
699
  subscribe: !!options.subscribe,
700
- heartbeats: 120,
700
+ heartbeats: options.heartbeats ?? 120,
701
+ heartbeat_cb: options.heartbeat_cb
701
702
  }
702
703
  if (!options.dont_retry) {
703
704
  params.retry = (res) => res.status !== 404
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "braid-text",
3
- "version": "0.2.96",
3
+ "version": "0.2.98",
4
4
  "description": "Library for collaborative text over http using braid.",
5
5
  "author": "Braid Working Group",
6
6
  "repository": "braid-org/braid-text",
@@ -1,9 +0,0 @@
1
- {
2
- "permissions": {
3
- "allow": [
4
- "Bash(node test/test.js:*)"
5
- ],
6
- "deny": [],
7
- "ask": []
8
- }
9
- }