import Vue from 'vue'
import Function from './dk-function'

const messageBox = Vue.extend(Function)

Function.install = function (options,{ok}) {
  let instance = new messageBox({
    data: Object.assign(options,{okFunc:ok})
  }).$mount()
  document.body.appendChild(instance.$el)

  Vue.nextTick(() => {
    instance.visible = true
  })
}
export default Function
