Skip to content

LESS 4.6.2 causing build error #4423

@isgeoffrey

Description

@isgeoffrey

To reproduce:
npm i with LESS set to ^4.5.1 or 4.6.2
running build with webpack

Current behavior:
webpack unable to build frontend applicaiton due to the following error
Module not found: Error: Can't resolve 'module' in 'C:\Users\xxx\git\xxx\node_modules\less\lib\less-node'

Expected behavior:
webpack builds normally

Environment information:

  • less version: 4.6.2
  • nodejs version: v24.0.0
  • operating system: windows & linux debian (when building in server)
  • webpack: 5.64.6

Able to resolve when locking LESS to 4.5.1 in package.json

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions