Skip to main content

Transform Code

With Transform Code, Ghostwriter can refactor your code to run faster, translate it into another language, and make your code easier to read

To use Transform Code, follow these steps:

  1. Select the block of code you want to transform. image
  2. Right-click in the editor to open up the context menu. image
  3. Select Transform code. image
  4. Type a prompt for what you would like to change about the highlighted code block in the provided text field.
  5. Press Transformimage
  6. Ghostwriter will provide a suggestion to transform your code. From here, you can choose to:
    A) Type a new prompt - Refine your prompt and try again.
    B) Transform - If you want to try again with the current prompt, press Transform again.
    C) Copy to clipboard - If you want to place this code somewhere other than what you highlighted, simply copy it to your clipboard.
    D) Replace selection - If you like the suggestion, click Replace selection to automatically substitute your highlighted code with Ghostwriter's suggestion.
    E) Share feedback - Don't like the suggestions? Help us improve by providing feedback.