1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" href="/favicon.ico" />
<link rel="stylesheet" href="/dist/style.css" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Test the package</title>
</head>
<body>
<div id="app"></div>
<script type="module">
import { RichTextReader } from './src/package.js'
import Vue from 'vue'
const app = new Vue({
data() {
return {
content: '**Hello There**',
}
},
provide: {
currentDirectory: '/'
},
render: (h) => h('div', [
h('textarea', {
style: {
width: '100%',
height: '20vh',
padding: '0px',
},
on: {
input: function (event) {
app.content = event.target.value
},
},
}, [app.content]),
h(RichTextReader, {
props: { content: app.content }
}),
]),
})
app.$mount('#app')
</script>
</body>
</html>
|