@@ -61,7 +61,7 @@ pnpm add @vue/composition-api
6161#### Register globally
6262
6363``` ts
64- import { createApp } from ' vue'
64+ import {createApp } from ' vue'
6565import CodeDiff from ' v-code-diff'
6666
6767app
7777 <code-diff
7878 :old-string="'12345'"
7979 :new-string="'3456'"
80- output-format="side-by-side" />
80+ output-format="side-by-side"/>
8181</template>
8282```
8383
@@ -149,25 +149,27 @@ version. And we will try to align the functions with the 0.x version as much as
149149
150150Key points:
151151
152- In the 1.x version, language recognition and highlighting will no longer be automatically performed, you need to
153- manually specify the language type, such as language="python", if not specified, it will default to plaintext
154- and will not be highlighted.
155- In the 1.x version, due to the fact that rendering and highlighting are performed at the same time, the component events
156- have been removed.
157- In the 1.x version, the following component properties (Prop) have been removed:
158- highlight
159- drawFileList
152+ * In the 1.x version, language recognition and highlighting will no longer be automatically performed, you need to
153+ manually specify the language type, such as language="python", if not specified, it will default to plaintext
154+ and will not be highlighted.
155+ * In the 1.x version, due to the fact that rendering and highlighting are performed at the same time, the component
156+ events
157+ have been removed.
158+ * In the 1.x version, the following component properties (Prop) have been removed:
159+ * highlight
160+ * drawFileList
161+
160162Below is a detailed comparison of the two versions, you can refer to it to complete the migration.
161163
162164### The difference of event.
163165
164166The component events are no longer provided in the 1.x version as rendering and highlighting are carried out
165167simultaneously.
166168
167- | Event Name | Description |
168- | ---------------| --------------------- |
169- | before-render | No longer available |
170- | after-render | No longer available |
169+ | Event Name | Change Status |
170+ | ---------------| --------------------|
171+ | before-render | No longer provided |
172+ | after-render | No longer provided |
171173
172174### The difference of prop.
173175
0 commit comments