Skip to content

feat: simplify#1589

Open
k11kirky wants to merge 1 commit into04-09-feat_refactor_improve_stabilityfrom
04-09-feat_simplify
Open

feat: simplify#1589
k11kirky wants to merge 1 commit into04-09-feat_refactor_improve_stabilityfrom
04-09-feat_simplify

Conversation

@k11kirky
Copy link
Copy Markdown
Contributor

@k11kirky k11kirky commented Apr 9, 2026

TLDR

Simplified PostHog enricher initialization and improved API ergonomics by removing manual setup requirements and adding file parsing capabilities.

Changes

  • Removed manual initialization: Grammar files are now bundled and auto-located at runtime, eliminating the need to call initialize() or specify WASM directory paths
  • Added file parsing: New parseFile() method automatically detects language from file extensions and reads files directly
  • Improved property naming: Renamed enrichedFlags and enrichedEvents to flags and events for cleaner API
  • Enhanced comment formatting: Removed restriction that limited one comment per source line
  • Updated documentation: Revised README examples to reflect the simplified API and new capabilities
  • Added language detection: Exported EXT_TO_LANG_ID mapping for file extension to language ID conversion

Copy link
Copy Markdown
Contributor Author

k11kirky commented Apr 9, 2026

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

This stack of pull requests is managed by Graphite. Learn more about stacking.

@k11kirky k11kirky force-pushed the 04-09-feat_simplify branch from a4faaa7 to 1f593e3 Compare April 10, 2026 14:16
@k11kirky k11kirky marked this pull request as ready for review April 10, 2026 14:16
@k11kirky k11kirky requested a review from adboio April 10, 2026 16:34
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.

1 participant