Questions tagged as 'nodejs'

1
answer

Consultation with mongoose

I want to call all the names of a 'users' collection without the information that accompanies it, the query that I do brings all the information that is in the 'users' collection (name, surname, password) and I would just like to call the names...
asked by 05.06.2018 / 07:51
2
answers

call files from the same module

Hello a moment ago I saw in a repository that I could call in the same project folder subfolders or files that were declared in package.json by @declaracion: file: nombrearchivo I think I saw it in several more sides but I did not...
asked by 01.07.2018 / 04:27
1
answer

how to refer to a schema in another folder

for example the following schemes are the following folders cr/user lms/content this is the outline contained user: { type: Schema.Types.ObjectId, ref: 'cr/user' } How can I reference a user from the schema content?...
asked by 08.05.2018 / 07:34
1
answer

Update a field in Mongoose if the new value is not null?

having a Schema like this: const FarmSchema = new Schema({ name: { type: String, required: true }, extension: { extension: { type: Number, min: 1, max: 1000, required: true }, measure: {...
asked by 05.05.2018 / 21:31
2
answers

How to fix error when executing webpack command from Node js?

I try to run the webpack command to compile an application in react js, previously I worked in ubuntu and it worked perfectly and I changed to windows and when using node js in windows, it generates the following message that does not allow me t...
asked by 27.04.2018 / 19:56
1
answer

Install create-react-app in a sub-domain

I'm doing a project on React using the create react app command. I have my server with NodeJS and I want to install the project in the main domain like www.dominio.com (that's what I do). But I also want to install a test version on test.domon...
asked by 29.04.2018 / 13:45
1
answer

How do I set an array as a parameter in JavaScript? [closed]

I've been trying a new function to my program, this program has the purpose of making it easier to search for elements within an array, all these elements are unique, one way to find them and deliver them is by a rank, giving two parameters in t...
asked by 25.04.2018 / 21:25
1
answer

How can I start a live server with node npm? [closed]

I'm new to this, I wanted to know how to start a live server with node npm? I started it with python but it does not have live-reload, when I try it with npm I get an error     
asked by 25.04.2018 / 16:36
1
answer

Server problem js

I have a problem creating a server with node JS. I write this code //Importando var express = require('express'); var bodyParser = require('body-parser'); var request = require('request'); //Instancia var app = express(); app.use(bodyParser....
asked by 10.04.2018 / 03:34
1
answer

Does anyone know how to activate shield in AdonisJS? Can not call function csrfField from

I have a problem with AdonisJS I am trying to create a form to send data by POST, but at the time of placing the token I get the following error "Can not call function csrfField from", now if I deactivate the shield and remove the function {{ cs...
asked by 13.04.2018 / 18:50