FlymeApps / weex-flymeui

🐼 A Flyme Style UI library based on Weex for Creator.
https://flymeapps.github.io/weex-flymeui
MIT License
67 stars 12 forks source link

在android上可以使用,为什么h5不能使用? #2

Open duanzhichao opened 6 years ago

json-sun commented 6 years ago

看下是不是 weex-vue-render 没有引入

duanzhichao commented 6 years ago

引入了,我用weex-ui没问题,用flyui不行

json-sun commented 6 years ago

麻烦贴一下报错的信息

duanzhichao commented 6 years ago

代码

<template>
  <div>
    <fm-button @buttonClick="buttonClicked" theme="blue">安装</fm-button>
  </div>
</template>

<script>
import { FmButton } from 'weex-flymeui'
// 或者 import FmButton from 'weex-flymeui/packages/fm-button';
export default {
  components: { FmButton },
  methods: {
    buttonClicked () {
      // enter your code
    }
  }
}
</script>

调试报错

Uncaught ReferenceError: Vue is not defined
    at eval (webpack-internal:///401:16)
    at Object.<anonymous> (index.web.js:2631)
    at __webpack_require__ (index.web.js:22)
    at eval (webpack-internal:///294:80)
    at Object.<anonymous> (index.web.js:1957)
    at __webpack_require__ (index.web.js:22)
    at eval (webpack-internal:///293:7)
    at Object.<anonymous> (index.web.js:1950)
    at __webpack_require__ (index.web.js:22)
    at eval (webpack-internal:///292:4)

后台报错

57% building modules 400/407 modules 7 active ...flymeui/packages/fm-textbar/index.vue[weex-vue-precompiler]: current expression not in transform lists: LogicalExpression
[weex-vue-precomiler]: current ast node: BinaryExpression {
  type: 'LogicalExpression',
  operator: '&&',
  left: 
   StaticMemberExpression {
     type: 'MemberExpression',
     computed: false,
     object: Identifier { type: 'Identifier', name: 'item' },
     property: Identifier { type: 'Identifier', name: 'color' } },
  right: ObjectExpression { type: 'ObjectExpression', properties: [ [Object] ] } }
 58% building modules 404/409 modules 5 active ...-flymeui/packages/fm-slider/index.vue[weex-vue-precompiler]: current expression not in transform lists: LogicalExpression
[weex-vue-precomiler]: current ast node: BinaryExpression {
  type: 'LogicalExpression',
  operator: '&&',
  left: 
   BinaryExpression {
     type: 'BinaryExpression',
     operator: '===',
     left: 
      BinaryExpression {
        type: 'BinaryExpression',
        operator: '-',
        left: [Object],
        right: [Object] },
     right: 
      UnaryExpression {
        type: 'UnaryExpression',
        operator: '-',
        argument: [Object],
        prefix: true } },
  right: ObjectExpression { type: 'ObjectExpression', properties: [ [Object] ] } }
snice commented 6 years ago

https://github.com/snice/easy-weex-demo 我这个集成了当下所有的第三方weex 组件库,都是OK的

duanzhichao commented 6 years ago

https://github.com/snice/easy-weex-demo 我这个集成了当下所有的第三方weex 组件库,都是OK的

但是我在网页端什么页看不到啊