rynop / dynamodb-local

A wrapper for AWS DynamoDB Local, intended for use in testcases
MIT License
53 stars 30 forks source link

Can not specify the value for '-dbPath' due to type restriction with using Typescript #48

Closed masaori closed 1 year ago

masaori commented 1 year ago

Type definition

type argValues = '-cors' | '-dbPath' | '-delayTransientStatuses' | '-help' | '-inMemory' | '-optimizeDbBeforeStartup' | '-port' | '-sharedDb';
export function launch(portNumber: number, dbPath?: string | null, args?: argValues[], verbose?: boolean, detached?: any, javaOpts?: string): Promise<ChildProcess>;

Typescript regard as a type error when I specify the value for -dbPath in args array.

Screen Shot 2023-05-10 at 15 16 51

How can I specify the path for the db file?

masaori commented 1 year ago

Sorry I misunderstood the signature of that function. Will close.