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

add deprecation warning to Tabs constructor #767

Merged
merged 1 commit into from
Mar 3, 2017
Merged

Conversation

giladgray
Copy link
Contributor

Changes proposed in this pull request:

  • Utils.isNodeEnv helper function checks value of process.env.NODE_ENV.

@blueprint-bot
Copy link

add deprecation warning to Tabs constructor

Preview: docs
Coverage: core | datetime

@giladgray giladgray requested a review from adidahiya March 3, 2017 19:34
declare var process: { env: any };

/** Returns whether `process.env.NODE_ENV` exists and equals `env`. */
export function isNodeEnv(env: string) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

consider limiting this string type to just "development" | "production" | "test"

Copy link
Contributor Author

@giladgray giladgray Mar 3, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seems overkill. also you don't get autocomplete so there's little advantage.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no, I think it's actually quite meaningful -- why would you compare to other values?

vscode actually does give me autocomplete :P

image

@giladgray giladgray merged commit 4125150 into master Mar 3, 2017
@giladgray giladgray deleted the gg/deprecate-tabs branch March 3, 2017 19:38
@giladgray giladgray mentioned this pull request Mar 4, 2017
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

Successfully merging this pull request may close these issues.

3 participants