Skip to content

React-scripts 5 build fails on Netlify - "validate is not a function" #17208

Description

@topapippo

Titolo: React-scripts 5 build fails on Netlify - "validate is not a function"
Messaggio:
Hi, I need help deploying a React app on Netlify.
Repository: https://github.com/topapippo/MBHS-GESTIONALE-EMERGENT
Error:
TypeError: validate is not a function
at new TerserPlugin (terser-webpack-plugin/dist/index.js:180:5)
at react-scripts/config/webpack.config.js:262:9
Node.js v18.20.8
Setup:

react-scripts: 5.0.1
Node: 18
Build command: npm install --legacy-peer-deps && npm run build
Base directory: frontend

What I tried:

Node 16, 18, 20
overrides for ajv, schema-utils, ajv-keywords
--legacy-peer-deps

Nothing works. How can I fix this?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions