Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

197
Views
overwrite tsconfig.json from the package

I have React app install a third-party package using Typsecript, running my react app current get an error message like below:

Class constructor Name cannot be invoked without 'new'

I did try to decare a variable with new for that, does not work.

so I dig deeper turn out the third package we use to extend of component have this setting in the tsconfig.json

{
    "compilerOptions": {
        "target": "es5",
    }
}

Is any way I can overwrite this setting in my current react app since I don't can't change that package?

Thanks!

about 4 years ago · Santiago Trujillo
1 answers
Answer question

0

I do not believe that this is possible, since if you did not create the app with the typescript template react-scripts will not use typescript. You have two options here: use cra to make a new app using the --template typescript option and copy your code, or run npm run eject or yarn eject to expose the configuration files for webpack and add the loader yourself, although this is risky because it risks messing up the project configurations.

about 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!