Inbox by Gmail – How to Format Text as Code

formattinginbox-by-gmail

I sent an email today (or wanted to) from Inbox by Gmail and was disappointed at the apparent lack of ability to format text as code when compiling an email:

enter image description here

How can I format text as code (or simply in any different font, for that matter) with Inbox by Gmail?

Best Answer

You can install the Markdown Here extension for Chrome and write the code in markdown format in the email compose window.

You can either write the code with a four-space indent:

    this is
    some code

Or with the triple backtick format:

```
this is
some code
```

Then, to turn the markdown code into a properly formatted email, activate the extension by right-clicking and selecting Markdown Toggle from the menu, clicking the extension button next to the address bar, or using the hotkey Ctrl Alt M.

Before and after screenshot:

screenshot