Skip to content

Commit 1ae74cf

Browse files
committed
Bugfix: modern decorator support
1 parent 05c5891 commit 1ae74cf

File tree

4 files changed

+26
-20
lines changed

4 files changed

+26
-20
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [2.2.1] - 2024-02-18
9+
10+
### Fixed
11+
12+
- TypeScript 5 decorators do not work.
13+
814
## [2.2.0] - 2023-10-03
915

1016
### Added

package-lock.json

Lines changed: 15 additions & 15 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77
},
88
"peerDependencies": {
99
"lodash": "^4.17.0",
10-
"@dipscope/type-manager": "^7.1.1",
11-
"@dipscope/entity-store": "^2.0.3"
10+
"@dipscope/type-manager": "^7.2.1",
11+
"@dipscope/entity-store": "^2.0.4"
1212
},
1313
"devDependencies": {
1414
"@types/jasmine": "^3.6.3",

src/json-api-resource.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { Entity } from '@dipscope/entity-store';
2-
import { TypeFn, TypeManager } from '@dipscope/type-manager';
2+
import { TypeDecorator, TypeFn, TypeManager } from '@dipscope/type-manager';
33
import { JsonApiResourceMetadata } from './json-api-resource-metadata';
44
import { JsonApiResourceOptions } from './json-api-resource-options';
55

@@ -8,9 +8,9 @@ import { JsonApiResourceOptions } from './json-api-resource-options';
88
*
99
* @param {TypeOptions<TType>} jsonApiResourceOptions Json api resource options.
1010
*
11-
* @returns {ClassDecorator} Class decorator.
11+
* @returns {TypeDecorator} Type decorator.
1212
*/
13-
export function JsonApiResource<TEntity extends Entity>(jsonApiResourceOptions: JsonApiResourceOptions): ClassDecorator
13+
export function JsonApiResource<TEntity extends Entity>(jsonApiResourceOptions: JsonApiResourceOptions): TypeDecorator
1414
{
1515
return function (target: any): any
1616
{

0 commit comments

Comments
 (0)