Giter Site home page Giter Site logo

Comments (10)

sebmaz93 avatar sebmaz93 commented on July 20, 2024 8

@VishnuJin upgrading to node v21.1.0 fixed the issue for me

from dart-sass.

euaaaio avatar euaaaio commented on July 20, 2024 4

Yeah. That's why I mentioned them here.
It scares me more that they haven't released a fix in 5 days.

from dart-sass.

gajus avatar gajus commented on July 20, 2024 4

Same here. Vite fails with:

  [WebServer] Preprocessor dependency "sass" failed to load:
  Cannot read properties of undefined (reading 'indexOf')
  [WebServer] Preprocessor dependency "sass" failed to load:
  Cannot read properties of undefined (reading 'pop')
  [WebServer] 1:18:33 PM [vite] Internal server error: Preprocessor dependency "sass" failed to load:
#13 76.70 @contra/slate:build: [vite:css] Preprocessor dependency "sass" failed to load:
#13 76.70 @contra/slate:build: Cannot read properties of undefined (reading 'indexOf')
#13 76.70 @contra/slate:build: file: /srv/packages/slate/src/editor/components/Key/Key.module.scss?used
#13 76.70 @contra/slate:build: error during build:
#13 76.70 @contra/slate:build: TypeError: Cannot read properties of undefined (reading 'indexOf')
#13 76.70 @contra/slate:build:     at /srv/node_modules/.pnpm/[email protected]/node_modules/sass/sass.dart.js:116798:12

Pasting in the error so Vite folks discover the thread when Google-ing it.

from dart-sass.

nex3 avatar nex3 commented on July 20, 2024 2

Since this seems to be fixed in Node 21.1, I'm closing it out.

from dart-sass.

euaaaio avatar euaaaio commented on July 20, 2024 1

Seems to be related to dart-lang/sdk#53784

from dart-sass.

DawidJanczak avatar DawidJanczak commented on July 20, 2024 1

I was thinking about that, but all occurrences of that other error mention indexOf and there's no references to navigator in this code. But still could be that, I'll definitely re-test it when that fix is in :)

from dart-sass.

sannajammeh avatar sannajammeh commented on July 20, 2024 1

facing the same with Vite, any workarounds other than downgrade of nodejs?

Unfortunately its the only work around

from dart-sass.

nex3 avatar nex3 commented on July 20, 2024

Can someone provide a minimal reproduction for this? I've tried manually editing sass.dart.js to work around dart-lang/sdk#53784, but when I do so Dart Sass loads and runs fine in Node 21 for me (via both ESM and CJS loads). It seems to work through WebPack as well.

from dart-sass.

sannajammeh avatar sannajammeh commented on July 20, 2024

Getting this as well in the latest Next.js 13.5.6 pages directory.

stack:

../../node_modules/.pnpm/[email protected][email protected][email protected][email protected]/node_modules/next/dist/build/webpack/loaders/css-loader/src/index.js??ruleSet[1].rules[7].oneOf[9].use[1]!../../node_modules/.pnpm/[email protected][email protected][email protected][email protected]/node_modules/next/dist/build/webpack/loaders/postcss-loader/src/index.js??ruleSet[1].rules[7].oneOf[9].use[2]!../../node_modules/.pnpm/[email protected][email protected][email protected][email protected]/node_modules/next/dist/build/webpack/loaders/resolve-url-loader/index.js??ruleSet[1].rules[7].oneOf[9].use[3]!../../node_modules/.pnpm/[email protected][email protected][email protected][email protected]/node_modules/next/dist/compiled/sass-loader/cjs.js??ruleSet[1].rules[7].oneOf[9].use[4]!./components/ui/ScrollArea.module.scss
./components/ui/ScrollArea.module.scss
./components/ui/ScrollArea.tsx

dart-lang/sdk@8fdf766

Appears its already fixed on dart-sass end

from dart-sass.

VishnuJin avatar VishnuJin commented on July 20, 2024

facing the same with Vite, any workarounds other than downgrade of nodejs?

from dart-sass.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.