New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

angular-pipes

Package Overview
Dependencies
Maintainers
1
Versions
78
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

angular-pipes

Angular 2 pipes library

  • 1.0.5
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
4.2K
decreased by-19.78%
Maintainers
1
Weekly downloads
 
Created
Source

NPM Version

angular-pipes

angular-pipes is a pipes library for angular 2. The project is hosted as angular-pipes on npm.

WARNING: Work in progress.

Contribute

Feel free to contribute in any way.

Pipes

Collections (array)

  • empty
  • head
  • initial
  • join
  • last
  • tail
  • uniq
  • without

Boolean

  • greater
  • greaterOrEqual
  • less
  • lessOrEqual
  • equal
  • notEqual
  • identical
  • notIdentical
  • null
  • undefined
  • number
  • string
  • function
  • array
  • object
  • defined

Math

  • bytes
  • ceil
  • floor
  • round
  • min
  • max
  • mean
  • sum

String

  • leftpad
  • rightpad
  • pad
  • trim
  • split
  • replace (not tested)
  • match (not tested)
  • test (not tested)

Install

npm

npm install angular-pipes --save

jspm

jspm install angular-pipes=npm:angular-pipes

How to use

For now, it only support TypeScript.

import { NG2_PIPES } from 'angular-pipes';

You can also import only one category and a string pipe.

import { NG2_BOOLEAN_PIPES, SplitPipe } from 'angular-pipes';

But this will import all the files, you can do better by importing just the boolean files.

import { NG2_BOOLEAN_PIPES } from 'angular-pipes/pipes/boolean';
import { SplitPipe } from 'angular-pipes/pipes/string';

Same thing for the other categories.

And if you want to only include one file:

import { HeadPipe } from 'angular-pipes/pipes/src/array/head.pipe';

The boolean pipes are only in two files, the types are in types.pipe.ts and the conditions are in conditions.pipe.ts

If you only use one or two pipes, it's better to include only those two files. It will be lighter. There is no bundle available, this project let you bundle as you wish.

Documentation - TODO

Tests

npm install
npm run lite

And navigate to /unit-tests.html. It may take some time for the files to transpile.

TODO: Karma

Contributors

  • Florian Knop

FAQs

Package last updated on 04 Apr 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc