GregorBiswanger/VSCode-json2ts

case in json keys

Opened this issue · 4 comments

Hi somenone,

First of all, thank you for this awesome tool!!
I'm facing some issues when the json key starts with uppercase character.
For example, if i paste this json:

{
    "Name": "DXgEoXxD",
    "Age": 23,
    "Address": "Street 12 Nº 1234",
    "DocNumber": "12345678-9"
}

I expect to get this interface:

export interface RootObject {
	Name: string;
	Age: number;
	Address: string;
        DocNumber: string;
}

But instead, i get this one:

export interface RootObject {
	name: string;
	age: number;
	address: string;
        docNumber: string;
}

Thank you in advance for your support.

I have same problem !

problem

+1

i have a same problem

+1
It's better to preserve the case of the keys.