githubnext / githubnext/vscode-react-webviews
Info: How to pass in a message from another command to the webview?
- Lingua principale
- TypeScript
- Stelle
- 11
- Fork
- 3
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
I have tried exposing a ``postMessage`` function in ``NextViewWebpanel`` class and then posting a message to ``this.panel.webview.postMessage``, but I can't get it working. I'd like to update the VSCodeAPI State.
What is the best practice in updating the state of the webview from another command?
Some context:
I'm trying to pass text from the editor to the webview.
Thank you in advance!
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Direzione di ricerca
Read the NextViewWebpanel class and the command that is meant to pass editor text to the webview, then trace the call to this.panel.webview.postMessage and the VSCodeAPI state update. The issue does not name a file or test, so completion would require defining and verifying a working message flow first.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- typescript, vscode
- Ambito
- tooling
- Tipo di issue
- Funzionalità
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Stato di attività
- Ferma
- Chiarezza
- Da chiarire
- Idoneità per principianti
- 15/100