# sws-input

> sws-input module to work in Angular 5 ### To install simply run npm install sws-input. **Also you need install** 1. npm i sws-label-directive *** After that you need import style to your style.css file for style label ``` @import "../node_modules/

Latest version **0.1.9** (published 2018-01-31) · MIT license · 0 weekly downloads

## Install

```sh
npm install sws-input
pnpm add sws-input
yarn add sws-input
bun add sws-input
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.9 |
| Published | 2018-01-31 |
| First published | 2018-01-15 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 2 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Alexander |
| Maintainers | sws-com |
| Keywords | Angular, Angular5, Angular 5, Angular5 input |

## Links

- npm: https://www.npmjs.com/package/sws-input
- npm.io page: https://npm.io/package/sws-input

## Dependencies (2)

- [sws-label-directive](https://npm.io/package/sws-label-directive.md) ~0.1.1
- [sws-form-field-errors](https://npm.io/package/sws-form-field-errors.md) ^0.1.0

## Recent versions

- 0.1.9 (latest) — 2018-01-31
- 0.1.8 — 2018-01-30
- 0.1.7 — 2018-01-30
- 0.1.6 — 2018-01-30
- 0.1.5 — 2018-01-30
- 0.1.4 — 2018-01-30
- 0.1.3 — 2018-01-19
- 0.1.2 — 2018-01-16
- 0.1.1 — 2018-01-16
- 0.1.0 — 2018-01-15

## README

# sws-input
sws-input module to work in Angular 5
### To install simply run
npm install sws-input.
**Also you need install**
1. npm i sws-label-directive
***
After that you need import style to your style.css file for style label
```
@import "../node_modules/sws-label-directive/label.css";
```
To use it in your Angular 5 app import the module.
import {SwsInputModule} from 'sws-input';
```
import {SwsInputModule} from 'sws-input';
...
@NgModule({
imports:[
SwsInputModule
],
})  
``` 
In your components in html template input 
```
<sws-input></sws-input>
```
**Important**
Also you need sent to sws-datepicker parameter as formControl
```
<sws-input [control]="form.controls['name']"></sws-input>
```

If may sent any parameters 'label, id, maxLength' or input any errors. Example:
```
<sws-input [control]="form.controls['name']" [label]="'Your name'" [maxLength]="10" [id]="'name'">
<span *ngIf="form.controls['name'].hasError('required')">error</span>
</sws-input>
```

---
_Source: https://npm.io/package/sws-input · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
