Bootcamp
Search…
6.ICE.1: NPM Webpack

Introduction

Create a browser app with date inputs with Webpack.

Base

  1. 1.
    Create a new NPM project and add the appropriate folders and files described in Module 6.1.2: Webpack NPM.
  2. 2.
    Install moment as a dependency of the project.
  3. 3.
    When the page loads, create a date input.
  4. 4.
    When the user enters a date into the date input, show a Moment formatted date in an h2 element. The date should have the format: January 12th, 1998.

Comfortable

Add the Copy to Clipboard library. When the user clicks a button, copy a moment formatted short date to the clipboard. The date should have the format: 1/12/98.

More Comfortable

Use the Moment Timezone library to show the names and times at all other timezones in the world, in ascending order of difference from the user's current zone.