inconsistent owner in Component function (production vs development build) result in out of order onCleanup
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 36.1k
- Forks
- 1.1k
- Avg merge
- 9h 18m
- Merged PRs (30d)
- 195
Description
Describe the bug
A component function owner is different between a dev and prod build
function MyComponent(){
getOwner() // <-- this is different between prod/dev builds.
// in prod the owner is of the parent, in dev it is a new owner scope.
return <></>
}
this inconsistency causes unexpected behavior, for example when using solid's onCleanup primitive

note: production build is working as designed, it is dev that alters the expectations
Your Example Website or App
.
Steps to Reproduce the Bug or Issue
see playground links for the difference between dev and prod
Expected behavior
it is expected that dev and prod will work similarly, in regard to owner scopes.
Screenshots or Videos
No response
Platform
.
Additional context
No response
related discussion of the issue
https://discord.com/channels/722131463138705510/1075879661134942238
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with getOwner and onCleanup behavior in the linked development and production playgrounds, then compare how the two builds establish component owner scopes. Done means development and production behave consistently for owner scopes and cleanup ordering, matching the stated production behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100
