-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Feedback source
None
GitHub Copilot plugin version
0.14.0
Eclipse IDE and version
Version: 2025-12 (4.38.0) Build id: 20251204-0850
Platform
Windows 11
Steps to reproduce
Prompt: Output a comparison of web components vs plain vanillajs in a table to build a simple visual toggle.
Any prompt resulting in a markdown table being output will generate the same issue
Logs (optional)
No response
Expected behavior
A proper table should be visualized
Actual behavior
The plain-text version of the table markdown is shown.
| Aspect | Plain Vanilla JS | Web Components | |--------|------------------|----------------| | Setup | Find a DIV, attach handlers directly | Define a custom element class, register with customElements.define() | | HTML Usage |
+ initTagManager('#myTags') | | | Style Isolation | None—CSS can bleed in/out, must use unique class names | Shadow DOM provides full encapsulation | | Reusability | Copy/paste JS + CSS, call init function | Just use the HTML tag anywhere | | Form Integration | Manually create/update hidden input | Same, or use ElementInternals API | | Dependencies | None | None | | Browser Support | All browsers | All modern browsers (IE11 needs polyfill) | | File Structure | Separate JS + CSS files, or inline | Single self-contained JS file | | Initialization | Explicit: TagManager.init(element, options) | Automatic: element self-initializes when added to DOM | | Multiple Instances | Must call init for each instance | Just add multiple tags | | Configuration | Pass options object to init function | Use HTML attributes: | | Event Handling | Custom callbacks or manual event dispatch | Native CustomEvent dispatch, use addEventListener | | Cleanup | Manual: must track and remove listeners | Automatic via disconnectedCallback() | | Learning Curve | Low—standard DOM manipulation | Medium—must learn lifecycle callbacks, Shadow DOM | | Debugging | Straightforward DOM inspection | Shadow DOM adds a layer in DevTools | | Framework Compatibility | Works anywhere with minor integration | Works anywhere as native HTML element | | Code Size | Minimal boilerplate | ~20-30 extra lines for class structure | | Attribute Reactivity | Manual: watch for changes yourself | Built-in: attributeChangedCallback() | | Semantic HTML | Generic with classes | Custom element name conveys meaning |
Additional information
No response
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working