Skip to content
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

fix(module:code-editor): load Monaco only once #7033

Merged

Conversation

arturovt
Copy link
Member

@arturovt arturovt commented Nov 3, 2021

PR Checklist

PR Type

What kind of change does this PR introduce?

[x] Bugfix

What is the current behavior?

We should load Monaco only once, it even has a warning within its source code (see the screenshot). This applies to apps that are bootstrapped and destroyed multiple times.

monaco-warning

What is the new behavior?

Monaco is ensured to be loaded only once.

Does this PR introduce a breaking change?

[ ] Yes
[x] No

@zorro-bot
Copy link

zorro-bot bot commented Nov 3, 2021

This preview will be available after the AzureCI is passed.

@codecov
Copy link

codecov bot commented Nov 3, 2021

Codecov Report

Merging #7033 (f074cc7) into master (b18c050) will decrease coverage by 0.04%.
The diff coverage is 23.80%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #7033      +/-   ##
==========================================
- Coverage   89.52%   89.48%   -0.05%     
==========================================
  Files         489      488       -1     
  Lines       15768    15772       +4     
  Branches     2573     2572       -1     
==========================================
- Hits        14117    14113       -4     
- Misses       1011     1018       +7     
- Partials      640      641       +1     
Impacted Files Coverage Δ
components/code-editor/code-editor.service.ts 18.98% <23.80%> (+0.67%) ⬆️
components/tabs/tab-nav-bar.component.ts 82.26% <0.00%> (-0.71%) ⬇️
components/code-editor/typings.ts

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b18c050...f074cc7. Read the comment docs.

Copy link
Member

@wzhudev wzhudev left a comment

Choose a reason for hiding this comment

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

LGTM. Thanks!

@hsuanxyz hsuanxyz merged commit e1eafec into NG-ZORRO:master Nov 4, 2021
@arturovt arturovt deleted the fix/code-editor-load-monaco-once branch November 4, 2021 11:20
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.

3 participants