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

Feature request: repl: add type inspection command #17072

Open
win-t opened this issue Dec 16, 2022 · 2 comments
Open

Feature request: repl: add type inspection command #17072

win-t opened this issue Dec 16, 2022 · 2 comments
Labels
repl related to the Read-Eval-Print-Loop functionality of Deno suggestion suggestions for new features (yet to be agreed)

Comments

@win-t
Copy link

win-t commented Dec 16, 2022

Hello, I have an idea.
I think we need a command to inspect the type of a symbol, something like :type command in ghci
it is a command that only available in repl
for example

> :type console.log
console.log : (...data: any[]) => void
> import * as react from `npm:react'
undefined
> :type react.useEffect
react.useEffect : (effect: EffectCallback, deps?: DependencyList) => void

of course, this feature is only available to any symbol that has a typescript declaration

@win-t
Copy link
Author

win-t commented Dec 16, 2022

maybe related to #16938 and #16800
I think it is better to have a command that is only available on repl instead of exposing the functionality as a dedicated function
psql is also another repl that I know to have this command separation

@dsherret
Copy link
Member

Related: #11078 (comment)

@dsherret dsherret added repl related to the Read-Eval-Print-Loop functionality of Deno suggestion suggestions for new features (yet to be agreed) labels Dec 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
repl related to the Read-Eval-Print-Loop functionality of Deno suggestion suggestions for new features (yet to be agreed)
Projects
None yet
Development

No branches or pull requests

2 participants