1
0
mirror of https://github.com/svg/svgo.git synced 2025-07-31 07:44:22 +03:00
Commit Graph

18 Commits

Author SHA1 Message Date
c3695ae533 Migrate to jest (#1520)
Mocha doesn't have a lot of features provided by jest.
There is a great assertion library out of the box.
And the most cool feature is inline snapshots.
Mocha also hides errors which makes debugging a nightmare sometimes.
2021-08-12 18:06:10 +03:00
66bb0fb2ad Commit fixtures 2021-03-03 12:32:43 +03:00
a99cc08e4f Format tests with prettier (#1380)
Will format the code with prettier in a few commits.
2021-02-27 23:17:47 +03:00
df14f37c48 test/coa/_index.js: Fix regex (#1347)
`.` means any character but we want to match the literal `.`
2021-02-20 17:05:04 +03:00
330e78b479 Fix reporting of config errors (#1342)
Errors are swallowed while resolving.
2021-02-19 12:11:35 +03:00
7a4217db4b Replace fs-extra with del 2021-02-16 19:51:05 +03:00
2236d0fd60 Upgrade mocha and refactor cli tests with async/await 2021-02-16 19:45:25 +03:00
a6f14018ee Implement loadConfig utility (#1328)
Ref https://github.com/svg/svgo/issues/1327

Config file now can only be js. `svgo.config.js` is searched by default.
Otherwise any js module specified in `--config` cli flag.

Config loader is exposed in entry point as `loadConfig(configFile, cwd)`.
2021-02-16 19:11:13 +03:00
d273b26605 Provide es module bundle for browser (#1326)
The was a lot of requests to provide browser compatible module. In this
diff I added `svgo/dist/svgo.browser.js` bundle and tested it with
playwright.
2021-02-16 19:11:01 +03:00
8899f682b8 Remove coverage imports from tests 2021-02-15 02:41:28 +03:00
a1c1b7f443 Remove json string as --config value support 2021-02-14 17:44:18 +03:00
57aecc50ac Replace coa with commander (#1293)
Ref https://packagephobia.com/result?p=coa https://packagephobia.com/result?p=commander

Coa was not updated for 2 years already and has outdated dependencies.

In this diff I replaced it with commander which has simpler syntax, none
dependencies and require arguments out of the box. Also array argument
is set syntactically which means more user-friendly "help".
2021-02-13 22:23:19 +03:00
258fecfa6b Remove spaces after ‘arcto’ path command flags 2019-07-13 16:18:08 +03:00
d911f0f4c7 Option recursive (#837)
Add -recursive (-r) option
2019-02-24 19:54:59 +03:00
1eb39cd24a Fix optimized size comparision in tests 2017-09-10 21:56:47 +03:00
e3ddf1d96a Process *.svg files 2017-09-09 23:56:07 +03:00
645a83fa6a Cleanup coa tests 2017-09-05 15:52:38 +03:00
b96982ffac add tests for coa 2017-08-24 01:31:57 +03:00