JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 1
  • Score
    100M100P100Q40507F
  • License ISC

Get german election polls.

Package Exports

  • german-election-polls
  • german-election-polls/lib/index.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (german-election-polls) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

German Election Polls

Usage

Installing

npm install german-election-polls

TypeScript Example

import polls from 'german-election-polls';

(async () => {
  await poll.shared.update();

  const query = poll.shared.select([
    Query.include([DataType.Surveys]),
    Query.Survey.Tasker.ID.isNot([4, 6]),
    Query.Survey.Release.isGreater(new Date('2021-11-21')),
    Query.Survey.Parliament.Shortcut.is(['Nordrhein-Westfalen (NRW)', 'Baden-Württemberg']),
    Query.Survey.Sort.byParticipants(Order.Asc),
    Query.Survey.Sort.allResults(Order.Desc),
  ]);
})();

JavaScript Example

import polls from 'german-election-polls';

(async () => {
  await poll.shared.update();

  const query = poll.shared.select([
    Query.include([DataType.Surveys]),
    Query.Survey.Tasker.ID.isNot([4, 6]),
    Query.Survey.Release.isGreater(new Date('2021-11-21')),
    Query.Survey.Parliament.Shortcut.is(['Nordrhein-Westfalen (NRW)', 'Baden-Württemberg']),
    Query.Survey.Sort.byParticipants(Order.Asc),
    Query.Survey.Sort.allResults(Order.Desc),
  ]);
})();

Where the data comes from

We are using the DAWUM API to collect all data.

Data from dawum.de (License: ODC-ODbL)
Daten von dawum.de (Lizenz: ODC-ODbL)