Skip to content

Commit 4749590

Browse files
committed
refactor: property decorator
1 parent 553cab3 commit 4749590

File tree

5 files changed

+4
-5
lines changed

5 files changed

+4
-5
lines changed

.eslintrc.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ module.exports = {
1818
default: 'array-simple',
1919
},
2020
],
21-
'@typescript-eslint/ban-types': 'off',
2221
'@typescript-eslint/naming-convention': [
2322
'error',
2423
{

packages/runtime/src/decorators/customAttribute.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
export function CustomAttribute(_name: string, _value: string): Function {
1+
export function CustomAttribute(_name: string, _value: string): PropertyDecorator {
22
return () => {
33
return;
44
};

packages/runtime/src/decorators/deprecated.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* used to show a method as deprecated on swagger documentation
33
*/
4-
export function Deprecated(): Function {
4+
export function Deprecated(): PropertyDecorator & ClassDecorator & ParameterDecorator {
55
return () => {
66
return;
77
};

packages/runtime/src/decorators/example.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
export function Example<T>(exampleModel: T, exampleLabel?: string): Function {
1+
export function Example<T>(exampleModel: T, exampleLabel?: string): PropertyDecorator {
22
return () => {
33
return;
44
};

packages/runtime/src/decorators/extension.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
export function Extension(_name: string, _value: ExtensionType | ExtensionType[]): Function {
1+
export function Extension(_name: string, _value: ExtensionType | ExtensionType[]): PropertyDecorator {
22
return () => {
33
return;
44
};

0 commit comments

Comments
 (0)