risen228 / craco-alias

A craco plugin for automatic aliases generation for Webpack and Jest
MIT License
109 stars 11 forks source link

Cannot parse tsconfig.extend.json #15

Closed tamb closed 4 years ago

tamb commented 4 years ago

Follow these steps:

https://github.com/risenforces/craco-alias#ran-into-a-problem

Then describe your problem and paste the plugin output.

This seems like a completely valid tsconfig.extend.json to me

{
    "compilerOptions": {
      // baseUrl is optional for plugin, but some IDEs require it
      "baseUrl": "src",
      "paths": {
        "@components": ["./src/components"],
        "@entities": ["./src/entities"],
        "@factories": ["./src/factories"],
        "@gifs": ["./src/gifs/v5"],
        "@imgs": ["./src/imgs"],
        "@interfaces": ["./src/interfaces"],
        "@root": ["./src"],
        "@store": ["./src/store"],
        "@utils": ["./src/utils"],
        "@missions": ["./src/missions"],
      }
    }
  }
> craco start

Cannot parse tsconfig.extend.json

Please read plugin documentation: https://github.com/risenforces/craco-alias
arutkowski00 commented 4 years ago

You have a trailing comma here which JSON specification does not allow:

"@missions": ["./src/missions"],
                               ^

That's why it isn't able to parse it.