All Questions
42
questions
4
votes
3
answers
165
views
Get the contents of a table cell for all selected rows
I have a table of user info. When you click the button, I want to get the email address from each selected row, output into a comma-separated string.
I got it to work with the following code, but I'm ...
0
votes
1
answer
70
views
JS "Tabs" element
How can this be improved?
I'm looking particularly at the twice repeated tabButtons.forEach(button => {
...
2
votes
1
answer
945
views
Animating GIF on hover in Javascript
I don't know JavaScript and it's safe to say this is my first code ever written in JS.
I just needed to animate my GIFs when user hovers over them only.
Googling separate concepts such as "string ...
0
votes
1
answer
160
views
Range slider show/hides and reset (vanilla js)
I have a HTML5 range slider. i.e. ...
2
votes
1
answer
226
views
Carousel Using Vanilla Javascript
As a beginner project, I've start working on this carousel slider that would slide through an image and a testimonial on click.
The number of images and content slides would always be the same number. ...
2
votes
2
answers
454
views
jQuery form.find radio class
In my application we have four inputs that are radio controls and the first radio control is checked by default. When the user selects another radio control and then saves the form I want to get the ...
6
votes
1
answer
499
views
Simple input class change with vanilla JS
I am just testing how I solved simple stuff.
Goal: The aim is to expand the width of an input and collapse it.
When mouseover ...
1
vote
1
answer
88
views
Automatically select the table rows between two selected rows
The code is to check the rows in a table. If in a table two non consecutive rows are checked then all the in between rows should be selected by itself. Also, after selecting two rows, on selection of ...
2
votes
2
answers
258
views
Cardinal direction enum from range input
Still learning JS and I made the following function to convert degrees into cardinal directions respectively. My first iteration of the code was over 50 lines and I was able to get it down to 13 using ...
4
votes
2
answers
465
views
Dynamically add/remove fields on input
The following code allows users to enter multiple optional quantity fields after first filling in a value of the current quantity input. If the input field contains a value it will then display the ...
4
votes
1
answer
135
views
Event triggers for animations using vanilla ES6
I'm new to JS and wanna know right code style or approach to cod Vanilla JS using ES6. To practice this, I'm using ESLint JS code-style of AirBnb and referencing clean-code-javascript repo. However, I ...
1
vote
0
answers
25
views
Creating a reusable plugin (Dialog/Notifier as example)
I started working on a notification system that is pluggable into any project. I have not made any "plugin" type javascript libraries, usually just functions very specific to the project at hand. That ...
2
votes
1
answer
407
views
Is this a proper way to cancel an onMouseOver which uses setTimeout? (Vanilla JS)
I've got a working solution for an onMouseOver event which rolls over a set of images and replaces them in the element. Due to my lack of knowledge in JS I would ...
3
votes
2
answers
933
views
jQuery dynamic toggle class function
I wrote this function that will toggle a class of a targeted element. Applying the class js_class_toggle to any element will trigger the function when clicking on ...
6
votes
2
answers
682
views
Tic-Tac-Toe code in JavaScript
I have developed a tic-tac-toe game in native JavaScript.
Can you tell me how to optimize more and what are the missing things? JSBIN
The logic, modular approach, testable and scalable?
...