nx-predictive-input
TypeScript icon, indicating that this package has built-in type declarations

1.0.2 • Public • Published

nx-predictive-input

This library was generated with Nx.

Description

Could not find any similar Angular component for this purpose, so I created my own. This is a standalone component which accepts @Input() predictions as a simple array of strings and works fine with ReactiveFormsModule.

Showcase

Example image

Install

Run npm install nx-predictive-input@latest to install this library.

Usage

Import component like this:

import { NxPredictiveInputComponent } from "nx-predictive-input";

In your component, please create array of countries like this:

@Component({...}) export class MyComponent { countries = ["Bosnia and Herzegovina"]; }

And use it in HTML like this:

<input-predictive [predictions]="countries"></input-predictive>

Running unit tests

Run nx test nx-predictive-input to execute the unit tests.

Package Sidebar

Install

npm i nx-predictive-input

Weekly Downloads

6

Version

1.0.2

License

none

Unpacked Size

41.4 kB

Total Files

11

Last publish

Collaborators

  • harespaha