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 commands to send JS to chrome for execution #110

Open
christoomey opened this issue Nov 1, 2015 · 0 comments
Open

Add commands to send JS to chrome for execution #110

christoomey opened this issue Nov 1, 2015 · 0 comments
Labels

Comments

@christoomey
Copy link
Owner

Using chrome-cli I can execute arbitrary JS in a page context. Just need to slap together the right system call from Vim. A start:

function! s:ExecuteInPageConsole()
  let line = escape(getreg("."), "'")
  silent call system("chrome-cli execute '" . line . "'")
endfunction

command! ExecuteInPageConsole call <sid>ExecuteInPageConsole()
@christoomey christoomey added the vim label Nov 1, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant