Most voted "node.js" questions
Node.js (or commonly Node) is a Javascript Runtime created with Chrome’s Javascript V8 engine. It allows you to run Javascript code without the need for a browser, raising the privileges to those found in other desktop languages. It is a technology strongly focused on non-blocking programming of I/O operations, which makes it very efficient for these operations.
Learn more…2,679 questions
Sort by count of
-
0
votes0
answers76
viewsIs there a socket.io event that activates when the client’s internet is slow?
Hello. I am in a project in nodejs + socket.io, I am with big problem, in relation to the client’s slow internet, I need to know if in socket.io there is some kind of event like this // If the…
-
0
votes2
answers393
viewsRoutes with Angularjs and Node.js
I learned a little about Angularjs and now I’m starting with Node.js and some doubts have arisen. With Angular I use $routeProvider to create the routes and navigate between the pages as single page…
-
0
votes2
answers660
viewsandroid Cordova camera plugin problem
I’m trying to make a "Hello World" in Ordova, it’s a screen with a button that triggers the camera, it’s not necessary to do anything else, just trigger the camera. the steps I took. Cordova create…
-
0
votes0
answers102
viewsM command "/usr/bin/nodejs" "/usr/bin/npm" "install" "Forever" "-g"
I tried to install a module and found some irregularities. I would like it to be precisely. I thought it was a conflict between directories /usr/bin/nodejs and usr/bin/npm. I tried to install…
-
0
votes0
answers154
viewsMonitor external HTTP requests within the page
Good morning gentlemen. It is possible to monitor page requests? I say: All the files that are called there, example: css, js, img, video, mp3, iframe... Any request HTTP.…
-
0
votes0
answers70
viewsGenerate graphics in image
Have some api where I pass the data, and it returns me the link of an image with the generated graph, in js Node? I found this project: https://github.com/ryanrolds/quiche, but it seems to be…
-
0
votes1
answer46
viewsNodejs: page not found
I was making my application, but when I update the page the browser returns me that the page is not available. I’ll post my code so you can tell me if there’s something wrong JS var http =…
-
0
votes0
answers38
viewsConvert date format to other
I would like to convert this date format: Wed Jul 20 2016 17:55:00 GMT-0300 (BRT) for this format: 2016-07-20T14:55:00.000-03:00
-
0
votes0
answers73
viewspg vs pg-Promise library
In my project I used the library pg for access to the postgres bank. But with some needs, I used the library pg-promise. For those who have used both, and understand more on the subject, I would…
-
0
votes0
answers104
viewsValidate information coming in req
I receive information for my route, where they are contained within a req. Ex: router.post('/', function (req, res){ }); This information I will put in my bank, however, before entering, I have to…
-
0
votes1
answer497
viewsProceedings with Nodejs
I would like to know how to take all processes with the nodejs equal to the c# Process[] processlist = Process.GetProcesses(); I would like to do this in NODEJS, to return all the PID from the…
-
0
votes1
answer955
viewsHow to organize the REST API and website frontend?
I am creating a Single Page Application site, for this, I created a Restful API on Node.js that does all the actions in the database, login, sending emails and etc. I thought of creating a "public"…
-
0
votes0
answers320
viewsExternal redirection on express
Galley, How do I change this line of my code: app.use(express.static(__dirname + '/public')); For 1 external redirect, for example redirect to http://www.google.com…
-
0
votes1
answer413
viewsSending and Receiving Packages (packets) in Nodejs
Well, I’ll try to explain the situation: I am studying Nodejs and for this I decided to rewrite the server-side code of an application that was originally written in C/C++, and this server receives…
-
0
votes1
answer834
viewsButtons with HTTP Request Action
The Button Click Request is receiving: { 'QTD1LED, ON': '' }, but I would like to receive only {QTD1LED, ON}. What I have is the change in my code? var http = require("http").createServer(servidor);…
-
0
votes1
answer417
viewsUpdate specific element in a Mongoose array
How to update the following record: "_id": "56dd4489800f800000000000", "registro": "2014-09-07T09:06:17.214Z", "stars": 0, "observacoes": [ { "texto": "", "dataResposta": "", "idUsuario":…
-
0
votes1
answer464
viewsFind in two Customers using Aggregation
I need to perform a find on two Collections in mongodb using Aggregation and place the results in a single array. I’m trying to do it this way, but it doesn’t work. I have Visiting and Opportunities…
-
0
votes0
answers345
viewsIs it possible to use Node.js as a server for PHP?
I am interested to know if I could use Node.js as a server for PHP. If so, how could I do that? Would it be a problem to use it?
-
0
votes0
answers422
viewsUpdating a list of documents in mongodb
I’m trying to update a list of objects similar to this: var lista = [ { _id: 57ea29361b297553c99d702f, nome: 'Meu nome', __v: 0 }, { _id: 57ea29371b297553c99d7031, nome: 'Meu outro nome', __v: 0 } ]…
-
0
votes1
answer243
viewsCannot read Property 'nodes' of Undefined
I’m getting the ERROR below when trying to implement a stylization in my project with Stylus. The same goes for background: url(...); and I think for any other attempt related. I found in the Github…
-
0
votes2
answers93
viewsNodejs replace windows terminal window
I remember installing the Nodejs on a windows machine and the terminal window (Command Prompt) has been replaced by a window fullscreen. If I’m not mistaken I had an option during installation. I…
-
0
votes1
answer148
viewsWarning when installing nodemon. How to resolve?
I installed the nodemon with the following command $ sudo npm install -g nodemon I got the following mistake: npm WARN notsup Not compatible with your operating system or architecture:…
-
0
votes1
answer895
viewssend email with Nodemailer
I created the following Model with Nodejs: 'use strict' function UserDAO(model) { this.model = model; } UserDAO.prototype.email = function(callback) { //TESTE de email var filePath =…
-
0
votes1
answer910
viewsDownload PDF Node.js
I’m using Request to download a billet from https://www.boletocloud.com/ which is in pdf. Turns out I can’t see the pdf I downloaded, the API developers say it’s in UTF-8, I’ve uploaded everything…
-
0
votes1
answer1311
viewsnpm WARN deprecated
I tried to find solution on the net about this error and the ones I found did not work. npm WARN deprecated [email protected]: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue…
-
0
votes1
answer657
viewsCreate audio file from URL
I need the messenger audio file to use in the Google Cloud Speech API. When an audio is received in the messenger, a url is generated that downloads that file into . mp4. How can I from that url…
-
0
votes1
answer34
viewsRead jade array value
I have the following array created in my controller: var data = []; for (var i = 0; i < array.length; i++) { nfejs(array[i], function(err, nfe) { var itemNfe = {}; itemNfe.name =…
-
0
votes0
answers64
viewsHow to make two different serialize and deserialize methods in Node js, with Passport?
I have two different types of user in my application. I was able to log in to one of the two users using Passport with serialize and deserialize. The problem is when I will do the second login,…
-
0
votes1
answer855
viewsNodejs - Redirect to error page when unable to access through GET
I would like to know how to redirect to a standard error page, such as a "not-found" page when a type error occurs Cannot GET /rota1/pagina2/18 I need that when the user tries to access a page like…
-
0
votes1
answer8812
viewsAngular JS Difference for Nodejs
What Angular JS Difference for Nodejs? Which is most used? Is there any tutorial that you recommend to those who are starting to teach a CRUD in each of them?
-
0
votes1
answer322
viewsQuery with Foreach and Subquery Node JS and MSSQL
I have a problem that I have not found solution yet, I have a select in a Precedent, I do a foreach in the result, inside this foreach I do another select in another Precedent using the Ids as code…
-
0
votes1
answer286
viewsHow to make a findOneAndUpdate in an array within another array with Mongoose
I am beginner in Mongoose, I would like to make an amendment (findOneAndUpdate) in the second array address in the city field, I tried everything I knew and I thank nothing to everyone who can help.…
-
0
votes1
answer126
viewsHow to port a Javascript Web server to a Windows executable?
I am new to Node.js, and developed a server using express to send files between computers on the same network, but I can only start the server on the computer that will receive the file if it has…
-
0
votes0
answers389
viewsTypeerror: Cannot read Property '1' of Undefined
Good morning, I need your help. I am receiving data from the serial port "/dev/ttyUSB0", my goal" is to recover some information ( temperature and humidity ) and replace in the object…
-
0
votes0
answers65
viewsSending android image to a js Node server
I’m developing a project and I need it to record a photo, and send it to a server that’s running Ode. In this same project is already running a data exchange through the socket.io and now I need to…
-
0
votes0
answers87
views404 socket.io.js with express in Node.js
I’m creating a simple chat that switches simultaneous messages between 2 browsers, using Node.js with socket.io, but for some reason, my project can’t identify my socket.io.js within the project.…
-
0
votes0
answers80
viewsHow to publish an API written in Typescript on Npmjs?
I created an API in Typescript just a short time ago. And I would like to know how you publish it in Npmjs, I know you have how to publish because Angular 2 low libs in Typescript. I don’t know…
-
0
votes1
answer423
viewsGulp Watch, SASS no amendment
My gulp: var gulp = require('gulp'), sass = require('gulp-ruby-sass'), imagemin = require('gulp-imagemin'), changed = require('gulp-changed'), browserSync = require('browser-sync'), livereload =…
-
0
votes1
answer133
viewsRegular Expression REGEX HELP
I have an array on the server in Nodejs, I am going through html files and I need to return the value that is in the middle of the span tag using a regular expression as it would look ? { < span…
-
0
votes0
answers191
viewsCallback is not defined - Node js
I’m making a connection with the Gento, and the connection works perfectly, but when I do the function I get the message 'Referenceerror: callback is not defined' Follows the Code,…
-
0
votes1
answer614
viewsWhat Way XPG FTP Access Via Javascript
You can access my free account on the XPG hosting server, through Javascript? I wonder if it is possible to make a connection with Javascript only with an FTP server(ftp://ftp.xpg.com.br), to "Send"…
-
0
votes0
answers90
viewsPost in table N:N with Node.js and Angularjs
I have a relationship N:N and 3 tables: projeto, pagamento and projeto_pagamento. In a form, I want to register a project and 5 payments, which would be the best way to perform this insertion? I…
-
0
votes0
answers29
viewsThe path to the http module
I know that the http module belongs to the core of Node.js. But where is it located? I can’t find it.
node.jsasked 7 years, 7 months ago Manoel Maciel 11 -
0
votes0
answers120
viewsHow to access DOM element from within the Clientesdao.js model?
I am making a query to the database and, to display the result in a #state element of the form, Nodejs does not recognize Document.getElementById('element'), nor jQuery. Error: ReferenceError:…
-
0
votes1
answer143
viewsDoubt about the structure of the Nodejs + Mongo app in Digital Ocean
Guys by indications I started using 1 machine at Digital Ocean in place at UOL Host. As I don’t have much experience with the server setup part, I’m in doubt and hope someone will help me: Setting:…
-
0
votes1
answer961
viewsFailed to run Ionic server
Good afternoon, I’m trying to run Ionic right after creating the project without even touching anything and always comes the same flaw. I no longer know what to try. When I run the command "Ionic…
javascript node.js apache-cordova ionic2 angularasked 7 years, 6 months ago Marcos Rai Alves da Cunha 372 -
0
votes1
answer221
viewsError in Node.js Module.js 472 throw err;
I’m creating a API in Node, for request with my application. But this error appears, claiming that this folder does not exist, but in the code I am not calling it anywhere. module.js:472 throw err;…
node.jsasked 7 years, 6 months ago Ramon Lopes 53 -
0
votes0
answers242
viewsSorting Object Array javascript
I am writing a library that implements several sorting algorithms all going well until I execute the sorting of an array of objects. const exec = (array, fnCompare) =>{ return sort.bubble(array,…
-
0
votes1
answer9
viewsWhen I store the ID it disappears with some numbers
I was making an app and in it I needed to store the id which is pretty great type this was my id 173782035419103232 but when arriving at the database it modifies to 173782035419103230 as I can do…
-
0
votes1
answer365
viewsNode.js sending GET command
Hello! I am having trouble using the GET /test command in this case, in which no information returns. Node.js code var http = require("http").createServer(servidor); var express =…