Plug-in
Rich Text Editor
The rich text editor in FormMaking V3 is VueQuill ↗ If needed, it should be introduced separately.
js
import { QuillEditor } from '@vueup/vue-quill'
import '@vueup/vue-quill/dist/vue-quill.snow.css'
app.component('QuillEditor', QuillEditor)
NOTE
If you have problems when importing, you can specify the following version: @vueup/vue-quill@beta
Code Editor
The code editor in the FormMaking V3 is ace ↗ . The default configuration is as follows:
js
app.use(FormMakingV3, {
aceurl: 'https://form.making.link/public/lib/ace' // The address is the ace file directory
})
导出 PDF ^3.5.8
需要在项目中单独引入 jspdf
和 html2canvas
库,才能使用导出 PDF 的功能。
bash
yarn add jspdf
bash
npm install jspdf --save
js
import { jsPDF } from 'jspdf'
import html2canvas from 'html2canvas'
app.use(FormMakingV3, {
jsPDF,
html2canvas
})
在 HTML 中使用
除了上面通过 import
引入,也可以直接使用 script
在 html 中引入
html
<script src="https://unpkg.com/jspdf@latest/dist/jspdf.umd.min.js"></script>
<script src="https://html2canvas.hertzen.com/dist/html2canvas.min.js"></script>