@polyrithm/click-prevent

This library was generated with Nx.

Usage no npm install needed!

<script type="module">
  import polyrithmClickPrevent from 'https://cdn.skypack.dev/@polyrithm/click-prevent';
</script>

README

click-prevent

This library was generated with Nx.

Running unit tests

Run nx test click-prevent to execute the unit tests.

click-prevent

A click event with stopPropagation;

Install


$ npm install @polyrithm/click-prevent --save

or

yarn add @polyrithm/click-prevent

Usage


// app.module or any module

import {ClickPreventModule} from '@polyrithm/click-prevent';

@NgModule({
  ...
  imports: [ClickPreventModule]
  ...
})

class MyModule {

}

// Example Component

<button class="btn" (click.prevent)="onClick($event, data)">
   Click me
</button>