Skip to content
Permalink
Browse files
fix: fix checking Reflect existance (#284)
  • Loading branch information
ktsn committed Oct 15, 2018
1 parent dfd45be commit e80a44b8b8e1a905da760cb01f5e315cf9e1ef7f
Showing with 2 additions and 4 deletions.
  1. +1 −1 src/component.ts
  2. +1 −3 src/reflect.ts
@@ -82,7 +82,7 @@ export function componentFactory (

forwardStaticMembers(Extended, Component, Super)

if (reflectionIsSupported()) {
if (reflectionIsSupported) {
copyReflectionMetadata(Extended, Component)
}

@@ -1,9 +1,7 @@
import Vue, { VueConstructor } from 'vue'
import { VueClass } from './declarations'

export function reflectionIsSupported () {
return (Reflect && Reflect.defineMetadata) !== undefined
}
export const reflectionIsSupported = typeof Reflect !== undefined && Reflect.defineMetadata

export function copyReflectionMetadata (
to: VueConstructor,

0 comments on commit e80a44b

Please sign in to comment.