Questions tagged [craco]

Craco stands for Create React App Configuration Overrides - an easy and comprehensible configuration layer for create-react-app.

Craco is a mechanism for overriding aspects the standard Create React App configuration without forcing the developer to eject their app from CRA.

It allows you add a single craco.config.js file at the root of your application and thus customise your eslint, babel, postcss, and webpack configurations.

190 questions
0
votes
1 answer

Netlify deploy failing with Create React App / CRACO / yarn build:

I have built a simple app using Create React App, Tailwind and CRACO (https://github.com/gsoft-inc/craco), following the instructions here: https://tailwindcss.com/docs/guides/create-react-app The app also uses Typescript if thats relevant. However…
awnine
  • 131
  • 1
  • 13
0
votes
1 answer

Cannot read property .match of undefined (AWS Amplify Build Error)

I'm trying to deploy a React/Typescript app using Amazon's AWS Amplify but the build keeps failing and returning the error containing: "Cannot read property .match of undefined" I've read so many threads but everyone keeps suggesting the same stupid…
0
votes
0 answers

Why craco build fails?

I'm building my app with Craco and running craco build gives me this output: Creating an optimized production build... Failed to compile. Error: html-webpack-plugin could not minify the generated output. In production mode the html minifcation is…
Mark
  • 1,385
  • 3
  • 16
  • 29
0
votes
1 answer

Using 'craco' with 'less' and 'postcss'

I use craco to customize configuration. I want to use less module and postcss and some postcss plugins,but I have encountered many problems craco.config.js style: { postcss: { plugins: [ require('postcss-px-to-viewport')({ …
H.ont
  • 1
  • 1
  • 1
0
votes
1 answer

Is it possible to change stylesheet URI on production build (webpack / craco)?

when building react app for production build, I would want to change specific stylesheet link from "http://127.0.0.1:4000/custom/styles.css" to "/custom/styles.css" Is it possible to do that with webpack / craco ? If it's possible how can I achieve…
LuckyLuke
  • 1,028
  • 2
  • 14
  • 28
0
votes
1 answer

SyntaxError: Unexpected token < at ScriptTransformer._transformAndBuildScript (../../node_modules/jest-runtime/build/script_transformer.js

I am using CRA (react-scripts v2.1.7) with craco v3.5 in a monorepo. I am using jest with testing-library/react. Whenever I run my tests, I get the error as Details: …
Shivangi Khandelwal
  • 113
  • 1
  • 1
  • 12
0
votes
1 answer

Monorepo and problem with building packages

I try to build modular React application using monorepository (workspaces) - in root folder I have package.json: { "private": true, "workspaces": ["shared/react-components", "client/react-app"], "scripts": { "start": "yarn --cwd…
Garion S.
  • 119
  • 2
  • 9
0
votes
1 answer

Antd dark theme is overriding my own css. How to solve it?

I installed antd to the CRA project. And I made some of my own classes and override default andt css. Then I wanted andt table component but with dark theme. So installed dark theme using webpack but failed. So I tried with craco and worked…
ericobi
  • 529
  • 3
  • 11
0
votes
2 answers

craco causes yarn build to fail due to "Cannot find module 'environment'. TS2307"

I installed and configured craco following the official README and the medium article "My Awesome Custom React Environment Variables Setup". I did sudo yarn global upgrade create-react-app create-react-app craco-getting-started yarn add…
Kalle Richter
  • 8,008
  • 26
  • 77
  • 177
-1
votes
1 answer

Error while building React App on Ubuntu 20.04.3 LTS using Craco

When I am trying to deploy my React App (built with npx create-react-app ./) on Ubuntu 20.04.3 LTS I get the following error: (node:3373) UnhandledPromiseRejectionWarning:…
Andrei Bunea
  • 111
  • 10
1 2 3
12
13