Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/omnedia/ngx-typewriter

A simple component library to animate text.
https://github.com/omnedia/ngx-typewriter

Last synced: 14 days ago
JSON representation

A simple component library to animate text.

Awesome Lists containing this project

README

        

# Ngx Typewriter Component

`@omnedia/ngx-typewriter` is a lightweight and easy-to-use angular library for creating typewriter effects in your web applications.

It uses RxJS to manage the typewriting effect, ensuring smooth and customizable animations.

## Installation

You can install the library via npm:

```bash
npm install @omnedia/ngx-typewriter
```

## Usage

First, import the Component class from the library:

```typescript
import { NgxTypewriterComponent } from '@omnedia/ngx-typewriter';

@Component({
...
imports: [
...
NgxTypewriterComponent,
],
...
})
```

Then, create an DOM Element of the TypeWriter:

```typescript
words: string[] = ['Im', 'typed', 'one', 'after', 'another'];
```

```html

```

## API

```html

```

Starts the typewriter effect.

- `words`: An array of strings to be typed.
- `disableLoop`: (optional): If set to true, the last word in the words array will stay.
- `writeSpeed` (optional): The speed of typing each character in milliseconds. Default is 40.
- `deleteDelay` (optional): The delay before starting to delete the typed word in milliseconds. Default is 3500.
- `writeDelay` (optional): The delay before starting to type the next word after deleting the current word in milliseconds. Default is 50.
- `styleClass` (optional): Add a class to the `

` Tag.

## Contributing

Contributions are welcome! Please feel free to submit a pull request or open an issue on GitHub.

## License

This project is licensed under the MIT License - see the LICENSE file for details.

## Acknowledgments

- RxJS for providing powerful reactive programming tools.
- All the contributors who have helped in improving this project.

## Contact

For any questions or suggestions, please open an issue or reach out to me at [[email protected]](mailto:[email protected]).