Unexpected behaviors in React JS
See original GitHub issueIssue Description
I installed the library using this command npm install TagCloud --save-dev
and because of a types
error I imported it like this
const TagCloud = require('TagCloud');
. After running the react app multiple spheres appear.
And another problem is when I change the javascript it doesn’t affect the sphere, also on every alternate reload it doesn’t load
import React from 'react';
import './about.scss';
function About() {
const TagCloud = require('TagCloud');
const myTags = [
'JavaScript',
'CSS',
'HTML',
'Vscode',
'XD',
'React',
'Python',
'Linux',
'git',
'Flutter',
'Dart',
'Firebase',
'SASS',
'JSON',
'Figma',
];
TagCloud('.content', myTags, {
radius: 250,
maxSpeed: 'fast',
initSpeed: 'fast',
direction: 135,
keep: true,
});
return (
<div className="About" id="About">
<div className="left">
<div className="heading">
<h1>ABOUT</h1>
</div>
<div className="para">
<p>
I am a high school student located in India, I am passionate about
UI designing, android development, web development and automation.
</p>
<br></br>
<p>
Love automating daily boring tasks using python, Linux OS, gaming
and in sports: football and badminton.
</p>
<br></br>
<p>
<a href="#Contact">Contact me</a>
</p>
</div>
</div>
<div className="right">
<span className="content"></span>
</div>
</div>
);
}
export default About;
Issue Analytics
- State:
- Created 9 months ago
- Comments:8
Top Results From Across the Web
Unexpected behavior Using React useState, Very strange output
I am a newbie in React. I was experimenting around to see how things work, and I found a very strange Behavior of...
Read more >Unexpected behavior when DOM structure is modified and re ...
Coding example for the question Unexpected behavior when DOM structure is modified and re-rendered in react-Reactjs.
Read more >Keys in react - why using indexes could lead to unexpected ...
in this video I'll show you an example of why using the array index could lead to some unexpected behaviors, what the key...
Read more >Cache unexpected behavior with react-native on Android #2694
I am using react-query in a react-native app. In iOS, everything is working as expected. On the other hand, on Android, the cache...
Read more >React-Native: Unexpected behaviour of Instance Mesh on its ...
Hello,. I have found that the Instance Mesh behaviour is unexpected as like babylonjs in react-native, particularly when I move its parent ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Great, thanks. Should we close de Issue? I think it’s more an issue with React rather than with the library
Oh for me this worked: