Accordion exercise done with ES6-Webpack-JsonServer
You need to have install it, as global, the next libraries:
$ npm install -g json-server # for mock API calls
You will need to execute webpack and json-server both at same time (*).
In the 1st terminal window, run the json-server command:
json-server mocks\userData.json
In the 2nd terminal window, run webpack-dev-server with hot reloading:
npm run start
or
yarn start
(*) Anyway, if the API throw an error, a mock data will be used to display results
You will need to launch the build process and deploy it the results located in the "dist" folder.
yarn build
$ npm run build # generates bundler
$ npm run start # starts local server with hot reloading