We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent db20492 commit 7a4eefeCopy full SHA for 7a4eefe
src/common/resource.dto.ts
@@ -4,6 +4,7 @@ import {
4
FnLike,
5
mapValues,
6
setInspectOnClass,
7
+ setToJson,
8
} from '@seedcompany/common';
9
import { LazyGetter as Once } from 'lazy-get-decorator';
10
import { DateTime } from 'luxon';
@@ -295,6 +296,7 @@ export class EnhancedResource<T extends ResourceShape<any>> {
295
296
setInspectOnClass(EnhancedResource, (res) => ({ collapsed }) => {
297
return collapsed(res.name, 'Enhanced');
298
});
299
+setToJson(EnhancedResource, (res) => ({ name: res.name }));
300
301
export interface EnhancedRelation<TResourceStatic extends ResourceShape<any>> {
302
readonly name: RelKey<TResourceStatic>;
0 commit comments