Codeblock

You should reference the official site documentation. https://gohugo.io/content-management/syntax-highlighting/

  • Normal usage of code block

    ```javascript
    console.log('Hello World!');
    ```
    
  • You can set the code-block title and line number to $, > symbol.

    ```>:s22adg.sh
    agasgas
    ```
    
    ```$:sadg.sh
    agasgas
    agasgas
    agasgas
    agasgas
    agasgas
    ```
    
    ```:/etc/profile.java
    System.out.println();
    ```
    
    code-block with title, symbol line number
    Code Block: with title, symbol line number

    You could also do this.

    ```javascript:etc/dir/myscript.js
    console.log('Hello World!');
    ```
    

Just keep in mind that the code block title should end with extensions. (e.g: .js, .c, .python) otherwise, the code-block would not render properly