We are working on Code Hike v1.0

Code Blocks

The fundamental building block of Code Hike is the code block. There are several ways to write code blocks inside markdown. The most common way is to wrap the code using triple backticks:

lorem.mdx

## Lorem ipsum
```
print("Hello, world!")
```
dolor **sit** amet

Syntax highlighting

If you specify a language after the ``` Code Hike will apply syntax highlighting to the code.

lorem.mdx

### Lorem ipsum
```python
print("Hello, world!")
```
dolor **sit** amet

Languages

Code Hike handles syntax highlighting for 196 languages: abap, actionscript-3, ada, apache, apex, apl, applescript, ara, asm, astro, awk, ballerina, bat, batch, berry, be, bibtex, bicep, blade, c, cadence, cdc, clarity, clojure, clj, cmake, cobol, codeql, ql, coffee, cpp, crystal, csharp, c#, cs, css, cue, d, dart, dax, diff, docker, dockerfile, dream-maker, elixir, elm, erb, erlang, erl, fish, fsharp, f#, fs, gdresource, gdscript, gdshader, gherkin, git-commit, git-rebase, glsl, gnuplot, go, graphql, groovy, hack, haml, handlebars, hbs, haskell, hs, hcl, hlsl, html, http, imba, ini, properties, java, javascript, js, jinja-html, jison, json, json5, jsonc, jsonnet, jssm, fsl, jsx, julia, kotlin, kusto, kql, latex, less, liquid, lisp, logo, lua, make, makefile, markdown, md, marko, matlab, mdx, mermaid, nginx, nim, nix, objective-c, objc, objective-cpp, ocaml, pascal, perl, php, plsql, postcss, powerquery, powershell, ps, ps1, prisma, prolog, proto, pug, jade, puppet, purescript, python, py, r, raku, perl6, razor, reg, rel, riscv, rst, ruby, rb, rust, rs, sas, sass, scala, scheme, scss, shaderlab, shader, shellscript, bash, console, sh, shell, zsh, smalltalk, solidity, sparql, sql, ssh-config, stata, stylus, styl, svelte, swift, system-verilog, tasl, tcl, tex, toml, tsx, turtle, twig, typescript, ts, v, vb, cmd, verilog, vhdl, viml, vim, vimscript, vue-html, vue, wasm, wenyan, 文言, wgsl, xml, xsl, yaml, yml, and zenscript.

Filename

If you add a title after the language, Code Hike will show a different UI featuring the filename:

lorem.mdx

### Lorem ipsum
```python hello.py
print("Hello, world!")
```
dolor **sit** amet