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

Detect current file? #1

Open
diegohaz opened this issue Jul 4, 2017 · 1 comment
Open

Detect current file? #1

diegohaz opened this issue Jul 4, 2017 · 1 comment

Comments

@diegohaz
Copy link
Contributor

diegohaz commented Jul 4, 2017

Hey, @Dennitz. Amazing job you've done here.

I don't know very much about vscode plugin API, but I wonder if it's possible to detect the current opened file and provide a second command to quickly duplicate it. Similar to generact path/to/component.js.

Thank you,

@Dennitz
Copy link
Owner

Dennitz commented Jul 4, 2017

@diegohaz
I guess vscode.window.activeTextEditor.document.fileName will do that.
On that note, maybe we should also provide a menu item for generact when a component is right-clicked in the file explorer.

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