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

Add a hook to run some code during preloading code #12544

Closed
CNSeniorious000 opened this issue Aug 4, 2024 · 1 comment
Closed

Add a hook to run some code during preloading code #12544

CNSeniorious000 opened this issue Aug 4, 2024 · 1 comment
Labels
feature request New feature or request

Comments

@CNSeniorious000
Copy link

Describe the problem

Some module is large, but not compatible with SSR. So I can only import it dynamically in an onMount or if (browser) block. But I still want them to be preloaded during that page got preloaded by preloadCode or data-sveltekit-preload-code.

An example is monaco-editor.

Describe the proposed solution

Add a hook like beforePreload in $app/navigation.

Alternatives considered

For now I can only write them in on:mouseover besides data-sveltekit-preload-code or write them after preloadCode

Importance

nice to have

Additional Information

No response

@eltigerchino eltigerchino added the feature request New feature or request label Oct 25, 2024
@eltigerchino
Copy link
Member

closing as duplicate of #9542

@eltigerchino eltigerchino closed this as not planned Won't fix, can't repro, duplicate, stale Oct 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants