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

Incorrect type definitions for env function #116

Open
AlexKomm opened this issue Sep 9, 2022 · 0 comments
Open

Incorrect type definitions for env function #116

AlexKomm opened this issue Sep 9, 2022 · 0 comments

Comments

@AlexKomm
Copy link

AlexKomm commented Sep 9, 2022

This packages provides the following type definitions:

declare module "@beam-australia/react-env" { function env(key: string): string export = env }

The problem is that env function returns undefined if env variable is not present.

Also key parameter should be optional and in this case, function returns an object containing all available env variables

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 a pull request may close this issue.

1 participant