Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Map<Integer, WhatEver> x produces field with string key instead of number key #80

Open
atsu85 opened this issue Mar 26, 2017 · 1 comment

Comments

@atsu85
Copy link
Collaborator

atsu85 commented Mar 26, 2017

Generating TypeScript from

class Bug {
  Map<Integer, String> intKeyMap;
}

produces

export interface Bug {
    intKeyMap: { [key: string ]: string;};
  // intKeyMap: { [key: number]: string;}; // <-- EXPECTED
}

but expecting number to be the key instead of string

@crummy
Copy link

crummy commented Nov 9, 2021

I think objects in JS always are keyed by string.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants