Compare commits

...

2 Commits

Author SHA1 Message Date
09e8b8b94c 5.0.19 2024-06-19 17:43:56 +02:00
265f4df8b3 fix(core): update 2024-06-19 17:43:55 +02:00
3 changed files with 9 additions and 5 deletions

View File

@ -1,6 +1,6 @@
{ {
"name": "@push.rocks/npmextra", "name": "@push.rocks/npmextra",
"version": "5.0.18", "version": "5.0.19",
"private": false, "private": false,
"description": "A utility to enhance npm with additional configuration, tool management capabilities, and a key-value store for project setups.", "description": "A utility to enhance npm with additional configuration, tool management capabilities, and a key-value store for project setups.",
"main": "dist_ts/index.js", "main": "dist_ts/index.js",

View File

@ -3,6 +3,6 @@
*/ */
export const commitinfo = { export const commitinfo = {
name: '@push.rocks/npmextra', name: '@push.rocks/npmextra',
version: '5.0.18', version: '5.0.19',
description: 'A utility to enhance npm with additional configuration, tool management capabilities, and a key-value store for project setups.' description: 'A utility to enhance npm with additional configuration, tool management capabilities, and a key-value store for project setups.'
} }

View File

@ -3,6 +3,10 @@ import * as paths from './npmextra.paths.js';
import { KeyValueStore } from './npmextra.classes.keyvaluestore.js'; import { KeyValueStore } from './npmextra.classes.keyvaluestore.js';
import { env } from 'process'; import { env } from 'process';
export type DeepPartial<T> = {
[P in keyof T]?: T[P] extends object ? DeepPartial<T[P]> : T[P];
};
export interface IAppDataOptions<T = any> { export interface IAppDataOptions<T = any> {
dirPath?: string; dirPath?: string;
requiredKeys?: Array<keyof T>; requiredKeys?: Array<keyof T>;
@ -15,9 +19,9 @@ export interface IAppDataOptions<T = any> {
/** /**
* kvStoreKey: 'MY_ENV_VAR' * kvStoreKey: 'MY_ENV_VAR'
*/ */
envMapping?: { envMapping?: DeepPartial<{
[key in keyof T]?: string | object; [key in keyof T]: string | object;
}; }>;
} }
export class AppData<T = any> { export class AppData<T = any> {