Skip to content

Failed to resolve remix:manifest on fresh create-remix app #10515

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

Open
tmacwill opened this issue Mar 2, 2025 · 20 comments
Open

Failed to resolve remix:manifest on fresh create-remix app #10515

tmacwill opened this issue Mar 2, 2025 · 20 comments

Comments

@tmacwill
Copy link

tmacwill commented Mar 2, 2025

Reproduction

Steps to reproduce:

  1. Run npx create-remix@latest.
  2. Run npm run dev in the newly created project (i.e., without modifying any files).
  3. Load the project in the web browser.
  4. Observe the below console warning:
6:23:37 PM [vite] (client) warning: Failed to resolve "remix:manifest" from /Users/tmac/tmp/thing/node_modules/.vite/deps/@remix-run_react.js?v=5ceadf52. An id should be written. Did you pass a URL?
  Plugin: vite:import-analysis
  File: /Users/tmac/tmp/thing/node_modules/.vite/deps/@remix-run_react.js?v=5ceadf52:8656:26
  8654|  });
  8655|  if (import.meta && import.meta.hot) {
  8656|    import.meta.hot.accept("remix:manifest", async ({
     |                           ^
  8657|      assetsManifest,
  8658|      needsRevalidation

This can also be reproduced by simply navigating to https://remix.new and observing the terminal panel.

Downgrading to vite@5 makes this warning go away.

System Info

System:
    OS: macOS 15.2
    CPU: (8) arm64 Apple M2
    Memory: 172.50 MB / 8.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 22.14.0 - ~/.nvm/versions/node/v22.14.0/bin/node
    npm: 10.9.2 - ~/.nvm/versions/node/v22.14.0/bin/npm
  Browsers:
    Brave Browser: 133.1.75.180
    Chrome: 133.0.6943.142
    Safari: 18.2
  npmPackages:
    @remix-run/dev: ^2.16.0 => 2.16.0
    @remix-run/node: ^2.16.0 => 2.16.0
    @remix-run/react: ^2.16.0 => 2.16.0
    @remix-run/serve: ^2.16.0 => 2.16.0
    vite: ^6.0.0 => 6.2.0

Used Package Manager

npm

Expected Behavior

Creating a new project, running it, and opening it in a browser should have no warnings (i.e., on vite 6).

Actual Behavior

Creating a new project, running it, and opening it in a browser has a warning.

@ezetojo
Copy link

ezetojo commented Mar 3, 2025

oh, so it's not my project...

[vite] (client) warning: Failed to resolve "remix:manifest" from ***/node_modules/.vite/deps/@remix-run_react.js?v=118ba05b. An id should be written. Did you pass a URL?
  Plugin: vite:import-analysis
  File: ***/node_modules/.vite/deps/@remix-run_react.js?v=118ba05b:3151:26
  3149|  });
  3150|  if (import.meta && import.meta.hot) {
  3151|    import.meta.hot.accept("remix:manifest", async ({
     |                           ^
  3152|      assetsManifest,
  3153|      needsRevalidation

@jovemexausto
Copy link

jovemexausto commented Mar 3, 2025

I'm also facing this issue.

"node_modules/vite": {
      "version": "6.2.0",
      "resolved": "https://registry.npmjs.org/vite/-/vite-6.2.0.tgz",
      "integrity": "sha512-7dPxoo+WsT/64rDcwoOjk76XHj+TqNTIvHKcuMQ1k4/SeHDaQt5GFAeLYzrimZrMpn/O6DtdI03WUjdxuPM0oQ==",
      "dev": true,
      "license": "MIT",
      "dependencies": {
        "esbuild": "^0.25.0",
        "postcss": "^8.5.3",
        "rollup": "^4.30.1"
      }
    }
    "node_modules/@remix-run/node": {
      "version": "2.16.0",
      "resolved": "https://registry.npmjs.org/@remix-run/node/-/node-2.16.0.tgz",
      "integrity": "sha512-9yYBYCHYO1+bIScGAtOy5/r4BoTS8E5lpQmjWP99UxSCSiKHPEO76V9Z8mmmarTNis/FPN+sUwfmbQWNHLA2vw==",
      "license": "MIT",
      "dependencies": {
        "@remix-run/server-runtime": "2.16.0",
        "@remix-run/web-fetch": "^4.4.2",
        "@web3-storage/multipart-parser": "^1.0.0",
        "cookie-signature": "^1.1.0",
        "source-map-support": "^0.5.21",
        "stream-slice": "^0.1.2",
        "undici": "^6.11.1"
      }

@erufenix
Copy link

erufenix commented Mar 3, 2025

Same here, same problem when running del dev

[vite] (client) warning: Failed to resolve "remix:manifest" from /Volumes/Develop/devs/webs/tobiweb-s/node_modules/.vite/deps/@remix-run_react.js?v=d727e5cc. An id should be written. Did you pass a URL? Plugin: vite:import-analysis File: /Volumes/Develop/devs/webs/tobiweb-s/node_modules/.vite/deps/@remix-run_react.js?v=d727e5cc:8656:26 8654| }); 8655| if (import.meta && import.meta.hot) { 8656| import.meta.hot.accept("remix:manifest", async ({ | ^ 8657| assetsManifest, 8658| needsRevalidation

`
➤ vite --version
vite/6.0.7 darwin-arm64 node-v23.6.0
edgarhtech@mini:~

➤ node --version
v23.6.0
`
Remix 2.16

@dunea
Copy link

dunea commented Mar 4, 2025

Me too

@dev-erich
Copy link

Same issue here:

10:24:56 PM [vite] (client) warning: Failed to resolve "remix:manifest" from ***/node_modules/.vite/deps/@remix-run_react.js?v=b0d3e421. An id should be written. Did you pass a URL?
  Plugin: vite:import-analysis
  File: ***/node_modules/.vite/deps/@remix-run_react.js?v=b0d3e421:8656:26
  8654|  });
  8655|  if (import.meta && import.meta.hot) {
  8656|    import.meta.hot.accept("remix:manifest", async ({
     |                           ^
  8657|      assetsManifest,
  8658|      needsRevalidation

@bnleft
Copy link

bnleft commented Mar 4, 2025

Ran into this issue too and found this workaround (might not the best) for this warning by creating a custom plugin to intercept the remix:manifest import.
Vite v6 might have added stricter rules for resolving imports and prob expects properly resolved module paths.

Example vite.config.ts:

import { vitePlugin as remix } from "@remix-run/dev";
import { defineConfig } from "vite";
import tsconfigPaths from "vite-tsconfig-paths";

declare module "@remix-run/node" {
  interface Future {
    v3_singleFetch: true;
  }
}

export default defineConfig({
  plugins: [
    remix({
      future: {
        v3_fetcherPersist: true,
        v3_relativeSplatPath: true,
        v3_throwAbortReason: true,
        v3_singleFetch: true,
        v3_lazyRouteDiscovery: true,
      },
    }),
    // Custom plugin resolves warning - Failed to resolve "remix:manifest" from /Users/... An id should be written. Did you pass a URL?
    {
      name: "remix-manifest-resolver",
      resolveId(id) {
        if (id === "remix:manifest") {
          return id;
        }
      },
      // Optional: warning is suppressed without this hook
      // Provides an empty object for 'remix:manifest' if HMR triggers, but HMR remains non-functional
      load(id) {
        if (id === "remix:manifest") {
          return "export default {}";
        }
      }
    },
    tsconfigPaths(),
  ],
});

Resources
(Vite extends Rollup)
resolveId: https://rollupjs.org/plugin-development/#resolveid
load: https://rollupjs.org/plugin-development/#load

@HandersonLuc
Copy link

HandersonLuc commented Mar 6, 2025

I thought I had installed a package incorrectly, I'm happy to know it's not just me, but I'm sad because I don't know how to solve it.

[vite] (client) warning: Failed to resolve "remix:manifest" from ***/node_modules/.vite/deps/@remix-run_react.js?v=64bfa5ad. An id should be written. Did you pass a URL?
  Plugin: vite:import-analysis
  File:***/node_modules/.vite/deps/@remix-run_react.js?v=64bfa5ad:8656:26
  8654|  });
  8655|  if (import.meta && import.meta.hot) {
  8656|    import.meta.hot.accept("remix:manifest", async ({
     |                           ^
  8657|      assetsManifest,
  8658|      needsRevalidation

@pcldev
Copy link

pcldev commented Mar 6, 2025

There is another workaround, I tried to downgrade version of remix-run to ^2.10.3.

@fourcolors
Copy link

I have the same issue

@harihar-nautiyal
Copy link

I too have same issue

Image

@gbresciano
Copy link

same issue

@MattyBalaam
Copy link

MattyBalaam commented Mar 11, 2025

As OP states, if you have Vite 6.x installed our case was fixed by reverting to Vite 5.x

@davepeck
Copy link

davepeck commented Mar 11, 2025

FWIW this was the very first thing I encountered the very first time I ever tried Remix (yesterday!). Alas.

@MattyBalaam
Copy link

FWIW this was the very first thing I encountered the very first time I ever tried Remix (yesterday!). Alas.

FYI if you are starting out you should be using React Route 7 in Framework mode, all new development is happening there.

@davepeck
Copy link

davepeck commented Mar 11, 2025

FYI if you are starting out you should be using React Route 7 in Framework mode, all new development is happening there.

Like the original bug reporter, I also encountered this with a simple npx create-remix@latest — I assume that uses whatever the latest goodness is? Or is that no longer the right way to start things?

Update: ah, I see, I should have done npx create-react-router@latest instead; that gets the latest goodness. As someone vaguely aware of the Remix universe, but brand new to it, I missed the whole "we're now merged with React Router". I'm guessing I'm not the only one. In any case... thanks!

@YunosukeYoshino
Copy link

same issue

@wensiyuanseven
Copy link

Me too

@iamyahia
Copy link

Is there any solution?
I face the same problem when creating a fresh remix project npx create-remix@latest.

@WahidinAji
Copy link

-r

https://discord.com/channels/770287896669978684/1349423586758361221/1350502129285988465

someone just dropped this. he changes the version of the VITE to v5 instead

@MattyBalaam
Copy link

The new 2.16.1 release fixes this for me.

https://github.com/remix-run/remix/blob/main/CHANGELOG.md#v2161

ActualNugget added a commit to ethanctan/ai-oa that referenced this issue Mar 24, 2025
trunk-io bot pushed a commit to arcjet/arcjet-js that referenced this issue Mar 27, 2025
Remix is supposed to support Vite 6 now, but when I upgrade I get the same error as [a lot of people](remix-run/remix#10515).

It seems that Remix is [being replaced by React Router v7](https://remix.run/blog/react-router-v7) in Framework mode so I'm not sure when the linked issue will be resolved.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests