lint - fixes #223
This commit is contained in:
parent
38eb2e502c
commit
68109b033f
@ -11,7 +11,7 @@ import {
|
|||||||
ContentAny,
|
ContentAny,
|
||||||
ContentBinary,
|
ContentBinary,
|
||||||
getItemCleanStart,
|
getItemCleanStart,
|
||||||
AbstractUpdateEncoder, Doc, Snapshot, Transaction, EventHandler, YEvent, Item, // eslint-disable-line
|
YText, YArray, AbstractUpdateEncoder, Doc, Snapshot, Transaction, EventHandler, YEvent, Item, // eslint-disable-line
|
||||||
} from '../internals.js'
|
} from '../internals.js'
|
||||||
|
|
||||||
import * as map from 'lib0/map.js'
|
import * as map from 'lib0/map.js'
|
||||||
@ -157,7 +157,7 @@ export const findMarker = (yarray, index) => {
|
|||||||
// window.lengthes.push(marker.index - pindex)
|
// window.lengthes.push(marker.index - pindex)
|
||||||
// console.log('distance', marker.index - pindex, 'len', p && p.parent.length)
|
// console.log('distance', marker.index - pindex, 'len', p && p.parent.length)
|
||||||
// }
|
// }
|
||||||
if (marker !== null && math.abs(marker.index - pindex) < p.parent.length / maxSearchMarker) {
|
if (marker !== null && math.abs(marker.index - pindex) < /** @type {YText|YArray<any>} */ (p.parent).length / maxSearchMarker) {
|
||||||
// adjust existing marker
|
// adjust existing marker
|
||||||
overwriteMarker(marker, p, pindex)
|
overwriteMarker(marker, p, pindex)
|
||||||
return marker
|
return marker
|
||||||
|
@ -293,7 +293,7 @@ const tryGc = () => {
|
|||||||
* @param {t.TestCase} tc
|
* @param {t.TestCase} tc
|
||||||
*/
|
*/
|
||||||
export const testLargeFragmentedDocument = tc => {
|
export const testLargeFragmentedDocument = tc => {
|
||||||
const itemsToInsert = 2000000
|
const itemsToInsert = 5000000
|
||||||
let update = /** @type {any} */ (null)
|
let update = /** @type {any} */ (null)
|
||||||
;(() => {
|
;(() => {
|
||||||
const doc1 = new Y.Doc()
|
const doc1 = new Y.Doc()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user