Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
duiba-tiny-image-node
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
劳工
duiba-tiny-image-node
Commits
d4d8b524
Commit
d4d8b524
authored
Nov 05, 2021
by
rockyl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复
parent
ec1114a9
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
3 deletions
+3
-3
api.js
dist/api.js
+1
-1
api.js.map
dist/api.js.map
+1
-1
api.ts
src/api.ts
+1
-1
No files found.
dist/api.js
View file @
d4d8b524
...
...
@@ -5,7 +5,7 @@
Object
.
defineProperty
(
exports
,
"__esModule"
,
{
value
:
true
});
const
logger_1
=
require
(
"./logger"
);
const
imagemin
=
require
(
"imagemin"
);
const
imageminJpegtran
=
require
(
"imagemin-
mozjpeg
"
);
const
imageminJpegtran
=
require
(
"imagemin-
jpegtran
"
);
const
imageminPngquant
=
require
(
"imagemin-pngquant2"
);
const
node_tinify_1
=
require
(
"node-tinify"
);
const
acceptTypes
=
[
'image/png'
,
'image/jpeg'
];
...
...
dist/api.js.map
View file @
d4d8b524
{"version":3,"file":"api.js","sourceRoot":"","sources":["../src/api.ts"],"names":[],"mappings":";AAAA;;GAEG;;AAEH,qCAA6B;AAE7B,MAAM,QAAQ,GAAG,OAAO,CAAC,UAAU,CAAC,CAAA;AACpC,MAAM,gBAAgB,GAAG,OAAO,CAAC,kBAAkB,CAAC,CAAA;AACpD,MAAM,gBAAgB,GAAG,OAAO,CAAC,oBAAoB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AAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE;YACpC,IAAI;gBACH,MAAM,MAAM,GAAG,MAAM,sBAAQ,CAAC,IAAI,CAAC,IAAI,EAAE,EAAC,UAAU,EAAE,QAAQ,EAAC,CAAC,CAAA;gBAChE,GAAG,CAAC,OAAO,CAAC,MAAM,EAAE;oBACnB,cAAc,EAAE,IAAI,CAAC,IAAI;iBACzB,CAAC,CAAA;aACF;YAAC,OAAO,CAAC,EAAE;gBACX,gBAAM,CAAC,KAAK,CAAC,UAAU,EAAE,iBAAiB,EAAE,CAAC,CAAC,OAAO,CAAC,CAAA;gBACtD,GAAG,CAAC,IAAI,CAAC;oBACR,IAAI,EAAE,CAAC;oBACP,GAAG,EAAE,iBAAiB;iBACtB,CAAC,CAAA;aACF;SACD;aAAM;YACN,gBAAM,CAAC,KAAK,CAAC,UAAU,EAAE,YAAY,CAAC,CAAA;YACtC,GAAG,CAAC,IAAI,CAAC;gBACR,IAAI,EAAE,CAAC;gBACP,GAAG,EAAE,YAAY;aACjB,CAAC,CAAA;SACF;KACD;SAAM;QACN,GAAG,CAAC,IAAI,CAAC;YACR,IAAI,EAAE,CAAC;YACP,GAAG,EAAE,iBAAiB;SACtB,CAAC,CAAA;KACF;IACD,OAAO,IAAI,EAAE,CAAA;AACd,CAAC"}
\ No newline at end of file
src/api.ts
View file @
d4d8b524
...
...
@@ -5,7 +5,7 @@
import
logger
from
"./logger"
const
imagemin
=
require
(
"imagemin"
)
const
imageminJpegtran
=
require
(
"imagemin-
mozjpeg
"
)
const
imageminJpegtran
=
require
(
"imagemin-
jpegtran
"
)
const
imageminPngquant
=
require
(
"imagemin-pngquant2"
)
import
{
compress
}
from
'node-tinify'
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment