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 optimizeDeps exclusion note for vite config #2877

Closed
wants to merge 1 commit into from

Conversation

mvanderlinde
Copy link

The current instructions for building one's first app using Vue + Vite does not work, and results in a net::ERR_ABORTED 504 (Outdated Optimize Dep) error.

Based on the discussion in ionic-team/pwa-elements#109 — and confirmed by my own testing — excluding the pwa-elements loader from Vite's dependency optimization fixes the issue in development.

It seems there may be lingering issues in production builds even with this fix based on that same open issue, but at the very least, this removes a current blocker in the documentation for users creating their first Ionic app.

The current instructions for building one's first app using Vue + Vite does not work, and results in a `net::ERR_ABORTED 504 (Outdated Optimize Dep)` error.

Based on the discussion in ionic-team/pwa-elements#109 — and confirmed by my own testing — excluding the `pwa-elements` loader from Vite's dependency optimization fixes the issue in development.

It seems there may be lingering issues in production builds even with this fix based on that same open issue, but at the very least, this removes a current blocker in the documentation for users creating their first Ionic app.
@vercel
Copy link

vercel bot commented Apr 4, 2023

@mvanderlinde is attempting to deploy a commit to the Ionic Team on Vercel.

A member of the Team first needs to authorize it.

@b4-io
Copy link

b4-io commented Apr 9, 2023

The lingering production problems are that vite doesn't include any of the pwa-elements libraries in the final build.
I don't find this to be an acceptable change as this isn't needed at all if the problem is fixed from the core.

@sean-perkins
Copy link
Contributor

Hello @mvanderlinde thanks for this suggested docs change.

Reviewing the active discussion on ionic-team/pwa-elements#109, I do not believe this is the best way to resolve this issue. It may suffice as a workaround to avoid the error, but it does not have the same behavior that the developer expects. The Ionic team should prioritize resolving the issue in PWA elements that is causing this exception to occur.

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.

3 participants