You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
林华焜 b6f8f922cf
first commit
4 years ago
..
dist first commit 4 years ago
src first commit 4 years ago
LICENSE first commit 4 years ago
README.md first commit 4 years ago
README_zh-CN.md first commit 4 years ago
package.json first commit 4 years ago

README.md

@better-scroll/observe-dom

中文文档

recaculating BetterScroll's scrollHeight or scrollWidth by MutationObserver, with this, you don't care when BetterScroll's scrollHeight or scrollWidth have changed. Plugin has done it for you.

if current browser does not surpport MutationObserver, it will fallback to setTimeout in recursion

Usage

import BScroll from '@better-scroll/core'
import ObserveDom from '@better-scroll/observe-dom'
BScroll.use(ObserveDom)

const bs = new BScroll('.wrapper', {
  observeDom: true
})