MonacoEditor: Console error when used twice in seperate tabs
See original GitHub issueDescribe the bug My Page consists of a TabView with several tabs. Two of them each contain one MonacoEditor. When switching tabs from one editor to the other, the following error is thrown in the console. This goes away after reloading via F5.
VM6290:5 Element already has context attribute: ui-monaco-editor-ed
C @ VM6290:5
createScoped @ VM6290:5
e @ VM6290:5
L @ VM6290:5
R @ VM6290:5
(anonymous) @ VM6290:5
W @ VM6290:5
U @ VM6290:5
a._doRender @ eNp9j9EOwjAIRb9o8r6_qS3bWFuopc1c4scbnXGmOl-4N3DIBZgVBrFVT7PeUqaIg7Go_XypmFfY5N-sS6GOxO2-lYxfrZiEkUvLDhSwpiDGwW4bRm2WEJJhDPDhG2qS4nGFTZpZkWoneFZdKDXXdXgtyErC2v_sHuPnINZXgpc2scSplmjUw9s1hDMFE1mPGXZ7HBeFjRV0VCTDQm7E0hEH4sdHdxLLuWI.js.seam?ln=omnifaces.combined&v=1615471860000:711
a._render @ eNp9j9EOwjAIRb9o8r6_qS3bWFuopc1c4scbnXGmOl-4N3DIBZgVBrFVT7PeUqaIg7Go_XypmFfY5N-sS6GOxO2-lYxfrZiEkUvLDhSwpiDGwW4bRm2WEJJhDPDhG2qS4nGFTZpZkWoneFZdKDXXdXgtyErC2v_sHuPnINZXgpc2scSplmjUw9s1hDMFE1mPGXZ7HBeFjRV0VCTDQm7E0hEH4sdHdxLLuWI.js.seam?ln=omnifaces.combined&v=1615471860000:710
render @ eNp9j9EOwjAIRb9o8r6_qS3bWFuopc1c4scbnXGmOl-4N3DIBZgVBrFVT7PeUqaIg7Go_XypmFfY5N-sS6GOxO2-lYxfrZiEkUvLDhSwpiDGwW4bRm2WEJJhDPDhG2qS4nGFTZpZkWoneFZdKDXXdXgtyErC2v_sHuPnINZXgpc2scSplmjUw9s1hDMFE1mPGXZ7HBeFjRV0VCTDQm7E0hEH4sdHdxLLuWI.js.seam?ln=omnifaces.combined&v=1615471860000:464
(anonymous) @ eNp9j9EOwjAIRb9o8r6_qS3bWFuopc1c4scbnXGmOl-4N3DIBZgVBrFVT7PeUqaIg7Go_XypmFfY5N-sS6GOxO2-lYxfrZiEkUvLDhSwpiDGwW4bRm2WEJJhDPDhG2qS4nGFTZpZkWoneFZdKDXXdXgtyErC2v_sHuPnINZXgpc2scSplmjUw9s1hDMFE1mPGXZ7HBeFjRV0VCTDQm7E0hEH4sdHdxLLuWI.js.seam?ln=omnifaces.combined&v=1615471860000:464
invokeDeferredRenders @ eNp9j9EOwjAIRb9o8r6_qS3bWFuopc1c4scbnXGmOl-4N3DIBZgVBrFVT7PeUqaIg7Go_XypmFfY5N-sS6GOxO2-lYxfrZiEkUvLDhSwpiDGwW4bRm2WEJJhDPDhG2qS4nGFTZpZkWoneFZdKDXXdXgtyErC2v_sHuPnINZXgpc2scSplmjUw9s1hDMFE1mPGXZ7HBeFjRV0VCTDQm7E0hEH4sdHdxLLuWI.js.seam?ln=omnifaces.combined&v=1615471860000:458
postTabShow @ eNp9j9EOwjAIRb9o8r6_qS3bWFuopc1c4scbnXGmOl-4N3DIBZgVBrFVT7PeUqaIg7Go_XypmFfY5N-sS6GOxO2-lYxfrZiEkUvLDhSwpiDGwW4bRm2WEJJhDPDhG2qS4nGFTZpZkWoneFZdKDXXdXgtyErC2v_sHuPnINZXgpc2scSplmjUw9s1hDMFE1mPGXZ7HBeFjRV0VCTDQm7E0hEH4sdHdxLLuWI.js.seam?ln=omnifaces.combined&v=1615471860000:539
show @ eNp9j9EOwjAIRb9o8r6_qS3bWFuopc1c4scbnXGmOl-4N3DIBZgVBrFVT7PeUqaIg7Go_XypmFfY5N-sS6GOxO2-lYxfrZiEkUvLDhSwpiDGwW4bRm2WEJJhDPDhG2qS4nGFTZpZkWoneFZdKDXXdXgtyErC2v_sHuPnINZXgpc2scSplmjUw9s1hDMFE1mPGXZ7HBeFjRV0VCTDQm7E0hEH4sdHdxLLuWI.js.seam?ln=omnifaces.combined&v=1615471860000:539
select @ eNp9j9EOwjAIRb9o8r6_qS3bWFuopc1c4scbnXGmOl-4N3DIBZgVBrFVT7PeUqaIg7Go_XypmFfY5N-sS6GOxO2-lYxfrZiEkUvLDhSwpiDGwW4bRm2WEJJhDPDhG2qS4nGFTZpZkWoneFZdKDXXdXgtyErC2v_sHuPnINZXgpc2scSplmjUw9s1hDMFE1mPGXZ7HBeFjRV0VCTDQm7E0hEH4sdHdxLLuWI.js.seam?ln=omnifaces.combined&v=1615471860000:539
(anonymous) @ eNp9j9EOwjAIRb9o8r6_qS3bWFuopc1c4scbnXGmOl-4N3DIBZgVBrFVT7PeUqaIg7Go_XypmFfY5N-sS6GOxO2-lYxfrZiEkUvLDhSwpiDGwW4bRm2WEJJhDPDhG2qS4nGFTZpZkWoneFZdKDXXdXgtyErC2v_sHuPnINZXgpc2scSplmjUw9s1hDMFE1mPGXZ7HBeFjRV0VCTDQm7E0hEH4sdHdxLLuWI.js.seam?ln=omnifaces.combined&v=1615471860000:539
dispatch @ eNp9j9EOwjAIRb9o8r6_qS3bWFuopc1c4scbnXGmOl-4N3DIBZgVBrFVT7PeUqaIg7Go_XypmFfY5N-sS6GOxO2-lYxfrZiEkUvLDhSwpiDGwW4bRm2WEJJhDPDhG2qS4nGFTZpZkWoneFZdKDXXdXgtyErC2v_sHuPnINZXgpc2scSplmjUw9s1hDMFE1mPGXZ7HBeFjRV0VCTDQm7E0hEH4sdHdxLLuWI.js.seam?ln=omnifaces.combined&v=1615471860000:68
v.handle @ eNp9j9EOwjAIRb9o8r6_qS3bWFuopc1c4scbnXGmOl-4N3DIBZgVBrFVT7PeUqaIg7Go_XypmFfY5N-sS6GOxO2-lYxfrZiEkUvLDhSwpiDGwW4bRm2WEJJhDPDhG2qS4nGFTZpZkWoneFZdKDXXdXgtyErC2v_sHuPnINZXgpc2scSplmjUw9s1hDMFE1mPGXZ7HBeFjRV0VCTDQm7E0hEH4sdHdxLLuWI.js.seam?ln=omnifaces.combined&v=1615471860000:68
Reproducer Will work on this later. The combined resources handler currently makes it quite unreadable, sorry.
Environment:
- PF Version: 10.0.0
- JSF + version:Mojarra 2.3.14_
- Affected browsers: ALL
To Reproduce Steps to reproduce the behavior:
will follow up
Expected behavior No console error should appear.
Issue Analytics
- State:
- Created 2 years ago
- Comments:20 (15 by maintainers)
Top Results From Across the Web
Editor action is run twice in Firefox #2178 - GitHub
In Firefox, this worked fine in Monaco Editor version 0.20.0, but broke in version 0.21.0. It can still be reproduced in the latest...
Read more >Monaco Editor AddComment event fires twice - Stack Overflow
I have configured the Monaco Editor to fire an event when Ctrl+S using AddCommand: <html> <head> <meta charset="utf-8" /> <style ...
Read more >All Docs - Quark.js
Monaco editor provides rich IntelliSense, validation and out of the box support for for HTML, CSS, SCSS, JSON, JavaScript and TypeScript. Your browser...
Read more >Monaco Editor Monarch - Microsoft Open Source
This document describes how to create a syntax highlighter using the Monarch library. This library allows you to specify an efficient syntax highlighter,...
Read more >1786043 – Alert Manager Monaco editor show duplicate info
Description of problem: When user make some invalid changes in Alert Manager YAML editor(Monaco editor), hover the invalid string will show duplicate error...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

@blutorange You probably want to override the
destroyandrefreshlisteners in the widget to dispose of the current editor.@blutorange : Thank you, scrollbeyondlastline indeed solved this issue.