@apolitical/common-helpers-events

Node.js module to format events

Usage no npm install needed!

<script type="module">
  import apoliticalCommonHelpersEvents from 'https://cdn.skypack.dev/@apolitical/common-helpers-events';
</script>

README

Common Helpers- Events

Node.js module to expose functionality to format event date into how it should be displayed on the frontend.

Current function

  • formatEvents
    • Takes an array of events, groups them into whether they are in the future or past. It returns an object with futureEvents and pastEvents