Created
January 19, 2020 05:01
-
-
Save mascii/f3452ad00fc49406e19cc956159a1a69 to your computer and use it in GitHub Desktop.
Vueコンストラクタ関数の取得(IE11対応版)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Vue = (function () { | |
var el = [].filter.call(document.all, function (el) {return el.__vue__})[0]; | |
if (!el) { | |
return; | |
} | |
var Vue = Object.getPrototypeOf(el.__vue__).constructor; | |
while (Vue.super) { | |
Vue = Vue.super; | |
} | |
return Vue; | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment