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

TS Path aliases seem to break type output #456

Open
sami616 opened this issue Jun 7, 2020 · 0 comments
Open

TS Path aliases seem to break type output #456

sami616 opened this issue Jun 7, 2020 · 0 comments

Comments

@sami616
Copy link

sami616 commented Jun 7, 2020

For example:

Works ✅

import { Theme } from '../themes/Theme'

export interface IconProps {
  /** The color to use */
  color?: keyof Theme['color']
}

Yikes! ❌

import { Theme } from @themes/Theme'

export interface IconProps {
  /** The color to use */
  color?: keyof Theme['color']
}

The bottom results in the following type annotation being output:

string | number | symbol instead of the expected 'primary' | 'secondary' | 'tertiary'

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

1 participant