Questions tagged [node-modules]
Node.js has a simple module loading system that reduces complexity of applications and promotes code reusability.
5,558
questions
0
votes
0
answers
17
views
Implementing Twitter API with NodeJS
I am trying to develop a NodeJS app and i want to be able to search for tweets including a keyword here is my code:
const express = require("express");
const app = express();
var Twitter = ...
0
votes
0
answers
15
views
Nest js convert module from forRoot to forRootAsync
@Module({
imports: [],
providers: [SupertokensService, AuthService],
exports: [],
controllers: [AuthController],
})
export class AuthModule implements NestModule {
configure(consumer: ...
-3
votes
0
answers
18
views
express js node api getting issue in https
i have created node app, which is working fine in http, but not working with https, can anyone please help me how to resolve this issue ? here i have added my script for it, any help will be really ...
0
votes
1
answer
20
views
Npm install failing because of bcrypt error
I deleted my node_modules folder in order to fix a previous error and now I'm stuck in another one and another one, I've even forgotten the initial error. Every time I try to run npm install or try to ...
0
votes
0
answers
14
views
How to import installed plugins via npm into Gulp final build?
There is a Gulp build for small projects. For example: I installed the plugin via npm import <Plugin Name> from <Plugin Path>. In theory, then I connect it to scripts.js and everything ...
0
votes
0
answers
12
views
How to solve "Error: package subpath.." while using jasmine-ts?
I'm running a nodejs project with jasmine and jasmine-ts
i get these errors when i try to run my tests
Error: Package subpath './lib/command' is not defined by "exports" in
D:\Projects - ...
0
votes
0
answers
23
views
What is the correct way of solving npm dependency tree errors?
After running npx npm-check-updates -u I tried running npm install, and got the following message:
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! Found: @nestjs/typeorm@8.0.3
...
1
vote
0
answers
15
views
'node_modules' is not recognized as an internal or external command, when running npm run build
When cmd tries to run node_modules/.bin/tsc I get this error:
'node_modules' is not recognized as an internal or external command,
operable program or batch file.
Package.json file contains the ...
0
votes
0
answers
12
views
Can't resolve 'react-image-video-lightbox'
This is my first question on StackOverflow. So might miss out on detailing, so please correct me if needed.
I am facing an issue with one of my imports in reactJs. The package react-image-video-...
0
votes
0
answers
12
views
After I update Npm then shows flowing dependency errors,How to solve this error shown in below?
Firstly I have an issue with crashing my app while working then I post a question in the stack and get some answer of updating Npm. After Updating Npm and deleting node modules, Package-lock Jason ...
-1
votes
0
answers
20
views
Node install, Node index.js, npm install
I am trying to create a mint website for my new nft collection but when i try to run node install ,npm install, or node index.js i keep getting errors. Im fairly new to coding so im not exactly sure ...
0
votes
0
answers
19
views
Node-gyp error while using install on Ubuntu
how are you? I have some problems with npm install.
I tried to download @discord/opus but the result looks like this. Does anyone know any decision? If so, it can be said about the solution. Thanks ...
-1
votes
0
answers
28
views
return value in nodeJs function with parameters
I got a problem with an async function but I found an issue on that site.
The problem is in that function, there is no parameters and I didn't find how to put them in my functions to execute the code ...
0
votes
0
answers
18
views
vendors~main.chunk.js file is getting downloaded multiple times
In our Create React App, this vendors~main.chunk.js file is getting downloaded multiple times.
We are using React 17, and previously, we got this issue when we assigned an undefined value to an ...
0
votes
1
answer
21
views
Is there any way add extra type for external npm packages in react type script?
I have imported react-microsoft-login package from npm and added one button in property children.
But I got a typescript error " property 'children' does not exist on type 'intrinsicattributes &...
0
votes
0
answers
10
views
nodemon crashed every time its run with error FontFaceSetLoadEvent, why is this?
I have this very simple express server. I use nodemon and every time i say npm run dev which should run nodemon server.js it crashes and I get FontFaceSetLoadEvent error.
I am not using ...
0
votes
0
answers
16
views
How to use ES Modules in Electron.js project
I'm working with electron.js, and I need to use an ES Module I made for an other project.
How can I include this module in my project knowing that electron js doesn't works with ES Module, and it ...
0
votes
1
answer
29
views
Use npm in Asp .Net Core 6 MVC project (instead of CDNs)
I'm trying to use npm inside .Net core 6 MVC project. I have added the file webpack.config.js as following:
module.exports = {
entry: [
"babel-polyfill",
"./src/...
0
votes
0
answers
22
views
Koa js Cannot find module 'koa-bodyparser' Internal Error
enter image description here
const Koa = require('Koa');
const bodyParser = require('koa-bodyparser');
const productRoutes = require('../routes/products.routes');
const app = new Koa();
app.use(...
-2
votes
0
answers
23
views
Is there a way to fix this error and get the npm start to work? [closed]
I tried installing an date picker from this site: https://www.npmjs.com/package/react-datepicker and now my React app isn't starting up. How can I fix this? Here are some screenshots of the error ...
0
votes
1
answer
45
views
How can I use a bind mount in docker-compose and still preserve node_modules?
I am trying to build and run an image based on this docker course. The goal is to have a bind mount that allows me to sync source code changes with the running container, but also to preserve the ...
-3
votes
1
answer
32
views
Are npm packages equal to node_modules?
What is the difference between npm packages vs. node_modules?
Or is an npm package equal to a node_module?
-1
votes
0
answers
7
views
How to bulk install and deploy packages on all aplications in netlify
I have a lot of applications in netlify. I want to install and deploy packages in all of applications. Is there any solutions for it?
0
votes
0
answers
5
views
How do I install the library I created in the example project using react-native-builder-bob?
I'm trying to build a component library for react-native.
I'm using a library called react-native-builder-bob since I figured out it was the most convenient way to do so.
The project is setup, I built ...
0
votes
0
answers
23
views
what is the best way to perform multiple inserts with tedious nodeJS
what is the best way to open and close connections when multiple inserts are made, through a stored procedure with tedious
try {
let conn = await Con.create();
for (let i = 0; i &...
0
votes
1
answer
16
views
When does the export statement runs in node js?
When does the export statement run? Is it before callbacks run. In that case, var1 and var2 will be undefined. Or is it after callbacks are completed?
let var1 = someAsyncFunction(param1).then( result ...
0
votes
0
answers
11
views
npm i command not work for aliases packages
Simply npm install doesn't work for alias packages, I need to do it like this
Sample:
npm install element-ui-fix-input@npm:element-ui@2.3.2
The aliased package is not affected if I do npm install. ...
0
votes
0
answers
56
views
ENOTDIR: not a directory node_modules/.staging/@types/node-16824c86/package.json
It error When I run docker exec -t [image] npm run production.
npm WARN ws@8.2.3 requires a peer of utf-8-validate@^5.0.2 but none was installed.
npm ERR! Linux 4.10.0-35-generic
npm ERR! argv "/...
0
votes
1
answer
19
views
Import existing modules in the VS code plugin extension
We're developing a VS Code extensions web plugin using Typescript. We already have a company provided component, which is downloaded in the node_modules folder. But when I'm referring those modules, ...
0
votes
0
answers
18
views
How to export variables that are assigned inside a callback function?
I am trying to create multiple DB connections. The problem is in order to get the DB connection string, I have to call an asynchronous function (getDBString). This asynchronous function returns the ...
0
votes
0
answers
9
views
nconf not working after installing jsonwebtoken
I recently introduced the jsonwebtoken as a dependancy in my nodeJs project which started breaking the nconf and now nconf is no longer able to read/parse the .json config files.
Note: The project is ...
1
vote
1
answer
64
views
+50
link or install local typescript library inside docker container
I'm still dockerizing our microfrontend application. Currently we use React and Angular and a shared library for the communication. The library is developed by ourself and installed locally via npm.
'-...
0
votes
0
answers
31
views
Executing NodeJS script From PHP (Laravel), not finding Node Modules in production
I have this function in my API Controller that executes a node file and it works normally on localhost, here is the script.
GifApiController.php
public function saveAndDissectGif(Request $request) {
...
0
votes
0
answers
21
views
Debug node_module file in docker with nextJS
I d'like to debug a node module JS file. I placed some console.logs inside it.
Now can't see nothing of these logs, so I made follwoing steps:
rebuild docker container
clear nextJS cache
First with ...
0
votes
1
answer
35
views
Yarn Unknown Syntax Error: Unsupported option name ("--check-files")
When I try to run yarn install --check-files on a rails repo that I cloned I'm getting the following error:
Unknown Syntax Error: Unsupported option name ("--check-files").
$ yarn install [-...
0
votes
1
answer
10
views
Netlify - Are deployment files case sensitive?
I've been working on a storybook and it works locally and on a dev server but when I deploy to Netlify - I get the following:
10:16:05 AM: ERR! ModuleNotFoundError: Module not found: Error: Can't ...
-1
votes
0
answers
44
views
error functions@1.0.0: The engine "node" is incompatible with this module. Expected version "14". Got "16.15.1", error Found incompatible module
good day sir/ma,
my react native app was using node@14, due to some persistent breakdowns i was compelled to decide to upgrade the node and all packages of node_module. After doing that, i kept on ...
0
votes
2
answers
35
views
Override nextjs-Sourcecode
I have an issue in my next.js-Application that might be only being fixed by a small adjustment to the next.js-Source-Code.
For simplicity I reduced the amount of code a little bit:
export class Head ...
0
votes
0
answers
30
views
Convert node package to React Native
I am struggling to integrate CinetPay in React Native app. They are giving solution in Node package or CDN javascript. I have installed node package from https://www.npmjs.com/package/cinetpay-nodejs.
...
0
votes
0
answers
31
views
i am having this issue when i am trying to check npm version in cmd
`node:internal/modules/cjs/loader:933
const err = new Error(message)`
Error: Cannot find module 'yallist'
1
vote
1
answer
28
views
How to pass pusher to utility classes in node.js
I am using Node.js here with Pusher,
but it's not a pusher related question, it's more of a Node.js question.
In Server.js (declare pusher, and used pusher once for authentication)
import express from ...
0
votes
2
answers
39
views
"No Exports Main Defined In" Error Node.js
I'm trying to make a simple api with js. But i keep getting this stupid error. NOTE: This is my first time programming in js.
Code:
const express = require('express')
const app = express()
const { ...
0
votes
0
answers
128
views
Cannot install @testing-library/jest-dom with Node 16.2.0
Deleted the node modules and dropped the package-lock file. After that try to do npm install and it results in the below error. Node version is 16.2.0. Ran npm cache clean --force as well.
npm ERR! ...
0
votes
0
answers
13
views
Facing problem while typing `yarn add --dev hardhat` in terminal using vs code
Warning come out and no node modules file added in the folder
0
votes
0
answers
147
views
How do i resolve this error even if the required version is installed?
Run borales/actions-yarn@v2.0.0
/usr/bin/docker run --name e2caa166253314d58b81117c99f1cce31_ec68be --label 72882e --workdir /github/workspace --rm -e INPUT_CMD -e INPUT_AUTH-TOKEN -e INPUT_REGISTRY-...
0
votes
2
answers
71
views
ERR_PACKAGE_PATH_NOT_EXPORTED with firebase-admin 11.0.0 and firebase-functions 3.21.2
I'm trying to update to the most recent versions of firebase-admin (11.0.0) and firebase-functions (3.21.2). I'm using firebase-tools 11.1.0. I get this error when try to deploy my functions:
Error: ...
0
votes
0
answers
18
views
How to ignore global node_modules folder when running npm script
I want to run a npm script (e.g., npm run start) but I do not want the module search path to include the global npm modules (e.g., /Users/Bob/node_modules). How can this be accomplished? Alternatively,...
0
votes
1
answer
28
views
Remove dependency completely from Npm
I wanna remove some dependencies completely from my project i.e package.json, package-lock.json
Package.json
{
"name": "application",
"version": "0.0.0",
&...
0
votes
1
answer
47
views
Module parse failed: Unexpected token / swagger-ui
Our repository has been running swagger-ui with no issues, but without any changes being made, I am now receiving an error and unable to update the repo at all. The build fails during deployment and I ...
0
votes
1
answer
20
views
Installed npm packages without npm init
I forgot to initialize npm by "npm init" and then installed other npm packages like express,ejs etc. inside my current project directory.
Where are these packages stored since no package....