-
Notifications
You must be signed in to change notification settings - Fork 171
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
12 changed files
with
69 additions
and
52 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
/// <reference types="vite/client" /> | ||
/// <reference types="@remix-run/node" /> |
This file contains 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
This file was deleted.
Oops, something went wrong.
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
import { unstable_vitePlugin as remix } from "@remix-run/dev"; | ||
import { defineConfig, type UserConfig } from "vite"; | ||
import tsconfigPaths from "vite-tsconfig-paths"; | ||
// import { installGlobals } from "@remix-run/node"; | ||
// | ||
// installGlobals(); | ||
// Related: https://github.com/remix-run/remix/issues/2835#issuecomment-1144102176 | ||
// Replace the HOST env var with SHOPIFY_APP_URL so that it doesn't break the remix server. The CLI will eventually | ||
// stop passing in HOST, so we can remove this workaround after the next major release. | ||
if ( | ||
process.env.HOST && | ||
(!process.env.SHOPIFY_APP_URL || | ||
process.env.SHOPIFY_APP_URL === process.env.HOST) | ||
) { | ||
process.env.SHOPIFY_APP_URL = process.env.HOST; | ||
delete process.env.HOST; | ||
} | ||
export default defineConfig({ | ||
server: { | ||
port: Number(process.env.PORT || 3000), | ||
hmr: { | ||
protocol: "ws", | ||
port: 8009, | ||
host: "localhost", | ||
}, | ||
// vite automatically bypass cors in dev mode | ||
// https://vitejs.dev/config/server-options.html#server-cors | ||
// we don't need it | ||
cors: false, | ||
}, | ||
plugins: [ | ||
remix({ | ||
ignoredRouteFiles: ["**/.*"], | ||
}), | ||
tsconfigPaths(), | ||
], | ||
build: { | ||
assetsInlineLimit: 0, | ||
}, | ||
}) satisfies UserConfig; |