0

I had the 'svg-to-ts' package installed and it worked ok and created ts files normaly.
However, when I started to upgrade my application to angular 15 from 10, the package stopped working. When I return the version of the package to the previous one, i.e. 5, it works normally,
but when I raise it to 8 or 10, which is the latest version, I get an error:

'svg-to-ts' is not recognized as an internal or external command,
operable program or batch file.

The script object and configuration in my package.json look like this:

"scripts": {
    "ng": "ng",
    "start": "ng serve",
    "build": "ng build",
    "test": "ng test",
    "lint": "ng lint",
    "e2e": "ng e2e",
    "generate-icons": "svg-to-ts"
  }

"svg-to-ts": {
    "generateType": "false",
    "delimiter": "KEBAB",
    "conversionType": "files",
    "iconsFolderName": "icons",
    "prefix": "app",
    "srcFiles": [
      "./src/assets/images/Svg/*.svg"
    ],
    "outputDirectory": "./src/assets/images/Svg",
    "svgoConfig": {
      "plugins": [
        {
          "removeDimensions": true
        },
        {
          "cleanupAttrs": true
        }
      ]
    }
  }

If anyone has a solution or similar experiences I would appreciate it. Thank you.

neca
  • 119
  • 1
  • 10

0 Answers0