Skip to content
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

When I use 'remark-gfm 'to parse the table, it will get stuck #1150

Closed
4 tasks done
luoluo5945 opened this issue Apr 25, 2023 · 2 comments
Closed
4 tasks done

When I use 'remark-gfm 'to parse the table, it will get stuck #1150

luoluo5945 opened this issue Apr 25, 2023 · 2 comments
Labels
🤷 no/invalid This cannot be acted upon 👎 phase/no Post cannot or will not be acted on

Comments

@luoluo5945
Copy link

luoluo5945 commented Apr 25, 2023

Initial checklist

Affected packages and versions

"remark": "^14.0.2", "remark-gfm": "^3.0.1",

Link to runnable example

No response

Steps to reproduce

import {remark} from 'remark';
import slug from 'remark-slug';
import githubFlavored from 'remark-gfm';
import htmlPlugin from 'remark-html';

const getHtml = (content: string) => {
    return remark()
        .use(slug)
        .use(githubFlavored)
        .use(htmlPlugin, {sanitize: false})
        .processSync(content)
        .toString();
};

TIP:The following is the markdown file where I encountered the problem. I tried to check the file with lint-md and found no problem, but the page froze after parsing with the above function, which was initially attributed to the use of the 'remark-gfm 'plugin

## config

| Configuration Key  | Configuration Value                                                                      | Comment                                                                           |
|--------------------|------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------|
| aaa | aaa | ccc |
| aaa | aaa | ccc |
| aaa | aaa | ccc |
| Endpoint           | workspace                                                                                | title                                                                        |
| ---                | ---                                                                                      | ---                                                                               |
| aaa | aaa | ccc |
| aaa | aaa | ccc |
| aaa | aaa | ccc |
| Region             | where                                                                                       | title                                                                |
| ---                | ---                                                                                      | ---                                                                               |
| aaa | aaa | ccc |
| aaa | aaa | ccc |
| aaa | aaa | ccc |
| DeviceHubLocalName | dh-1                                                                                     | Windmill-device devicehub                             |
| ---                | ---                                                                                      | ---                                                                               |
| aaa | aaa | ccc |
| aaa | aaa | ccc |
| aaa | aaa | ccc |
| TimeoutMS          | 20000                                                                                    | tsm/meerkat                                                            |
| ---                | ---                                                                                      | ---                                                                               |
| aaa | aaa | ccc |
| aaa | aaa | ccc |
| aaa | aaa | ccc |
| TimeoutMS          | 60000                                                                                    | gaea-transform                                                       |
| ---                | ---                                                                                      | ---                                                                               |
| aaa | aaa | ccc |
| aaa | aaa | ccc |
| aaa | aaa | ccc | 
| GPUMem             | 5000                                                                                     | trt                                                                  |
| ---                | ---                                                                                      | ---                                                                               |
| ***Servings***       | ***Servings***                                                                           | title                                                |
| ***Edge***          | ***Edge***                                                                               | title                                                                      |
| aaa | aaa | ccc |
| aaa | aaa | ccc |
| aaa | aaa | ccc |

Expected behavior

Normal analysis

Actual behavior

Page stuck

Runtime

No response

Package manager

yarn 1

OS

macOS

Build and bundle tools

Webpack

@github-actions github-actions bot added 👋 phase/new Post is being triaged automatically 🤞 phase/open Post is being triaged manually and removed 👋 phase/new Post is being triaged automatically labels Apr 25, 2023
@ChristianMurphy
Copy link
Member

Hey @luoluo5945! 👋
Sorry you ran into a spot of trouble.
I'm unable to replicate the issue as you describe in a sandbox
https://codesandbox.io/s/remark-slug-gfm-and-html-o11b1g

Some ideas on how to debug:

  1. check that all dependencies are up-to-date
  2. check which version of node you are using, consider using the latest LTS (https://nodejs.org/en)
  3. check if you have any other scripts on the page which could be causing it to freeze

Feel free to add a minimal reproducible example in a sandbox, like codesandbox or stackblitz, if you still believe this is a bug here.
For now I'm closing this out as it doesn't appear to be an issue here.

@ChristianMurphy ChristianMurphy added the 🤷 no/invalid This cannot be acted upon label Apr 25, 2023
@github-actions

This comment has been minimized.

@github-actions github-actions bot added 👎 phase/no Post cannot or will not be acted on and removed 🤞 phase/open Post is being triaged manually labels Apr 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🤷 no/invalid This cannot be acted upon 👎 phase/no Post cannot or will not be acted on
Development

No branches or pull requests

2 participants