Feat/static generation - #629
Closed
jimhlad wants to merge 7 commits into
Closed
Conversation
👷 Deploy request for nuxt-image-v1 pending review.Visit the deploys page to approve it
|
Contributor
Author
|
Updated to address issue outlined here: #614 (comment) |
Contributor
Author
|
Updated to fix issue with srcset image generation |
|
This works great. Please merge asap |
pi0
reviewed
Nov 24, 2022
| const ipxOptions = { | ||
| ...(useRuntimeConfig().ipx || {}), | ||
| // TODO: Switch to storage API when ipx supports it | ||
| dir: fileURLToPath(new URL('../public', import.meta.url)) |
Member
There was a problem hiding this comment.
This workaround works also for the production .output/ directory structure as path is resolved at runtime. If we do resolve() in src/ipx.ts, full path of build environment will be into the bundle.
Member
Contributor
Author
|
Thanks @pi0 . Does it work with multiple formatters at the same time though (e.g. width, height and quality)? I recall I had to add Also had some issues using |
Member
|
Feel free to open PR for other issues ❤️ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is a modified version of @pi0 's PR for static image generation (took the heavy lifting from there).
Would be interested to get a second pair of eyes from @danielroe or someone on the Nuxt team.
P.S. Not sure if creating a separate PR was the best approach. Feel free to close this out if it's way off the mark or if modifying the original PR is easier. Thanks!