Skip to content

refactor(web): abstract prismTabs creation in TriggerSnippetTabs (#4493) #8650

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

Open
wants to merge 1 commit into
base: next
Choose a base branch
from

Conversation

ultimateebeast
Copy link

🧹 Refactor Overview

This PR refactors the TriggerSnippetTabs component to move the prism tab generation logic into a helper function (createTriggerSnippetTabs). This makes the component cleaner and improves maintainability.

✅ What’s Changed

  • Extracted tab configuration logic (Node.js and Curl) from inside the component
  • Created a reusable function to dynamically generate tab definitions
  • Kept the tab behavior and UI unchanged

🧪 Tested

  • ✅ Verified that both Node.js and Curl tabs render correctly
  • ✅ Tested with dynamic trigger input data

Closes #4493

Copy link

netlify bot commented Jul 6, 2025

👷 Deploy request for dashboard-v2-novu-staging pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 0cb8388

@ultimateebeast ultimateebeast changed the title refactor: abstract prismTabs creation in TriggerSnippetTabs (#4493) refactor(trigger-snippet-tabs): abstract prismTabs creation (#4493) Jul 6, 2025
@ultimateebeast ultimateebeast changed the title refactor(trigger-snippet-tabs): abstract prismTabs creation (#4493) refactor(web): abstract prismTabs creation in TriggerSnippetTabs (#4493) Jul 6, 2025
@ultimateebeast
Copy link
Author

Hi! I've addressed #4493 by refactoring the TriggerSnippetTabs component. Let me know if you'd like any changes. Thanks for reviewing!

@scopsy
Copy link
Contributor

scopsy commented Jul 6, 2025

@ultimateebeast not sure how does this related to the issue you tagged

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[NV-3044] 🚀 Feature: Support Weixin/Wechat
2 participants