0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Android5.1のWebViewでBootstrap4.1.0のモーダル表示時に「TypeError: Object.keys called on non-object」が発生する件

Posted at

起きたこと

Android 5.1 内のWebViewにてBootstrap4のモーダルを表示させようとしたところエラーが発生しモーダルが表示されない。

TypeError: Object.keys called on non-object
  function _objectSpread(target) {
    for (var i = 1; i < arguments.length; i++) {
      var source = arguments[i] != null ? arguments[i] : {};
      var ownKeys = Object.keys(source); //←ここで「TypeError: Object.keys called on non-object」が発生

      if (typeof Object.getOwnPropertySymbols === 'function') {
        ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function (sym) {
          return Object.getOwnPropertyDescriptor(source, sym).enumerable;
        }));
      }

      ownKeys.forEach(function (key) {
        _defineProperty(target, key, source[key]);
      });
    }

    return target;
  }

環境など

Android5.1(シミュレーター)
Bootstrap 4.1.0

原因

Bootstrap側のバグ(?)でした。(IE11などでも同様の事象が起きるらしい)
https://github.com/twbs/bootstrap/issues/26266
https://github.com/twbs/bootstrap/pull/26291

対策

Bootstrapのバージョンアップ
4.1.0 → 4.1.1 で事象が解決することを確認済み。

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?