Skip to content
This repository has been archived by the owner on Feb 28, 2022. It is now read-only.

Wrong HTML rendering with lists #458

Closed
tripodsan opened this issue Sep 17, 2019 · 14 comments
Closed

Wrong HTML rendering with lists #458

tripodsan opened this issue Sep 17, 2019 · 14 comments
Assignees
Labels
bug Something isn't working good first issue Good for newcomers

Comments

@tripodsan
Copy link
Contributor

tripodsan commented Sep 17, 2019

the following lists are rendered correctly in github:

## Then numbered lists:
1. First install the dependencies:  
`$ npm install`
1. Bar **bold**
1. Fruits
    1. Apple
    1. Oranges
    1. Lemons
        1. Roman
        1. Greek  
Muiltiline  
With `code`.
        1. Spanish

Then numbered lists:

  1. First install the dependencies:
    $ npm install
  2. Bar bold
  3. Fruits
    1. Apple
    2. Oranges
    3. Lemons
      1. Roman
      2. Greek
        Muiltiline
        With code.
      3. Spanish

but the pipeline produces:

Then numbered lists:

  1. First install the dependencies:
    $ npm install
  2. Bar bold
  3. Fruits 1. Apple 1. Oranges 1. Lemons 1. Roman 1. Greek
    Muiltiline
    With code. 1. Spanish
@tripodsan
Copy link
Contributor Author

tripodsan commented Sep 17, 2019

another example:

### **Demos**
You can watch the entire recording here
1. Server timing & DOM based HTL engine
1. Helix Pages & auto-generated sequence diagrams
1. Performance analysis of Helix OpenWhisk actions
1. Authoring user journey
1. Dev experience: Helix 6 months ago and today

Demos

You can watch the entire recording here

  1. Server timing & DOM based HTL engine
  2. Helix Pages & auto-generated sequence diagrams
  3. Performance analysis of Helix OpenWhisk actions
  4. Authoring user journey
  5. Dev experience: Helix 6 months ago and today

pipeline:

You can watch the entire recording here. 1. Server timing & DOM based HTL engine 1. Helix Pages & auto-generated sequence diagrams 1. Performance analysis of Helix OpenWhisk actions 1. Authoring user journey 1. Dev experience: Helix 6 months ago and today


adding an empty line before the list fixes the problem.

@tripodsan tripodsan added bug Something isn't working good first issue Good for newcomers labels Sep 18, 2019
@derekneuland
Copy link

derekneuland commented Oct 3, 2019

@tripodsan I'll take this!

@derekneuland
Copy link

Can you point me in the right direction to which file should be edited?

@MarquiseRosier
Copy link
Contributor

@derekneuland I can help you :) were you able to reproduce the issue?

@MarquiseRosier
Copy link
Contributor

MarquiseRosier commented Oct 3, 2019

There's a few ways to reproduce. You can use the helix-cli demo, You can follow the instructions in the helix-cli Readme at https://www.github.com/adobe/helix-cli

You'll learn how to create a demo project.

Plug the code that's giving erroneous output; into your demo's md file,
then run
hlx up --local-repo [root of your demo dir] --dev-default HTTP_TIMEOUT 3000

This should reproduce the error.

Or

you can even; take the markdown that's giving the bad result and plug it into one of the tests in https://github.com/adobe/helix-pipeline/blob/master/test/testHTMLFromMarkdown.js

From there set some breakpoints and follow the flow of execution. You should find the code that dictates how some of the markdown is rendered! Welcome, and thanks for contributing! :)

Keep pinging and asking questions; we're happy to help

@lex111
Copy link

lex111 commented Oct 8, 2019

I did some investigation, current issues can be solved, but links with spaces (because is that link is not a valid markdown link) and links references (because this bug in the remark) will stop working. 😕

@tripodsan
Copy link
Contributor Author

@derekneuland / @lex111 Still working on this?

@lex111
Copy link

lex111 commented Oct 15, 2019

@tripodsan I'm stuck :(

@MarquiseRosier MarquiseRosier self-assigned this Oct 29, 2019
@MarquiseRosier
Copy link
Contributor

I'll take this; @lex111 unless you're still open to working on it.

@lex111 hey you referenced an issue with link parsing; what did you find?

@tripodsan I'm starting to think this is an issue with how remark-parse handles lists; I'm going to do some more investigating

@MarquiseRosier
Copy link
Contributor

@lex111

This is related to; it's unresolved: they're making up a fix :)
remarkjs/remark#315

@lex111
Copy link

lex111 commented Oct 30, 2019

@MarquiseRosier cool, unfortunately I gave up, but hope this issue will be resolved soon.

@MarquiseRosier
Copy link
Contributor

Hey folks! Looks like this is about to be fixed!! :)

remarkjs/remark#315 (comment)

By PR:
remarkjs/remark#536

@trieloff
Copy link
Contributor

trieloff commented Oct 2, 2020

Cool, and scary, as this will probably break a few other things for us.

@tripodsan
Copy link
Contributor Author

won't fix.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

5 participants