ng bootstrap“ ^ 4.0.0”:分页控件本身正在工作时,其位置已损坏

时间:2018-11-27 11:50:09

标签: ng-bootstrap

通过遵循以下示例来尝试使用分页功能:“ https://getbootstrap.com/docs/4.0/components/pagination/”。我使用的是“ NG Bootstrap“ ^ 4.0.0”。当分页控件本身正在工作时,它们的显示损坏了。displayed vertically, not horizontally as expected

以下是从“ package.json”中获取的依赖项:

  "name": "ng7sass",
  "version": "0.0.0",
  "scripts": {
    "ng": "ng",
    "start": "ng serve",
    "build": "ng build",
    "test": "ng test",
    "lint": "ng lint",
    "e2e": "ng e2e"
  },
  "private": true,
  "dependencies": {
"@angular/animations": "~7.0.0",
    "@angular/common": "~7.0.0",
    "@angular/compiler": "~7.0.0",
    "@angular/core": "~7.0.0",
    "@angular/forms": "~7.0.0",
    "@angular/http": "~7.0.0",
    "@angular/platform-browser": "~7.0.0",
    "@angular/platform-browser-dynamic": "~7.0.0",
    "@angular/router": "~7.0.0",
    "@ng-bootstrap/ng-bootstrap": "^4.0.0",
    "core-js": "^2.5.4",
    "rxjs": "~6.3.3",
    "zone.js": "~0.8.26"
  }

我错过了什么吗?请帮忙。

1 个答案:

答案 0 :(得分:0)

事实证明,ng-bootstrap取决于boostrap样式表才能正常工作。我已经通过向项目添加引导程序4解决了分页显示问题。非常感谢您对此事的关注。