mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2025-10-16 12:05:41 +00:00
Add gulp-strip-comments type
This commit is contained in:
parent
b3cad84aa3
commit
b09582f973
12
types/gulp-strip-comments/gulp-strip-comments-tests.ts
Normal file
12
types/gulp-strip-comments/gulp-strip-comments-tests.ts
Normal file
@ -0,0 +1,12 @@
|
||||
import * as gulp from 'gulp';
|
||||
import * as stripComments from 'gulp-strip-comments';
|
||||
|
||||
gulp.task('default', () => {
|
||||
return gulp.src('src/app.js')
|
||||
.pipe(stripComments({
|
||||
safe: true,
|
||||
}))
|
||||
.pipe(stripComments.html())
|
||||
.pipe(stripComments.text())
|
||||
.pipe(gulp.dest('dist'));
|
||||
});
|
||||
26
types/gulp-strip-comments/index.d.ts
vendored
Normal file
26
types/gulp-strip-comments/index.d.ts
vendored
Normal file
@ -0,0 +1,26 @@
|
||||
// Type definitions for gulp-strip-comments 2.5
|
||||
// Project: https://github.com/RnbWd/gulp-strip-comments
|
||||
// Definitions by: Aqours <https://github.com/Aqours>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
/// <reference types="node" />
|
||||
|
||||
declare namespace stripComments {
|
||||
interface StripOptions {
|
||||
safe?: boolean;
|
||||
ignore?: RegExp | RegExp[];
|
||||
space?: boolean;
|
||||
trim?: boolean;
|
||||
}
|
||||
|
||||
interface Strip {
|
||||
(options?: StripOptions): NodeJS.ReadWriteStream;
|
||||
text(options?: StripOptions): NodeJS.ReadWriteStream;
|
||||
html(options?: StripOptions): NodeJS.ReadWriteStream;
|
||||
getEOL(): string;
|
||||
}
|
||||
}
|
||||
|
||||
declare const strip: stripComments.Strip;
|
||||
|
||||
export = strip;
|
||||
23
types/gulp-strip-comments/tsconfig.json
Normal file
23
types/gulp-strip-comments/tsconfig.json
Normal file
@ -0,0 +1,23 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"strictFunctionTypes": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": [
|
||||
"index.d.ts",
|
||||
"gulp-strip-comments-tests.ts"
|
||||
]
|
||||
}
|
||||
1
types/gulp-strip-comments/tslint.json
Normal file
1
types/gulp-strip-comments/tslint.json
Normal file
@ -0,0 +1 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
Loading…
Reference in New Issue
Block a user