Skip to content

Commit 744d293

Browse files
committed
docs
1 parent ad9ccdd commit 744d293

File tree

2 files changed

+30
-0
lines changed

2 files changed

+30
-0
lines changed

docs/en/migration/from-v3-to-v4.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
## Breaking changes
2+
### Output into new dist structure
3+
4+
* Output ESM into dist/esm
5+
* Output CommonJS into dist/cjs
6+
7+
If you use deprecated `vue-facing-decorator/dist/index-return-cons` and your ts config uses `moduleResolution` with `Node16`, it will be resolved correctly. Otherwise you need to change the path to `vue-facing-decorator/dist/esm/index-return-cons` or `vue-facing-decorator/dist/cjs/index-return-cons`.
8+
9+
### Totally remove support for initialization class fields with this.xxx in class declaration
10+
11+
```ts
12+
@Component
13+
class C extends Vue{
14+
@Prop
15+
prop!:string
16+
17+
method(){return ''}
18+
19+
field1 = this.prop //NOT SUPPORT
20+
21+
field2 = this.method() //NOT SUPPORT
22+
}
23+
```

docs/zh-cn/migration/from-v3-to-v4.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
## 破坏性改变
2+
### 输出结构变化
3+
4+
* 输出ESM格式到dist/esm
5+
* 输出CommonJS格式到dist/cjs
6+
7+
如果你使用已废弃的`vue-facing-decorator/dist/index-return-cons`并且你的TS配置`moduleResolution``Node16`,这将没有影响。否则你需要将路径改变为`vue-facing-decorator/dist/esm/index-return-cons``vue-facing-decorator/dist/cjs/index-return-cons`

0 commit comments

Comments
 (0)