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

Fixed recursive wrapping of data function that leads to memory leak (asyncData plugin). #66

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

Conversation

mr-luke
Copy link

@mr-luke mr-luke commented May 13, 2022

What kind of change does this PR introduce?

Fixed memory leak of asyncData plugin.

What is the current behavior?

There's a recursive wrapping of data function which adds a new level each time SSR renders same component. This leads up to stuck references of asyncData variable that cannot be collected by GC.

What is the new behavior?

Under first attempt the original data function is cloned to internal options' property to ensure that each wrapping works on correct function.

Checklist:

  • Documentation
  • Tests

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.

1 participant