Skip to content

Conversation

@fernando-aviles
Copy link
Contributor

@fernando-aviles fernando-aviles commented Jan 8, 2026

Greptile Overview

Greptile Overview

Greptile Summary

This PR adds a custom GitHub Flavored Markdown (GFM) plugin to the gt-remark package by implementing remarkGfmCustom. The plugin registers GFM extensions for strikethrough, tables, task lists, and footnotes.

Key Changes:

  • Added remarkGfmCustom plugin that configures micromark and mdast extensions for GFM features
  • Added 8 new dependencies: 4 micromark extensions and 4 mdast utilities
  • Exported remarkGfmCustom alongside existing escapeHtmlInTextNodes plugin

Issues Found:

  • Missing tests for the new remarkGfmCustom plugin - no verification it works correctly
  • Plugin implementation uses data-only pattern (doesn't return transformer), which is valid but should be tested to ensure GFM features work as expected

Confidence Score: 3/5

  • This PR is functionally safe but lacks test coverage for new functionality
  • The implementation follows unified plugin patterns correctly and adds standard GFM dependencies. However, the new remarkGfmCustom plugin has zero test coverage, making it impossible to verify it works correctly with strikethrough, tables, task lists, and footnotes. The existing escapeHtmlInTextNodes has comprehensive tests, but the new plugin needs similar coverage.
  • Pay attention to packages/remark/src/index.ts - the new plugin needs testing before production use

Important Files Changed

File Analysis

Filename Score Overview
packages/remark/src/index.ts 3/5 Added custom GFM plugin implementation with all GFM extensions, but missing tests and no return statement clarification
packages/remark/package.json 5/5 Added 8 new GFM-related dependencies for micromark extensions and mdast utilities

Sequence Diagram

sequenceDiagram
    participant User
    participant Unified as Unified Processor
    participant Plugin as remarkGfmCustom
    participant Data as Processor Data
    participant Extensions as GFM Extensions
    
    User->>Unified: .use(remarkGfmCustom)
    Unified->>Plugin: Call plugin function
    Plugin->>Data: Access this.data()
    Plugin->>Data: Initialize extension arrays
    Plugin->>Extensions: Load micromark extensions
    Extensions-->>Plugin: gfmStrikethrough, gfmTable, etc.
    Plugin->>Data: Push to micromarkExtensions
    Plugin->>Extensions: Load from/to markdown utils
    Extensions-->>Plugin: gfmStrikethroughFromMarkdown, etc.
    Plugin->>Data: Push to fromMarkdownExtensions
    Plugin->>Data: Push to toMarkdownExtensions
    Plugin-->>Unified: Extensions registered
    Unified->>User: Processor ready with GFM support
Loading

Important Files Changed

File Analysis

Filename Score Overview
packages/remark/src/index.ts 3/5 Added custom GFM plugin implementation with all GFM extensions, but missing tests and no return statement clarification
packages/remark/package.json 5/5 Added 8 new GFM-related dependencies for micromark extensions and mdast utilities

Sequence Diagram

sequenceDiagram
    participant User
    participant Unified as Unified Processor
    participant Plugin as remarkGfmCustom
    participant Data as Processor Data
    participant Extensions as GFM Extensions
    
    User->>Unified: .use(remarkGfmCustom)
    Unified->>Plugin: Call plugin function
    Plugin->>Data: Access this.data()
    Plugin->>Data: Initialize extension arrays
    Plugin->>Extensions: Load micromark extensions
    Extensions-->>Plugin: gfmStrikethrough, gfmTable, etc.
    Plugin->>Data: Push to micromarkExtensions
    Plugin->>Extensions: Load from/to markdown utils
    Extensions-->>Plugin: gfmStrikethroughFromMarkdown, etc.
    Plugin->>Data: Push to fromMarkdownExtensions
    Plugin->>Data: Push to toMarkdownExtensions
    Plugin-->>Unified: Extensions registered
    Unified->>User: Processor ready with GFM support
Loading

@fernando-aviles fernando-aviles requested a review from a team as a code owner January 8, 2026 22:11
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 files reviewed, 2 comments

Edit Code Review Agent Settings | Greptile

@fernando-aviles fernando-aviles merged commit 24987af into main Jan 8, 2026
19 checks passed
@fernando-aviles fernando-aviles deleted the f/gfm-plugin branch January 8, 2026 22:27
@github-actions github-actions bot mentioned this pull request Jan 8, 2026
archie-mckenzie pushed a commit that referenced this pull request Jan 8, 2026
This PR was opened by the [Changesets
release](https://github.com/changesets/action) GitHub action. When
you're ready to do a release, you can merge this and the packages will
be published to npm automatically. If you're not ready to do a release
yet, that's fine, whenever you add more changesets to main, this PR will
be updated.


# Releases
## [email protected]

### Patch Changes

- [#938](#938)
[`24987af`](24987af)
Thanks [@fernando-aviles](https://github.com/fernando-aviles)! - Adding
custom GFM plugin

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants