Skip to content

Commit fad25b8

Browse files
committed
fix(engine): add $message function to display message
1 parent 230d5bb commit fad25b8

File tree

1 file changed

+18
-7
lines changed

1 file changed

+18
-7
lines changed

front-end/h5/src/engine-entry.js

+18-7
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,29 @@
1-
/**
2-
* #!zh:
3-
* engine 页面是 webpack 构建多页面中的其中的一个页面
4-
* entry-entry 是 构建 engine 页面的入口,类似于 src/main.js 的作用
5-
* 作用:作品预览的渲染引擎,其实就是简单遍历 work(作品) 的 pages 以及 elements,显示即可
6-
* 主要在预览弹窗中预览 和 用户在手机上查看作品使用
7-
*
1+
/*
2+
* @Author: ly525
3+
* @Date: 2019-11-24 18:51:58
4+
* @LastEditors: ly525
5+
* @LastEditTime: 2019-12-15 17:09:51
6+
* @FilePath: /luban-h5/front-end/h5/src/engine-entry.js
7+
* @Github: https://github.com/ly525/luban-h5
8+
* @Description:
9+
#!zh: 页面预览引擎入口
10+
构建 engine 页面的入口,作用与 src/main.js 类似,都是页面入口
11+
作用:作品预览的渲染引擎,原理:遍历 work(作品) 的 pages 以及 elements,显示即可
12+
使用场景:预览弹窗中预览 和 在手机上查看作品使用
13+
* @Copyright 2018 - 2019 luban-h5. All Rights Reserved
814
*/
15+
916
import Vue from 'vue'
1017
// import 'font-awesome/css/font-awesome.min.css'
18+
import message from 'ant-design-vue/lib/message' // 加载 JS
19+
import 'ant-design-vue/lib/message/style/css' // 加载 CSS
20+
1121
import { pluginsList } from './mixins/load-plugins.js'
1222
import Element from './components/core/models/element'
1323
import NodeWrapper from '@/components/preview/node-wrapper.js'
1424

1525
Vue.config.productionTip = true
26+
Vue.prototype.$message = message
1627

1728
const Engine = {
1829
name: 'engine',

0 commit comments

Comments
 (0)