Questions tagged [javascript]
JavaScript is a versatile, high-level programming language. It is the programming language in all browsers, and can be used for back-end programming with Node.js. Use this tag for questions regarding vanilla JavaScript; optionally tagged with an ECMAScript version. If you are using a preprocessor such as TypeScript please tag with that too.
9,426 questions
0
votes
0
answers
37
views
Streaming messages for Chrome MV3 Web extensions
Explainer
Problem
No standardized Web Extension API to send or transfer TypedArrays or ArrayBuffers or
...
0
votes
0
answers
41
views
WebSocketStream implementation, JavaScript runtime agnostic
References
WebSocketStream Explained
WebSocketStream API design
Source code
https://github.com/guest271314/websocket-stream-impl
Implementation
...
1
vote
1
answer
150
views
A different way to create HTML elements
I created this module to help with the creation of HTML elements:
...
2
votes
0
answers
81
views
Native Messaging performance test
I put together this Native Messaging performance test to determine based on evidence which programming language, JavaScript engine or runtime, and WebAssembly compiled code is fastest to round trip 1 ...
0
votes
0
answers
38
views
SpiderMonkey JavaScript engine Native Messaging host
Native Messaging host using Mozilla SpiderMonkey JavaScript/WebAssembly engine.
Documentations
Chrome Developers
MDN Web Docs
Microsoft Edge Developer documentation
Messaging between the app and ...
6
votes
5
answers
1k
views
JavaScript program that calculates the sum and difference of a pair of numbers
The goal of the following openprocessing.org JavaScript program is to calculate the sum and difference of a pair of numbers and print the 2 results if they are both positive. I want to do the ...
1
vote
0
answers
40
views
A calendar event element
Below is code for a front end calendar event element I have just finished. Though I have been programming in JavaScript for a while, this is the first time I have created a custom class and element, ...
7
votes
1
answer
95
views
Fruity Balance GUI Remake
I am new to front end development and thought to recreate the GUI of Fruity Balance just for practice. I would love to hear any advice on best practices. I am also wondering if any improvements could ...
0
votes
0
answers
99
views
TCP and UDP sockets in the browser, Part 2: fetch() and WebRTC
A branch of a repository I maintain has a function that can do different things based on the input and expected result, and structure of a particular inner function call.
I can echo 20 MB to and from ...
-1
votes
2
answers
142
views
How would a more seasoned developer un-quag this quagmire?
I'm looking for suggestions on how this code structure can be improved. It feels like there's a smarter way.
The purpose of the script is to create live stream players if the following conditions are ...
2
votes
1
answer
152
views
Program to get all possible words from a set of letters
I wrote this code below to get all possible words for an array containing \$n\$ letters.
The logic of the code is that the letters of the array are mixed up in random positions and checks if this ...
6
votes
1
answer
543
views
Creating a fast connect 4 ai solver in JavaScript
I’ve implemented a Connect 4 AI in JavaScript using a Negamax search. My goal is to solve the game completely from the starting position (depth 42). I’m trying to make it as fast as possible and would ...
5
votes
1
answer
73
views
Web component (custom element) for a Swing-like (Java) tree with a shared style sheet
This is my first web component. I implement it as an autonomous custom HTML element. I cannot use a customized built-in element because it's not supported by Safari. Nevertheless, as it mainly ...
3
votes
1
answer
95
views
UDP and TCP sockets in the browser
I'm using a Web extension to communicate with an Isolated Web App over externally_connectable for the capability to use Direct Sockets UDP and TCP sockets from ...
4
votes
3
answers
200
views
My first web project; calculate the GCD and LCM of two numbers and save cookies
I made my first ever JavaScript project. It is a program that calculates the GCD and LCM of 2 numbers that the user inputs. It also stores these 2 numbers in cookies so that they can be accessed for ...