Skip to content

Conversation

@ematipico
Copy link
Member

@ematipico ematipico commented Sep 1, 2025

Changes

This PR refactors how the manifest is computed and pulled during development and build.

There's a new module called astro:serialized-manifest. While it returns a deserialised manifest, it's actually deserialised during its creation. It means that it's computed from AstroSettings, and it's deserialised inside the virtual module.

Happy to bikeshed the name.

Now astro:config/server and astro:config/client use this module to pull the information. Plus, I refactored them to use this.environment.name instead of opts.ssr

Testing

Updated. They should all pass

Docs

N/A

@changeset-bot
Copy link

changeset-bot bot commented Sep 1, 2025

⚠️ No Changeset found

Latest commit: 4c16b50

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@github-actions github-actions bot added the pkg: astro Related to the core `astro` package (scope) label Sep 1, 2025
@ematipico ematipico force-pushed the env-api/vite-plugin-routes branch from fdc3bab to f4db70b Compare September 1, 2025 13:13
@ematipico ematipico changed the title refactor: use environments to load modules (#14191) refactor: manifest as virtual module Sep 1, 2025
@ematipico ematipico marked this pull request as ready for review September 1, 2025 14:06
@ematipico ematipico force-pushed the env-api/vite-plugin-routes branch from 9b7cb7d to f0a6635 Compare September 1, 2025 14:22
Copy link
Contributor

@ascorbic ascorbic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like a good approach

@ematipico ematipico force-pushed the env-api/vite-plugin-routes branch from 2f18cc3 to 2868ab2 Compare September 2, 2025 11:05
@github-actions github-actions bot added feat: markdown Related to Markdown (scope) pkg: svelte Related to Svelte (scope) pkg: example Related to an example package (scope) 🚨 action Modifies GitHub Actions pkg: integration Related to any renderer integration (scope) docs pr labels Sep 2, 2025
@ematipico ematipico force-pushed the env-api/vite-plugin-routes branch from f17f70c to 4c16b50 Compare September 2, 2025 13:39
@github-actions github-actions bot removed the feat: markdown Related to Markdown (scope) label Sep 2, 2025
@github-actions github-actions bot removed pkg: svelte Related to Svelte (scope) pkg: example Related to an example package (scope) 🚨 action Modifies GitHub Actions pkg: integration Related to any renderer integration (scope) docs pr labels Sep 2, 2025
@ematipico
Copy link
Member Author

I'll investigate later why the integration tests time out. I'll merge the PR for now

@ematipico ematipico merged commit 15a3eab into feat/environment-api Sep 2, 2025
9 of 14 checks passed
@ematipico ematipico deleted the env-api/vite-plugin-routes branch September 2, 2025 14:12
ematipico added a commit that referenced this pull request Sep 3, 2025
ematipico added a commit that referenced this pull request Sep 3, 2025
* refactor: use environments to load modules (#14191)

* refactor: make `App` more extensible using `BaseApp` (#14197)

* refactor: App to extends the new BaseApp (#14213)

* refactor: manifest as virtual module (#14298)

* refactor: create `generate` when needed

* fix type

* remove type

* fix types

* fix breakage of code
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pkg: astro Related to the core `astro` package (scope)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants