clauderic / dnd-kit

The modern, lightweight, performant, accessible and extensible drag & drop toolkit for React.
http://dndkit.com
MIT License
12.71k stars 632 forks source link

Trouble installing `@dnd-kit/react` #1444

Closed sgup closed 3 months ago

sgup commented 3 months ago

Hi, I'm getting the following error when installing/using the newer @dnd-kit/react with Next "15.0.0-rc.0" and using pnpm to install:

[0]  ⨯ ./node_modules/.pnpm/@dnd-kit+react@0.0.3_react-dom@19.0.0-rc-fb9a90fa48-20240614_react@19.0.0-rc-fb9a90fa48-20240_7fouwnkzrvn3iryviz2lpazhdy/node_modules/@dnd-kit/react/index.js:1:1
[0] Module not found: Can't resolve './chunk-RDUPMLCN.js'
[0] > 1 | import { DragDropContext } from './chunk-RDUPMLCN.js';
[0]     | ^
[0]   2 | import { lazy, useContext, useCallback, useEffect } from 'react';
[0]   3 | import { Draggable, Droppable } from '@dnd-kit/dom';
[0]   4 | import { useComputed, useOnValueChange, useConstant } from '@dnd-kit/react/hooks';
[0]
[0] https://nextjs.org/docs/messages/module-not-found

Here's the code in node_modules:

image
chunkerchunker commented 3 months ago

I ran into the same problem, but it looks like it's been fixed with the latest 0.0.4 release.