Update Tinder.js
All checks were successful
Create and publish a Docker image / Deploy image (push) Has been skipped
Create and publish a Docker image / Publish image (push) Successful in 1m17s

This commit is contained in:
VITALY-VORON 2023-08-24 22:06:44 +03:00
parent 80e8fbf328
commit 18b3e0b819

View File

@ -1,6 +1,6 @@
import React, {useEffect, useState} from 'react';
import TinderCard from 'react-tinder-card';
import './Tinder.css'
import './Tinder.css';
const db = [
{
@ -45,7 +45,7 @@ const db = [
useEffect(() => {
let uniqueTags = [];
if (cardId.length === swiped.id) {
if (cardId.length === 1) {
uniqueTags = cardId.filter(function(elem, pos) {
return cardId.indexOf(elem) === pos;})
console.log(uniqueTags);
@ -72,7 +72,7 @@ const db = [
<div className='card'>
<div
className='card-content'
style={{ backgroundImage: `url(${character.url})` }}
// style={{ backgroundImage: `url(${character.url})` }}
>
<h3>{character.name}</h3>
</div>