Category "javascript"

Javascript version mismatch for Tabris framework

Few month ago I gave a try to Tabris, a nice framework for the development of native Android and iOS apps in Javascript. I wanted to get back to it today but my

Powerapps code components with react and web3

I am doing a very simple powerapps code component project using react and web3. As soon as I build the project, I get a bunch of errors. Many of them I managed

Prevent select2 from opening when a tag is clicked

This question evolved into preventing the dropdown from opening on enter key press. As you can see, my ugly solution closes the dropdown with a setTimeout when

"'React' was used before it was defined." eslint warning

Similar question to this post on StackOverflow but I cannot seem to get rid of this warning after trying everything I could find on the internet. Github Issue.

AOS (animate on scroll) library not working when selecting elements to animate with jQuery

I'm trying to animate H1 elements for many pages using AOS (animate on scroll). I have several pages that use the title so I'm selecting all the titles with jQu

Remove new lines from JSON

Consider I have the following string: { "{\n <<<-- error \"SomeKey\": {\n \"somevalue\": \"test\",\n, \"AnotherKey\": \"Long string shou

How to execute a Bash command using an Electron platform in Cordova

I'm trying to use Cordova that now includes Electron to create a Desktop App for Linux. I want a button that fires a shell command: const exec = require('chil

How to identify whether webp image is static or animated?

I am working on a project where a user can upload webp images. I know how to convert webp images into jpg/png, but am stuck on how to identify whether the webp

Component name "Temp" should always be multi-word vue/multi-word-component-names

I am new In Vue.js Technology. I am getting an error while running my Vue application. Don't know where I am wrong, please try to fix my error. This is the Temp

extract-text-webpack-plugin replacement in webpack 5

I'm working on the project upgrading from webpack 3 to webpack 5. In the project, it was using raw-loader and extract-text-webpack-plugin to parse imported html

Javascript Fetch - Custom header is causing error: net::ERR_HTTP2_PROTOCOL_ERROR

Good day, I need to access the API of a payment gateway from my website. It is built with React and Next JS. While using the fetch method, I get an error: net::

Embed a React component into a HTML site, without affecting the parent site's styling and without an iframe

I have a React component that I want to build and insert into an HTML site. The component has some styling, which if imported will conflict with the HTML site's

How to Use Firebase Phone Authentication without recaptcha in React Native

I want to use firebase phone verification without recaptcha in react native. Below is my code. The code is working properly. But I Don't want to use recaptcha.

Chart.js error Cannot read property 'length' of null

I am using Chart.js via an ajax call $.ajax({ url: 'MenuG.aspx/GetGraphData', type: "POST", data: "{}", dataType:

import json file in react, webpack config error

I am trying to import a json file into my code. The js file for the same is import React from 'react'; import ReactDom from 'react-dom' ; import $ from 'jquery

Testing axios.create() instance with jest

I tried many solution from this task. I want testing axios instance api call without any libralies (jest-axios-mock, moaxios, msw, etc). I hope it's possible, b

How can I connect IPFS with infura when uploading data?

I'm creating an NFT marketplace using hardhat, solidity & Next js, I have a form from where I enter some specific information about the NFT, then by clickin

spawnSync /bin/sh ENOBUFS

Error "spawnSync /bin/sh ENOBUFS" spawns in my NodeJs application non-systematically while executing the following line : child_process.execSync(`cd /tmp/myFold

await & async when you don't care about errors

Let's take a simple example, fs.stat. I can promisify fs.stat and write: const stats = await stat(file, fs.constants.R_OK); but if the file doesn't exist this

Get No. of approvals on a pull request using github's graphql api

I'm trying to get the number of approvals a pull request has received. I can get the number of reviews, but that includes all reviews whether approved, rejected