Skip to content

Commit 806ff22

Browse files
committed
guide
1 parent 3fcfc14 commit 806ff22

File tree

11 files changed

+248
-248
lines changed

11 files changed

+248
-248
lines changed

.vitepress/locales/ja.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,13 @@ export default {
1616

1717
sidebar: [
1818
{
19-
text: 'Guide',
19+
text: 'ガイド',
2020
items: [
21-
{ text: 'Overview', link: '/ja/' },
22-
{ text: 'New Recommendations', link: '/ja/recommendations' },
23-
{ text: 'Migration Build', link: '/ja/migration-build' },
21+
{ text: '概要', link: '/ja/' },
22+
{ text: '新しい推奨事項', link: '/ja/recommendations' },
23+
{ text: '移行ビルド', link: '/ja/migration-build' },
2424
{
25-
text: 'Breaking Changes',
25+
text: '破壊的変更',
2626
link: '/ja/breaking-changes/'
2727
}
2828
]

src/ja/breaking-changes/custom-elements-interop.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ Vue.config.ignoredElements = ['plastic-button']
6161

6262
It's important to note the runtime config only affects runtime template compilation - it won't affect pre-compiled templates.
6363

64-
## Customized Built-in Elements
64+
## Customized Built-in Elements {#customized-built-in-elements}
6565

6666
The Custom Elements specification provides a way to use custom elements as [Customized Built-in Element](https://html.spec.whatwg.org/multipage/custom-elements.html#custom-elements-customized-builtin-example) by adding the `is` attribute to a built-in element:
6767

src/ja/breaking-changes/data-option.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ Using the example above, there would only be one possible implementation of the
6262
</script>
6363
```
6464

65-
## Mixin Merge Behavior Change
65+
## Mixin Merge Behavior Change {#mixin-merge-behavior-change}
6666

6767
In addition, when `data()` from a component and its mixins or extends base are merged, the merge is now performed *shallowly*:
6868

src/ja/breaking-changes/functional-components.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ DynamicHeading.props = ['level']
8585
export default DynamicHeading
8686
```
8787

88-
### Single File Components (SFCs)
88+
### Single File Components (SFCs) {#single-file-components-sfcs}
8989

9090
In 3.x, the performance difference between stateful and functional components has been drastically reduced and will be insignificant in most use cases. As a result, the migration path for developers using `functional` on SFCs is to remove the attribute and rename all references of `props` to `$props` and `attrs` to `$attrs`.
9191

src/ja/breaking-changes/global-api.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ While this approach is convenient, it leads to a couple of problems. Technically
5555

5656
To avoid these problems, in Vue 3 we introduce…
5757

58-
## A New Global API: `createApp`
58+
## A New Global API: `createApp` {#a-new-global-api-createapp}
5959

6060
Calling `createApp` returns an _app instance_, a new concept in Vue 3.
6161

@@ -89,15 +89,15 @@ An app instance exposes a subset of the Vue 2 global APIs. The rule of thumb is
8989

9090
All other global APIs that do not globally mutate behavior are now named exports, as documented in [Global API Treeshaking](./global-api-treeshaking.html).
9191

92-
### `config.productionTip` Removed
92+
### `config.productionTip` Removed {#config-productiontip-removed}
9393

9494
In Vue 3.x, the "use production build" tip will only show up when using the "dev + full build" (the build that includes the runtime compiler and has warnings).
9595

9696
For ES modules builds, since they are used with bundlers, and in most cases a CLI or boilerplate would have configured the production env properly, this tip will no longer show up.
9797

9898
[Migration build flag: `CONFIG_PRODUCTION_TIP`](../migration-build.html#compat-configuration)
9999

100-
### `config.ignoredElements` Is Now `config.compilerOptions.isCustomElement`
100+
### `config.ignoredElements` Is Now `config.compilerOptions.isCustomElement` {#config-ignoredelements-is-now-config-compileroptions-iscustomelement}
101101

102102
This config option was introduced with the intention to support native custom elements, so the renaming better conveys what it does. The new option also expects a function which provides more flexibility than the old string / RegExp approach:
103103

@@ -120,7 +120,7 @@ In Vue 3, the check of whether an element is a component or not has been moved t
120120

121121
[Migration build flag: `CONFIG_IGNORED_ELEMENTS`](../migration-build.html#compat-configuration)
122122

123-
### `Vue.prototype` Replaced by `config.globalProperties`
123+
### `Vue.prototype` Replaced by `config.globalProperties` {#vue-prototype-replaced-by-config-globalproperties}
124124

125125
In Vue 2, `Vue.prototype` was commonly used to add properties that would be accessible in all components.
126126

@@ -141,7 +141,7 @@ Using `provide` (discussed [below](#provide-inject)) should also be considered a
141141

142142
[Migration build flag: `GLOBAL_PROTOTYPE`](../migration-build.html#compat-configuration)
143143

144-
### `Vue.extend` Removed
144+
### `Vue.extend` Removed {#vue-extend-removed}
145145

146146
In Vue 2.x, `Vue.extend` was used to create a "subclass" of the base Vue constructor with the argument that should be an object containing component options. In Vue 3.x, we don't have the concept of component constructors anymore. Mounting a component should always use the `createApp` global API:
147147

@@ -210,7 +210,7 @@ const app = createApp(MyApp)
210210
app.use(VueRouter)
211211
```
212212

213-
## Mounting App Instance
213+
## Mounting App Instance {#mounting-app-instance}
214214

215215
After being initialized with `createApp(/* options */)`, the app instance `app` can be used to mount a root component instance with `app.mount(domTarget)`:
216216

src/ja/breaking-changes/index.md

Lines changed: 49 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -1,66 +1,66 @@
1-
# Breaking Changes
1+
# 破壊的変更
22

3-
This page lists all Vue 3 breaking changes from Vue 2.
3+
このページでは、Vue 2 から Vue 3 の破壊的変更をすべてリストアップしています。
44

5-
While it looks like a lot has changed, a lot of what you know and love about Vue is still the same; but we wanted to be as thorough as possible and provide detailed explanations and examples for every documented change.
5+
たくさん変わったように見えますが、Vue について皆さんが知っていることや気に入っていることの多くは変わりません。しかしできる限り徹底して、ドキュメント化されたすべての変更について詳細な説明と例を提供したいと考えました。
66

7-
## Details
7+
## 詳細
88

9-
### Global API
9+
### グローバル API
1010

11-
- [Global Vue API is changed to use an application instance](./global-api.html)
12-
- [Global and internal APIs have been restructured to be tree-shakable](./global-api-treeshaking.html)
11+
- [グローバル Vue API はアプリケーションインスタンスを使用するように変更されました](./global-api.html)
12+
- [グローバル API と内部 API が再構築され、ツリーシェイキングが可能になりました](./global-api-treeshaking.html)
1313

14-
### Template Directives
14+
### テンプレートディレクティブ
1515

16-
- [`v-model` usage on components has been reworked, replacing `v-bind.sync`](./v-model.html)
17-
- [`key` usage on `<template v-for>` and non-`v-for` nodes has changed](./key-attribute.html)
18-
- [`v-if` and `v-for` precedence when used on the same element has changed](./v-if-v-for.html)
19-
- [`v-bind="object"` is now order-sensitive](./v-bind.html)
20-
- [`v-on:event.native` modifier has been removed](./v-on-native-modifier-removed.md)
16+
- [コンポーネントでの `v-model` の使用方法が見直され、`v-bind.sync` を置き換えます](./v-model.html)
17+
- [`<template v-for>` `v-for` でないノードでの `key` の使い方が変更されました](./key-attribute.html)
18+
- [`v-if` `v-for` を同じ要素で使用した場合の優先順位が変更されました](./v-if-v-for.html)
19+
- [`v-bind="object"` は順序に依存するようになりました](./v-bind.html)
20+
- [`v-on:event.native` 修飾子は削除されました](./v-on-native-modifier-removed.md)
2121

22-
### Components
22+
### コンポーネント
2323

24-
- [Functional components can only be created using a plain function](./functional-components.html)
25-
- [`functional` attribute on single-file component (SFC) `<template>` and `functional` component option are deprecated](./functional-components.html)
26-
- [Async components now require `defineAsyncComponent` method to be created](./async-components.html)
27-
- [Component events should now be declared with the `emits` option](./emits-option.md)
24+
- [関数型コンポーネントは普通の関数のみで作成できます](./functional-components.html)
25+
- [単一ファイルコンポーネント(SFC)での `<template>` `functional` 属性と、コンポーネントオプションの `functional` は非推奨です](./functional-components.html)
26+
- [非同期コンポーネントを作成するには `defineAsyncComponent` メソッドが必要になりました](./async-components.html)
27+
- [コンポーネントイベントは `emits` オプションで宣言する必要があります](./emits-option.md)
2828

29-
### Render Function
29+
### レンダー関数
3030

31-
- [Render function API changed](./render-function-api.html)
32-
- [`$scopedSlots` property is removed and all slots are exposed via `$slots` as functions](./slots-unification.html)
33-
- [`$listeners` has been removed / merged into `$attrs`](./listeners-removed)
34-
- [`$attrs` now includes `class` and `style` attributes](./attrs-includes-class-style.md)
31+
- [レンダー関数の API が変更されました](./render-function-api.html)
32+
- [`$scopedSlots` プロパティーは削除され、すべてのスロットが `$slots` で関数として公開されます](./slots-unification.html)
33+
- [`$listeners` は削除され、`$attrs` に統合されました](./listeners-removed)
34+
- [`$attrs` には `class` `style` 属性が含まれるようになりました](./attrs-includes-class-style.md)
3535

36-
### Custom Elements
36+
### カスタム要素
3737

38-
- [Custom element checks are now performed during template compilation](./custom-elements-interop.html)
39-
- [Special `is` attribute usage is restricted to the reserved `<component>` tag only](./custom-elements-interop.html#customized-built-in-elements)
38+
- [テンプレートのコンパイル時に、カスタム要素のチェックが行われるようになりました](./custom-elements-interop.html)
39+
- [特別な `is` 属性の使用は、予約済みである `<component>` タグのみに制限されます](./custom-elements-interop.html#customized-built-in-elements)
4040

41-
### Other Minor Changes
41+
### その他の小さな変更
4242

43-
- The `destroyed` lifecycle option has been renamed to `unmounted`
44-
- The `beforeDestroy` lifecycle option has been renamed to `beforeUnmount`
45-
- [Props `default` factory function no longer has access to `this` context](./props-default-this.html)
46-
- [Custom directive API changed to align with component lifecycle and `binding.expression` removed](./custom-directives.html)
47-
- [The `data` option should always be declared as a function](./data-option.html)
48-
- [The `data` option from mixins is now merged shallowly](./data-option.html#mixin-merge-behavior-change)
49-
- [Attributes coercion strategy changed](./attribute-coercion.html)
50-
- [Some transition classes got a rename](./transition.html)
51-
- [`<TransitionGroup>` now renders no wrapper element by default](./transition-group.html)
52-
- [When watching an array, the callback will only trigger when the array is replaced. If you need to trigger on mutation, the `deep` option must be specified.](./watch.html)
53-
- `<template>` tags with no special directives (`v-if/else-if/else`, `v-for`, or `v-slot`) are now treated as plain elements and will result in a native `<template>` element instead of rendering its inner content.
54-
- [Mounted application does not replace the element it's mounted to](./mount-changes.html)
55-
- [Lifecycle `hook:` events prefix changed to `vnode-`](./vnode-lifecycle-events.html)
43+
- ライフサイクルの `destroyed` オプションは `unmounted` に名称変更されました
44+
- ライフサイクルの `beforeDestroy` オプションは `beforeUnmount` に名称変更されました
45+
- [props の `default` ファクトリー関数は `this` コンテキストにアクセスできなくなりました](./props-default-this.html)
46+
- [カスタムディレクティブ API は、コンポーネントのライフサイクルに合わせて変更され、`binding.expression` は削除されました](./custom-directives.html)
47+
- [`data` オプションは、常に関数として宣言する必要があります](./data-option.html)
48+
- [mixins の `data` オプションは浅くマージされるようになりました](./data-option.html#mixin-merge-behavior-change)
49+
- [属性の型強制戦略が変更されました](./attribute-coercion.html)
50+
- [一部のトランジションクラス名が変更されました](./transition.html)
51+
- [`<TransitionGroup>` はデフォルトでラッパー要素をレンダリングしないようになりました](./transition-group.html)
52+
- [配列を監視している場合、コールバックは配列が置換されたときにのみトリガーされます。変更時にトリガーする必要がある場合は、`deep` オプションを指定する必要があります。](./watch.html)
53+
- 特別なディレクティブ(`v-if/else-if/else`, `v-for`, `v-slot`)を持たない `<template>` タグはプレーンな要素として扱われ、その内部コンテンツをレンダリングする代わりに、ネイティブの `<template>` 要素が生成されるようになりました。
54+
- [マウントされたアプリケーションは、そこにマウントされている要素を置き換えません](./mount-changes.html)
55+
- [ライフサイクルの `hook:` イベントプレフィックスが `vnode-` に変更されました](./vnode-lifecycle-events.html)
5656

57-
### Removed APIs
57+
### 削除された API
5858

59-
- [`keyCode` support as `v-on` modifiers](./keycode-modifiers.html)
60-
- [$on, $off and \$once instance methods](./events-api.html)
61-
- [Filters](./filters.html)
62-
- [Inline templates attributes](./inline-template-attribute.html)
63-
- [`$children` instance property](./children.html)
64-
- [`propsData` option](./props-data.html)
65-
- `$destroy` instance method. Users should no longer manually manage the lifecycle of individual Vue components.
66-
- Global functions `set` and `delete`, and the instance methods `$set` and `$delete`. They are no longer required with proxy-based change detection.
59+
- [`v-on` 修飾子としての `keyCode` サポート](./keycode-modifiers.html)
60+
- [$on, $off, \$once インスタンスメソッド](./events-api.html)
61+
- [フィルター](./filters.html)
62+
- [インラインテンプレート属性](./inline-template-attribute.html)
63+
- [`$children` インスタンスプロパティー](./children.html)
64+
- [`propsData` オプション](./props-data.html)
65+
- `$destroy` インスタンスメソッド。ユーザーは、個々の Vue コンポーネントのライフサイクルを手動で管理する必要がなくなりました。
66+
- グローバル関数の `set` `delete`、インスタンスメソッドの `$set` `$delete` は削除されました。プロキシベースの変更検出では不要になりました。

src/ja/breaking-changes/key-attribute.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ The `key` special attribute is used as a hint for Vue's virtual DOM algorithm to
1818
- [List Rendering: Maintaining State](https://ja.vuejs.org/guide/essentials/list.html#maintaining-state-with-key)
1919
- [API Reference: `key` Special Attribute](https://ja.vuejs.org/api/built-in-special-attributes.html#key)
2020

21-
## On conditional branches
21+
## On conditional branches {#on-conditional-branches}
2222

2323
In Vue 2.x, it was recommended to use `key`s on `v-if`/`v-else`/`v-else-if` branches.
2424

@@ -52,7 +52,7 @@ The breaking change is that if you manually provide `key`s, each branch must use
5252
<div v-else key="b">No</div>
5353
```
5454

55-
## With `<template v-for>`
55+
## With `<template v-for>` {#with-template-v-for}
5656

5757
In Vue 2.x, a `<template>` tag could not have a `key`. Instead, you could place the `key`s on each of its children.
5858

0 commit comments

Comments
 (0)