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

chore(edit-content): improve load time in edit content form #30392

Merged
merged 3 commits into from
Oct 18, 2024

Conversation

nicobytes
Copy link
Contributor

@nicobytes nicobytes commented Oct 18, 2024

Proposed Changes

#30389

Summary

This pull request includes significant changes to the dot-edit-content-field component in the core-web library. The main updates involve deferring the rendering of various field components and removing the now unnecessary DotEditContentFieldsModule.

Rendering Optimization:

  • Added @defer (on immediate) directive to defer the rendering of multiple field components in dot-edit-content-field.component.html to improve performance. (core-web/libs/edit-content/src/lib/components/dot-edit-content-field/dot-edit-content-field.component.html)
Screenshot 2024-10-18 at 10 05 57 AM

Module Refactoring:

  • Removed the DotEditContentFieldsModule and updated the imports to include individual field components directly in dot-edit-content-field.component.ts. (core-web/libs/edit-content/src/lib/components/dot-edit-content-field/dot-edit-content-field.component.ts) [1] [2]
  • Deleted the now redundant DotEditContentFieldsModule file. (core-web/libs/edit-content/src/lib/fields/dot-edit-content-fields.module.ts)

Checklist

  • Tests
  • Translations
  • Security Implications Contemplated (add notes if applicable)

Screenshots

With all fields, each field is loaded only when necessary.

Frame 10

When the user selects a few fields, only those fields are loaded

Frame 11

This PR fixes: #30389

@nicobytes nicobytes linked an issue Oct 18, 2024 that may be closed by this pull request
Copy link

@nicobytes nicobytes marked this pull request as ready for review October 18, 2024 15:16
@nicobytes nicobytes changed the title 30389 improve load time in edit content form chore(edit-content): improve load time in edit content form Oct 18, 2024
@nicobytes nicobytes added this pull request to the merge queue Oct 18, 2024
Merged via the queue into main with commit 017c6b8 Oct 18, 2024
20 checks passed
@nicobytes nicobytes deleted the 30389-improve-load-time-in-edit-content-form branch October 18, 2024 18:22
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.

Improve load time in edit-content form
5 participants