-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use ordered list with code block #121
Comments
I agree that the number is resetting, but you're also not using lists correctly. I guess we could consider this a bug in deno-gfm, but let me show you what I mean first. Compare this source: 1. test
```ts
const foo: string = "";
```
87. asdf
```ts
const foo: string = "";
```
2. foo
```ts
const foo: string = "";
``` Which renders like this:
const foo: string = "";
const foo: string = "";
const foo: string = ""; Against this source: 1. test
```ts
const foo: string = "";
```
87. asdf
```ts
const foo: string = "";
```
2. foo
```ts
const foo: string = "";
``` Which renders like this:
Note how the code blocks in the second example are indented and how the numbers are irrelevant. In your original example and my first example, they are not. This means the code blocks aren't actually part of the list, and in reality, there are multiple lists. So if there's a bug here, it's that deno-gfm doesn't preserve the initial value of a single item ordered list. Instead, you should indent your blocks with four spaces in order to get them to participate in the list. Btw, it would be helpful to include the source of the markdown example. You can escape your markdown by using a different delimiter for the code block, e.g. I would leave this issue open because there is obviously a discrepancy with what github does. This likely causes confusion to others as well. |
Question
How can I use code block inside an ordered list? The number is reseting. Example below
db/schema.ts
para criar tabelas.db:setup:deps
no seu terminal para instalar asdependências necessárias para realizar o schema migration. É necessário
versão do deno maior ou igual a 1.43.0 e utilizar a variável de ambiente
DENO_FUTURE=1
para habilitar a instalação de módulos npm.The result from GitHub's markdown ☝️
The result with deno-gfm's markdown 👇
The text was updated successfully, but these errors were encountered: