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

feat(remix-dev)!: remove browserBuildDirectory config option #6900

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/silver-readers-think.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@remix-run/dev": major
---

Remove `browserBuildDirectory` config option
28 changes: 1 addition & 27 deletions packages/remix-dev/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,14 +100,6 @@ export interface AppConfig {
*/
assetsBuildDirectory?: string;

/**
* The path to the browser build, relative to remix.config.js. Defaults to
* "public/build".
*
* @deprecated Use `{@link AppConfig.assetsBuildDirectory}` instead
*/
browserBuildDirectory?: string;

/**
* The URL prefix of the browser build with a trailing slash. Defaults to
* `"/build/"`. This is the path the browser will use to find assets.
Expand Down Expand Up @@ -785,14 +777,8 @@ export async function readConfig(
? path.resolve(appDirectory, userEntryServerFile)
: path.resolve(defaultsDirectory, entryServerFile);

if (appConfig.browserBuildDirectory) {
browserBuildDirectoryWarning();
}

let assetsBuildDirectory =
appConfig.assetsBuildDirectory ||
appConfig.browserBuildDirectory ||
path.join("public", "build");
appConfig.assetsBuildDirectory || path.join("public", "build");

let absoluteAssetsBuildDirectory = path.resolve(
rootDirectory,
Expand Down Expand Up @@ -1018,18 +1004,6 @@ let disjunctionListFormat = new Intl.ListFormat("en", {
type: "disjunction",
});

let browserBuildDirectoryWarning = () =>
logger.warn(
"The `browserBuildDirectory` config option will be removed in v2",
{
details: [
"You can use the `assetsBuildDirectory` config option instead.",
"-> https://remix.run/docs/en/v1.15.0/pages/v2#browserbuilddirectory",
],
key: "browserBuildDirectoryWarning",
}
);

let serverBuildDirectoryWarning = () =>
logger.warn(
"The `serverBuildDirectory` config option will be removed in v2",
Expand Down