69
questions
0
votes
0
answers
6
views
Storybook with Next.js and Webpack 5 cannot resolve various node modules
I'm trying to create a Storybook project with Next.js and webpack 5. I have a few decorators in my preview.tsx:
import type { Preview } from "@storybook/react";
import React from "react&...
0
votes
1
answer
15
views
Discord.js fs.writeFile not updating the correct json
I am using discord.js to write a bot. I am using a json called data in order to hold information that can be changed via slash commands. However, using fs.writeFile doesn't modify the targeted json.
...
0
votes
0
answers
3
views
How to deploy an AdonisJS API to Vercel
I'm having trouble deploying my AdonisJS (v6) application to Vercel. Despite following the AdonisJS documentation, I haven't been able to resolve the issue.
The deployment process on Vercel completes ...
-1
votes
0
answers
15
views
POST request works fine in devtools, but not on the website
My issue is that for some reason, the addEventListener for my POST request doesn't work unless I'm in devtools. The POST request is connected to a button on the page via this addEventListener in a ...
0
votes
1
answer
10
views
mock.module is undefined in Node.js v22.9.0 node:test module
I'm trying to mock some module using Node.js v22.9.0 with the built-in node:test mock.module .
While other properties like mock.method work correctly, I get undefined when trying to access mock.module....
0
votes
0
answers
5
views
Issue with Node.js Version and node-sass in Stencil CLI in Bigcommerce
I am currently using Node.js version 18 and have encountered an issue when attempting to run Stencil CLI with a lower version of Node.js. When using versions below 18, I receive an error indicating ...
0
votes
0
answers
7
views
How to correctly load ag-Grid CSS in an older Node.js 10.16.3 project using Polymer and Webpack?
I'm working on an older project using Node.js 10.16.3 and Polymer. I want to integrate the ag-Grid library, but I'm facing issues due to compatibility problems with modern JavaScript syntax, ...
0
votes
0
answers
7
views
TypeError: originalFactory is undefined in Aplication Next 14
In my next application, every time I start the project with npm run dev it gives me these errors
TypeError: originalFactory is undefined
Warning: An error occurred during hydration. The server HTML ...
0
votes
0
answers
8
views
Dealing with CORS when using dynamic routes in Vercel
I have set up a small express proxy which is designed to be deployed on Vercel. The user calls the proxy by sending a request to https://<domain>/<url_to_get>, for example https://proxy-...
0
votes
0
answers
5
views
In StyleDictionary with Node.js, after migrating from v3 to v4, "ts/resolveMath" transform is not found
After migrating StyleDictionary build script from v3 to v4, everything is working correctly, except the only "ts/resolveMath" transform:
Error:
Unknown transform "ts/resolveMath" ...
0
votes
1
answer
49
views
Implementation of Array.prototype.toLocaleString
I'm interested in the following piece of code written in JS:
const array = [1,2,3];
const locales = 'en-US';
const options = null;
console.log(array.toLocaleString(locales,options));
Before Node.js ...
1
vote
1
answer
8
views
Catching exceptions with async await and avoid unhandledRejection [duplicate]
I have a larger use case that I narrowed down to the following code snippet.
This code might not make a lot of sense however this is just to demonstrate the issue I have.
I am trying to catch the ...
-1
votes
0
answers
15
views
How to install an npm package that has submodules from GitHub directly
I made a fork of an existing node module (that has a git submodule), and I want to install my fork using npm fro GitHub.
However it seems that npm install does not save (or removes) the .git folder, ...
0
votes
0
answers
28
views
Why does my Telegram Login Widget validation not work?
Telegram login widget returns something like this:
.../callback?id=1234567890&first_name=xxx&username=xxx&photo_url=urlhere&auth_date=1234567890&hash=verylonghashhere
...
0
votes
0
answers
15
views
"Error: Cannot find module 'aws-sdk'\nRequire stack:\n- /var/task/index.js\n- /var/runtime/index.mjs" despite me adding a dependency to the sdk
I have upgraded my nodejs runtime on my lamdba function today from 10x (very outdated I realise) to 18x and I am getting the following error:
"Error: Cannot find module 'aws-sdk'\nRequire stack:\...