If you have a list before you try to write code, your code doesn't get styled.
Am I doing something wrong?
- Here's an example
Second item
code->this.doesnt(work.at_all)
Use the suggested method mentioned in @Oded's answer if you want to format as code in the last item of the list.
If you want to format as code outside the list, insert a comment between the last item of the list and the code. Like:
code
Markdown for this example:
- List item 1
- List item 2
<!-- Comment inserted to render code *outside* the list -->
code
You can also use an empty comment, i.e, <!---->
</>
or </
(not sure if the second one would cause more issues in some cases, though)
<!>
is a valid HTML comment and used it when required and the parser once got confused and misinterpreted stuff.
Commented
Jan 13, 2017 at 12:37
For code in lists to be interpreted as code, it needs to be indented 4 spaces further to the list indentation.
Second item
code->this.does(work.just_fine)
This is also noted in the editing help for advanced lists (pretty much the very last line of that).