Skip to content

Commit

Permalink
Merge pull request #142 from hnviradiya/topic/documentation
Browse files Browse the repository at this point in the history
English Documentation Typos fixed
  • Loading branch information
ruojianll authored Dec 8, 2024
2 parents 0e28a72 + 13c0a3b commit 76377a9
Show file tree
Hide file tree
Showing 12 changed files with 17 additions and 17 deletions.
2 changes: 1 addition & 1 deletion changelog/v3.0.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export default toNative(MyComp)
export default class MyComp extends Vue{}
```

### Deprecate init class property despends on another in constructor
### Deprecate init class property depends on another in constructor

This is not allowed now.
```typescript
Expand Down
4 changes: 2 additions & 2 deletions changelog/v3.0.1.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

1. Use class constructor name as default component name.

2. `@Ref` decorator accepts `key` paramater.
2. `@Ref` decorator accepts `key` parameter.

3. New `@Provide` decorator

# Document Update

1. `@Ref`, which accepts `key` paramater.
1. `@Ref`, which accepts `key` parameter.

2. New `@Provide` decorator
4 changes: 2 additions & 2 deletions docs/en/class-component/accessor/accessor.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
## Usage

Property getters will be tranformed into `{computed:{get:Foo}}`.
Property getters will be transformed into `{computed:{get:Foo}}`.

[](./code-usage.ts ':include :type=code typescript')

## Writable

Property setters will be tranformed into `{computed:{set:Foo}}`.
Property setters will be transformed into `{computed:{set:Foo}}`.

[](./code-writable.ts ':include :type=code typescript')

Expand Down
2 changes: 1 addition & 1 deletion docs/en/class-component/event/event.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

We could define a method which triggers a vue event by `Emit` decorator.

The decorator received an optional event name paramater. Event will be triggered with this name and the method returned value. If the event name parameter is omitted, use method's name by default.
The decorator received an optional event name parameter. Event will be triggered with this name and the method returned value. If the event name parameter is omitted, use method's name by default.

[](./code-usage.ts ':include :type=code typescript')

Expand Down
2 changes: 1 addition & 1 deletion docs/en/class-component/hooks/hooks.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
## Usage

Class component supports almost all lifecycle hooks in vanilla vue. Write them as class methods directly. Hooks won't be tranformed into `methods`.
Class component supports almost all lifecycle hooks in vanilla vue. Write them as class methods directly. Hooks won't be transformed into `methods`.

> All these hooks must be methods of a class, not properties.
Expand Down
2 changes: 1 addition & 1 deletion docs/en/class-component/setup/setup.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
## Usage

Use the decorator `Setup` exported from `'vue-facing-decorator'` to inject [composables](https://vuejs.org/guide/reusability/composables.html) into your component's class as proeprty.
Use the decorator `Setup` exported from `'vue-facing-decorator'` to inject [composables](https://vuejs.org/guide/reusability/composables.html) into your component's class as property.

[](./code-usage-base.ts ':include :type=code typescript')

2 changes: 1 addition & 1 deletion docs/en/class-component/watcher/watcher.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Use `Watch` decorator to define a watcher in vue's `watch`.

The first parameter is the name watched.

Same as vue `watch`, the watcher receives two paremeters: new value and old value.
Same as vue `watch`, the watcher receives two parameters: new value and old value.

[](./code-usage.ts ':include :type=code typescript')

Expand Down
2 changes: 1 addition & 1 deletion docs/en/custom/custom.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Use `createDecorator` to build your own decorators.

If you are a package author, install vue-facing-decorator as `devDependecies` and mark it in `peerDependencies`.
If you are a package author, install vue-facing-decorator as `devDependencies` and mark it in `peerDependencies`.

`createDecorator` receives a creator function, which accepts two parameters:
1. Generated vue options component, you can modify it to implement anything you want.
Expand Down
4 changes: 2 additions & 2 deletions docs/en/inheritance/complex-example/complex-example.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Consider code:

[](./code-example.ts ':include :type=code typescript')

There are three components: `Comp`(includes `CompSper`), `SuperComp`(includes `SuperCompSuper`) and `VueNativeComponent`.
There are three components: `Comp`(includes `CompSuper`), `SuperComp`(includes `SuperCompSuper`) and `VueNativeComponent`.

The inheritance relationship is:

Expand All @@ -14,4 +14,4 @@ The inheritance relationship is:
vue extends (SuperComp ECMAScript extends SuperCompSuper)
```

Due to vue implemention, `VueNativeComponent`(useing vue `mixins`) will overwrite `SuperComp`(useing vue `extends`).
Due to vue implementation, `VueNativeComponent`(using vue `mixins`) will overwrite `SuperComp`(using vue `extends`).
4 changes: 2 additions & 2 deletions docs/en/migration/from-v2-to-v3.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

To migrate from v2, you need to change your project with some break changes.

In 3.x, decorator `Component` is same to `ComponentBase`, and you should cast class component to vue options API manually, see Breaking changes secion.
In 3.x, decorator `Component` is same to `ComponentBase`, and you should cast class component to vue options API manually, see Breaking changes section.

## Breaking changes

Expand All @@ -12,7 +12,7 @@ It is recommended to use `toNative` to transform a class component into a vue op

[](./from-v2-to-v3-breaking-changes-toNative.ts ':include :type=code typescript')

### Depreactate init class property despends on another in constructor
### Deprecate init class property depends on another in constructor

This is not allowed now.

Expand Down
2 changes: 1 addition & 1 deletion docs/en/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Works on TypeScript and decorator.

[](./quick-start/code-what-it-is-example.ts ':include :type=code typescript')

If you like deprecaed [vue-class-component](https://github.com/vuejs/vue-class-component) and deprecated [vue-property-decorator](https://github.com/kaorun343/vue-property-decorator), try this!
If you like deprecated [vue-class-component](https://github.com/vuejs/vue-class-component) and deprecated [vue-property-decorator](https://github.com/kaorun343/vue-property-decorator), try this!

Suggestion and contribution welcome.

Expand Down
4 changes: 2 additions & 2 deletions docs/en/tsx/attribute-types/attribute-types.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ To make enable TSX attribute types:

1. Import `TSX` function from this repo.

2. Define an interface(e.g. `Props`) to decribe properties in component.
2. Define an interface(e.g. `Props`) to describe properties in component.

3. Define an interface(e.g. `Events`) to decribe events in component.
3. Define an interface(e.g. `Events`) to describe events in component.

4. Make component extend from `TSX<Props,Events>()(BaseComponent)`.

Expand Down

0 comments on commit 76377a9

Please sign in to comment.