Issues with Animations in Animate.css

Seeking to achieve fluid transitions using Vue.js and Animate.css, encountering issues with certain animations not functioning as expected!

Successfully implementing animations such as: bounceIn, bounceOut, and hinge.

Experimenting with this on codepen.io, also attempted locally with identical results.

Below is the element code undergoing animation:

/* ... */
<transition
  name="custom-transition"
  mode="out-in"
  :enter-active-class="'animate_animated ' + enterClass"
  :leave-active-class="'animate_animated ' + leaveClass"
>
  <h1 v-if="show" :key="value">
    {{ value }}
  </h1>
</transition>
/* ... */

Values for enterClass and leaveClass are derived from the following:

// ...
data: {
  show: true,
  enterClass: 'animate__bounceIn',
  enterAnimations: [
    'animate__backInDown',
    'animate__bounceIn',
    'animate__fadeIn',
    'animate__lightSpeedInRight',
    'animate__rotateIn',
    'animate__jackInTheBox',
    'animate__rollIn',
    'animate__zoomIn',
    'animate__slideInDown',
  ],
  leaveClass: 'animate__bounceOut',
  leaveAnimations: [
    'animate__backOutDown',
    'animate__bounceOut',
    'animate__fadeOut',
    'animate__lightSpeedOutLeft',
    'animate__rotateOut',
    'animate__hinge',
    'animate__rollOut',
    'animate__zoomOut',
    'animate__slideOutDown',
  ],
  value: 'Hi!',
}
// ...

Code on codepen.io

Answer №1

Oops, I made a silly mistake by forgetting to include the second underscore in the class name animate__animated

<transition
  name="custom-transition"
  mode="out-in"
  :enter-active-class="'animate__animated ' + enterClass"
  :leave-active-class="'animate__animated ' + leaveClass"
>
  /*...*/
</transition>

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

The filename is similar to the one already present, the only difference being the letter casing. Vetur(1149)

My folder structure and code are all in order. However, after renaming my folder once, Vetur keeps showing me this annoying message. I have attempted the following solutions: Deleting the repository entirely and committing a new Git Reinstalling Vetur R ...

How can I fetch data from SQL using JavaScript based on a specific value in PHP?

My application is built using the Yii2 framework. Within my application, there is a view.php file that consists of an element and a button. The element, <div id="userId">, contains the user's login ID, and I aim to use the button to re ...

Send binary information using Prototype Ajax request

Currently, I am utilizing Prototype to send a POST request, and within the postdata are numerous fields. One of these fields contains binary data from a file, such as an Excel spreadsheet chosen by the user for upload. To retrieve the contents of the file ...

The initial loading of jQuery DataTables shows duplicate entries

Expanding on my query from the previous day: jQuery AJAX call function on timeout Following the guidance provided in the response from yesterday's post, the table successfully reloads without requiring a full page refresh every 30 seconds. However, ...

Using Angular JS services and controllers in separate files may result in errors

Within my angularjs project, I manage the following files: /index.html <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=no, width=device-wid ...

Utilizing FontAwsome Icons within a CSS2DObject using VueJS

As an aspiring coder, I am determined to display a FontAwsome User Icon similar to the example here within a VueJS component. I have diligently attempted to replicate the same example showcased in this codesandbox, exploring the two approaches recommended ...

Show a message popup or view based on the validation of the model

Picture an online store with multiple steps to complete during the checkout process. Whenever the customer clicks the 'next' button, it triggers the corresponding 'Action' method. This method includes a validation check to ensure that t ...

Is the strange z-index behavior causing issues with mouse interactions a bug or a standard occurrence?

Whenever I attempt to adjust the z-index on my webpage to rearrange the layering of overlapping divs, I always encounter an issue where the lower div becomes unresponsive to mouse events. Currently, my setup includes: <div class="leftcolumn"> <d ...

Discovering the magic of Vue SCRIPT SETUP

I have successfully implemented the simple-vue-camera library and it works well, but I would like to utilize it with script setup. However, I am unable to access the snapshot method of the camera... The issue seems to be in the 'const cameraComponent ...

Importing named exports dynamically in Next.js

Currently, I am in the process of learning Next.js and I want to utilize a function called getItem from the package found at https://www.npmjs.com/package/encrypt-storage In my attempt to do so using the code snippet below, I encountered an error stating ...

Using $stateParams injection for unit testing Angular applications with Karma

Here is the starting point for the controller code: angular .module('hc.hotelContent') .controller('NameLocationController', nameLocationCtrlFn); //Todo change hotelDataService nameLocationCtrlFn.$inject = ['$stateParams', &a ...

Guide on positioning components to the right side of the NavigationDrawer in Vuetify with VueRouter

Working on my VueJS project, I've implemented a system to display content based on the user login using Firebase and Vuex state management. When a user is logged in, the content is shown using the v-if directive. Currently, I have successfully placed ...

Is it possible to use the .focus() event on an entire form in JQuery? If so, how

Take a look at this HTML snippet: <form ....> <textarea>....</textarea <input .... /> </form> I'm trying to set up a help section that appears when the user focuses on any form element, and disappears when they lose ...

Encountering an issue with Material-UI and Next.js: "TypeError: theme.spacing is not a function

Encountering an issue after modifying _app.js to dynamically generate a material UI theme. I've been following the implementation example provided by the material-ui team at: https://github.com/mui-org/material-ui/tree/master/examples/nextjs. To summ ...

Exploring best practices for transmitting JavaScript objects and arrays via forms to servers (JSON/??)

I would like to understand what would be the most effective approach to achieve this: Based on a user selection, generate a list of "selected items" in the following format: {items {categoryString {tag_id1 {[fr]=>itemFR, [en]=>itemEN} {c ...

Submitting an image from React and Redux to the backend: A comprehensive guide

I'm currently working with the MERN stack and facing an issue while trying to upload an image in the front end (react) and then access it in the backend (express, nodejs) for later storage. Despite using multer, I keep encountering 'undefined&apo ...

Custom-designed background featuring unique styles

I have implemented the following code to create a continuous running banner: <style> #myimage { position: fixed; left: 0%; width: 100%; bottom: 0%; background:url("http://static.giga.de/wp-content/uploads/2014/08/tastatur-bild ...

Is it possible to customize the styling of certain fundamental MUI components using makeStyles?

:D This is my first time embarking on a project from the ground up using react and MUI. I've been curious if I have set it up correctly. My goal right now is to incorporate some styling using makeStyles for certain components provided by Material UI ...

Tips for sending arguments to react-highcharts?

While browsing through the documentation, I noticed that I can pass config in a certain way: render() { let config = this.config; return ( <div className="column"> <div className="ui segment"> ...

Utilizing Vuex and Vue-Router for seamless authentication: Sending user ID from Vuex store to Vue-Router via router-link parameters

Can the ID of the currently logged-in user be passed to the router link's params? I have this piece of code and I am trying to display information on a page based on the params ID. routes.js { path: '/objective/employee/:id', ...