0.0.8-ng5 • Published 6 years ago

ngx-poll v0.0.8-ng5

Weekly downloads
2
License
MIT
Repository
github
Last release
6 years ago

Table of contents

  1. Installation instructions

  2. Documentation

    @Inputs

    @Outputs

  3. Example

    Development server

  4. License

Installation instructions

Install ngx-poll from npm:

npm install ngx-poll --save

Add PollModule to NgModule imports:

import { PollModule } from 'ngx-poll';

@NgModule({
  // ...
  imports: [
      PollModule,
      // ...
  ]
  // ...
})

Add component to your page:

<ngx-poll [questions]="questions"></ngx-poll>

You will need ngx-bootstrap configuration:

  • Into your index.html
<!--- index.html -->
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" rel="stylesheet">
  • Into your app.component.ts
import { setTheme } from 'ngx-bootstrap/utils';

@Component({...})
export class AppComponent {
  constructor() {
    setTheme('bs4');
    // ...
  }
}

Documentation

@Inputs

NameTypeDefault value
primaryButtonTitlestring'Yes'
primaryButtonValueanytrue
secondaryButtonTitlestring'No'
secondaryButtonValueanyfalse
submitButtonTitlestring'Send'
submitButtonEnabledbooleanfalse
dataLoadedbooleantrue
questions{ text: string, value: any }undefined

@Outputs

NameTypeEmited
sendvoidWhen submit button clicked

Example

The example project was generated with Angular CLI version 6.1.5.

Development server

Run ng serve for a dev server. Navigate to http://localhost:4200/. The app will automatically reload if you change any of the source files.

License

MIT

0.0.8-ng5

6 years ago

0.0.7-ng5

6 years ago

0.0.6-ng5

6 years ago

0.0.5-ng5

6 years ago

0.0.4-ng5

6 years ago

0.0.4

6 years ago

0.0.3

6 years ago

0.0.2

6 years ago

0.0.1

6 years ago