feat:add cypress E2E

This commit is contained in:
黄云飞
2022-03-11 17:24:12 +08:00
parent ead23ab0a1
commit c025f3d19c
13 changed files with 1287 additions and 1 deletions
+2
View File
@@ -11,6 +11,8 @@ window.onload = function () {
const container = document.querySelector<HTMLDivElement>('.editor')!
const instance = new Editor(container, <IElement[]>data, options)
console.log('实例: ', instance)
// cypress使用
Reflect.set(window, 'editor', instance)
// 2. | 撤销 | 重做 | 格式刷 | 清除格式 |
const undoDom = document.querySelector<HTMLDivElement>('.menu-item__undo')!