以bootstrap3.3.6版本中未压缩的bootstrap.js文件为例。
第一处在971行左右,删除这3句
- this.checkScrollbar()
- this.setScrollbar()
- this.$body.addClass('modal-open')
第二处1081行左右,也删除3句
- that.$body.removeClass('modal-open')
- that.resetAdjustments()
- that.resetScrollbar()
这样就好了。都是写无关紧要的代码,给body加内边距的,不会影响其他组件的运行。
转载请注明出处。