Skip to content
This repository has been archived by the owner on Jun 17, 2023. It is now read-only.

emrergin/prudencetemperance

Repository files navigation

Prudence and Temperance Testing

Web based experimentation for the concepts of Prudence and Temperance. Also will include a treatment for Risk Aversion.

Joint project with Mehmet Yiğit Gürdal and Tolga Umut Kuzubaş.

The front end is using Vue3 while the backend uses MongoDB and Node.js. The backend code will not be hosted in this repo.

Details

Some introductory readings for the concepts.

Usage

  • npm install to install necessary packages.
  • npm run serve to have a file that is served by a local server.
  • npm run build to build a file that works without a server.
  • Backend code is not included, so you need to build an API for yourself.

Sources

What I learned

  • findIndex() returns -1 if no match is found.
  • closest() is not about closeness in terms of pixel location, it checks only the parents.
  • For sequential animations, default browser behaviour of removing filling animations should be evaded by persist().
  • For nodes removed with v-if condition, any dynamic class assignments will not work for child elements, even if they are not children of the original parent anymore.
  • Accurately modifying data with event listeners is best done with passing the relevant data as an object property.
  • For multiple components referencing the same functions, Composition API is a better fit.
  • There is no universally consistent way to send data if the user just prefers to exit.
  • An image is rendered inline by default, thus have extra space below it to account for descenders.
  • Persisting animations and Vue components don't behave well together.

Thanks