Open 2nthony opened 5 years ago
Now idea is check package.json
package.json
If have vue then set __DVAN_ENV__ = 'vue', cannot set VUE_ENV because vue-ssr using it(If I still remember).
vue
__DVAN_ENV__ = 'vue'
VUE_ENV
vue-ssr
If have React then set __DVAN_ENV__ = 'react'
React
__DVAN_ENV__ = 'react'
Maybe this way is better: If have vue then set __DVAN_ENV__ to vue, react in otherwise.
__DVAN_ENV__
react
Actually use __DVAN_ENV__: string in Client-Side, also have __IS_VUE__: boolean
__DVAN_ENV__: string
__IS_VUE__: boolean
Since version: 2.1.5
2.1.5
Now idea is check
package.json
If have
vue
then set__DVAN_ENV__ = 'vue'
, cannot setVUE_ENV
becausevue-ssr
using it(If I still remember).If have
React
then set__DVAN_ENV__ = 'react'
Maybe this way is better: If have
vue
then set__DVAN_ENV__
tovue
,react
in otherwise.