Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gruntjs/grunt-lib-contrib
Common functionality shared across grunt-contrib tasks.
https://github.com/gruntjs/grunt-lib-contrib
Last synced: about 2 months ago
JSON representation
Common functionality shared across grunt-contrib tasks.
- Host: GitHub
- URL: https://github.com/gruntjs/grunt-lib-contrib
- Owner: gruntjs
- License: mit
- Created: 2012-09-04T18:34:38.000Z (over 12 years ago)
- Default Branch: main
- Last Pushed: 2021-03-22T14:49:56.000Z (almost 4 years ago)
- Last Synced: 2024-08-08T17:16:18.363Z (5 months ago)
- Language: JavaScript
- Homepage: http://gruntjs.com/
- Size: 41 KB
- Stars: 12
- Watchers: 7
- Forks: 12
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG
- License: LICENSE-MIT
Awesome Lists containing this project
README
# grunt-lib-contrib [![Build Status](https://secure.travis-ci.org/gruntjs/grunt-lib-contrib.png?branch=master)](http://travis-ci.org/gruntjs/grunt-lib-contrib)
**DEPRECATED - DO NOT USE**
> Common functionality shared across grunt-contrib tasks.
### Helper Functions
#### stripPath(path, stripPath)
**Deprecated. Use [strip-path](https://github.com/sindresorhus/strip-path) instead.**
Strip a path from a path. Normalize both paths for best results.
#### minMaxInfo(min, max, report)
**Deprecated. Use [maxmin](https://github.com/sindresorhus/maxmin) instead.**
Helper for logging compressed, uncompressed and gzipped sizes of strings.
##### report
Choices: `false`, `'min'`, `'gzip'`
Default: `false`Either do not report anything, report only minification result, or report minification and gzip results.
**Important** Including `'gzip'` results can make this task 5-10x slower depending on the size of the file.
```js
var max = grunt.file.read('max.js');
var min = minify(max);
minMaxInfo(min, max, 'gzip');
```Would print:
```
Original: 495 bytes.
Minified: 396 bytes.
Gzipped: 36 bytes.
```#### getNamespaceDeclaration(ns)
**Deprecated. Use [nsdeclare](https://www.npmjs.org/package/nsdeclare) instead.**
This helper is used to build JS namespace declarations.
--
*Lib submitted by [Tyler Kellen](https://goingslowly.com/).*