question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Can I change the default code font in markdown code blocks?

See original GitHub issue

Description

I noticed that default codes font in code blocks is Courier (or Courier New) and I want to change it to Consolas. I try to change css file in static/themes/ then build, but it doesn’t work.

In line 349 of file dark.css, I changed the code as show below.

code {
  ...
  font-family: Menlo, Monaco, Consolas, "Courier New", monospace;
}
code {
  ...
  font-family: Consolas;
}

Is there some ways to change the font?

Versions

  • OS: Ubuntu 16.04

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
fxhacommented, Apr 21, 2018

@DingShizhe Please open hamburger menu and select View and click on Toggle Developer Tools or View -> Toggle Developer Tools on macOS.

0reactions
Jocscommented, Apr 27, 2018

@DingShizhe If not more question, I’ll close this issue, you can still ask or track this issue here.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Markdown cheat sheet - Squarespace Help Center
Use this cheat sheet for syntax reference in the Markdown language. You can use Markdown in the Markdown block.
Read more >
7.3 Style code blocks and text output | R Markdown Cookbook
7.3 Style code blocks and text output. We can customize the style of code chunks and their text output using the chunk options...
Read more >
fonts - Why are code blocks and code literals displaying with ...
Under Markdown Code Face , uncheck/delete everything and then save. This will make the code face the same as the default face.
Read more >
How to set a monopaced font in code-blocks? - Stack Overflow
Yes, you do need a mode that highlights markdown code. ... If you set default face to a monospace font, that font will...
Read more >
Code blocks | Docusaurus
You can add a title to the code block by adding a title key after the language (leave a space between them). ```jsx...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found