Skip to content

Conversation

@brian-smith-tcril
Copy link
Contributor

BREAKING CHANGE: rename mfeConfigApiUrl to runtimeConfigJsonUrl
BREAKING CHANGE: remove siteId from config URL building

add cache buster for development environments

BREAKING CHANGE: rename `mfeConfigApiUrl` to `runtimeConfigJsonUrl`
BREAKING CHANGE: remove `siteId` from config URL building

add cache buster for development environments
Comment on lines -168 to +169
const { mfeConfigApiUrl, siteId } = getSiteConfig();
const { runtimeConfigJsonUrl, environment } = getSiteConfig();
Copy link
Contributor Author

Choose a reason for hiding this comment

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

My understanding of the new runtime config architecture is that the build-time site config will just point to a URL, and we won't have a concept of siteId.

Comment on lines +177 to +181
// In development mode, add a timestamp as a cache buster
// to support live-editing runtime config JSON
if (environment === EnvironmentTypes.DEVELOPMENT) {
runtimeConfigUrl.searchParams.set('timestamp', Date.now());
}
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is super helpful for local dev (live editing the json and seeing things update). I'm not sure if this is a pattern we're happy with, and I'm very open to other ideas about how to handle this use case.

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.

1 participant