From 1314a49f0575b843eae10bb6dcfd70b8cd53a32b Mon Sep 17 00:00:00 2001 From: Shahar Kazaz Date: Thu, 11 May 2023 12:58:03 +0300 Subject: [PATCH] =?UTF-8?q?chore:=20=F0=9F=A4=96=20update=20svgo=20to=20v3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 1 + svg-generator/package.json | 8 ++++++-- svg-generator/tsconfig.json | 7 ++++--- 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index 523034d..f075a00 100644 --- a/package.json +++ b/package.json @@ -6,6 +6,7 @@ "start": "ng serve", "test:generator": "npm run test --prefix svg-generator", "run:generator": "node svg-generator/index.js", + "build:generator": "npm run build --prefix svg-generator", "hooks:pre-commit": "node hooks/pre-commit.js && lint-staged", "commit": "git-cz", "build:lib": "ng build @ngneat/svg-icon --configuration production && cp -r README.md dist/ngneat/svg-icon", diff --git a/svg-generator/package.json b/svg-generator/package.json index 3cea7b1..eea0b93 100644 --- a/svg-generator/package.json +++ b/svg-generator/package.json @@ -1,6 +1,6 @@ { "name": "@ngneat/svg-generator", - "version": "6.0.0", + "version": "7.0.0", "description": "svg generator", "main": "generator.js", "bin": { @@ -11,7 +11,9 @@ }, "scripts": { "start": "tsc --watch", + "prebuild": "rm -rf dist", "build": "tsc", + "postbuild": "cp package.json dist", "test": "npm run build && jest ./index.spec.js" }, "keywords": [ @@ -21,6 +23,9 @@ ], "author": "Netanel Basal", "license": "MIT", + "peerDependencies": { + "svgo": ">=3.0.0" + }, "dependencies": { "camelcase": "6.2.0", "chokidar": "3.5.3", @@ -28,7 +33,6 @@ "fs-extra": "10.1.0", "glob": "8.0.3", "lodash.kebabcase": "4.1.1", - "svgo": "2.8.0", "typescript": "4.8.4", "commander": "9.4.1" }, diff --git a/svg-generator/tsconfig.json b/svg-generator/tsconfig.json index 11544fa..38f6c11 100644 --- a/svg-generator/tsconfig.json +++ b/svg-generator/tsconfig.json @@ -13,11 +13,11 @@ // "allowJs": true, /* Allow javascript files to be compiled. */ // "checkJs": true, /* Report errors in .js files. */ // "jsx": "preserve", /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */ - // "declaration": true, /* Generates corresponding '.d.ts' file. */ + "declaration": true, /* Generates corresponding '.d.ts' file. */ // "declarationMap": true, /* Generates a sourcemap for each corresponding '.d.ts' file. */ // "sourceMap": true, /* Generates corresponding '.map' file. */ // "outFile": "./", /* Concatenate and emit output to single file. */ - // "outDir": "./", /* Redirect output structure to the directory. */ + "outDir": "./dist", /* Redirect output structure to the directory. */ // "rootDir": "./", /* Specify the root directory of input files. Use to control the output directory structure with --outDir. */ // "composite": true, /* Enable project compilation */ // "tsBuildInfoFile": "./", /* Specify file to store incremental compilation information */ @@ -72,5 +72,6 @@ /* Skip type checking of declaration files. */ "forceConsistentCasingInFileNames": true /* Disallow inconsistently-cased references to the same file. */ - } + }, + "exclude": ["**/*.spec.ts", "node_modules"] }