Data dodania Pytanie
2017-01-09 23:01 why var clientPeople = <%- JSON.stringify(serverPeople) %>; console.log(typeof clientPeople); returns as object not string inside of ejs file »
This code is running inside of an ejs file: Questions is why var clientPeople = <%- JSON.stringify(serverPeople) %>; console.log(typeof clien...
(1) odpowiedzi
2017-01-09 14:01 how to create cross platform scripts (multiple command for single line) in package.json (nodeJs) »
issue: in script: we want to check env. variable {dev/test/mock} and do following script run based on it. if $mock is true the run script start-mock...
(2) odpowiedzi
2017-01-09 13:01 electron remote global value undefined »
I am using var remote = require('electron').remote; and trying to get the value using remote.getGlobal('config').siteUrl In my main.js I am setting t...
(0) odpowiedzi
2017-01-09 06:01 node js (with ejs view engine) and datatables »
I am using node js with ejs view engine and mySql database. I want to use datatable in my application with Server-side processing in node js so how sh...
(0) odpowiedzi
2017-01-09 05:01 Difference between Q.defer() & Promise() »
I'm trying to understand why following code is behaving differently with Q.defer() and Promise() Case 1 : When I'm using Q.defer() getDocument(i...
(1) odpowiedzi
2017-01-09 00:01 Passing dynamical information using ejs and html »
so I am trying to pass some variable ( number) data to a email template. I am trying to use the ejs like this : var compiled = ejs.compile(fs.readFil...
(1) odpowiedzi
2017-01-08 20:01 Display Mongoose Grouped By Data in EJS »
I have mongoose data, queried using aggregate group by, which I want to display in EJS. // route.js router.route('/') .post(function(req,...
(0) odpowiedzi
2017-01-08 15:01 Mongoose: TypeError: hex is not a function »
I am developing a simple data persistence app using mongoose, After getting stuck on this error CastError: Cast to ObjectId failed for value "{ _...
(4) odpowiedzi
2017-01-08 14:01 Why node.js is much slower than Google Chrome? »
I've got simple code, that creates a chunk with 16*16*256 boxes of 10 elements array and a bool variable. Method tick increases array elements and cha...
(1) odpowiedzi
2017-01-08 10:01 Request body is empty when making a POST request via HTML form »
I'm having a problem with symptoms similar to this question and several others, though the answers haven't helped me. I'm trying to submit a password ...
(1) odpowiedzi
2017-01-08 06:01 Asynchronous function not producing immediate result inside while loop »
I am new to nodejs and what I have done is I have connected LCD Panel and 4x4 Membrane matrix keypad to Raspberry Pi and I have programmed them using ...
(1) odpowiedzi
2017-01-07 23:01 Get the number of times each string occurs in an Array »
function countWords(inputWords) { var sortArray = inputWords.sort(function (idx1, idx2) { return idx1.localeCompare(idx2) }); var resultArray = []; va...
(1) odpowiedzi
2017-01-07 17:01 Node express server not serving images folder »
When I run my bundled React app on the production server, it can't find my image files and I'm not sure why. I'm fairly sure it's got something to do ...
(1) odpowiedzi
2017-01-07 13:01 Promise does not resolve node.js »
I am trying to resolve some promises by the sendRequest function but it does not work. For example, if I evoke sendRequest function 4 times, all of t...
(1) odpowiedzi
2017-01-07 04:01 UNMET PEER DEPENDENCY D3.js and Angular 2 »
I have an existing Angular 2 project, and I'm trying to get started integrating some D3.js into my project. I'm new to Angular, and this will be my fi...
(2) odpowiedzi
2017-01-06 21:01 sw-precache-webpack-plugin webpack service worker default template »
I'm using the sw-precache-webpack-plugin to generate a service worker for my project, I can see all my fonts, js and css files in the cache storage bu...
(1) odpowiedzi
2017-01-06 15:01 SSL Certificate {Non-self-signed certificate} not connecting Socket.io to Nodejs server »
I tried to connect to a non-secure {without SSL} node.js server via socket.io-client and when i run HTTP it works fine in the iOS app But when I conn...
(0) odpowiedzi
2017-01-06 14:01 Normalize missing value inside an array of objects with nodejs »
I have this data scenario: var data = [ { 'name': 'social-button', 'group': null }, { 'name': 'social-button', 'group': null }, { 'name'...
(3) odpowiedzi
2017-01-06 14:01 Elasticsearch with node js: List all the types and fields of an index »
I can get the mapping of an elasticsearch index like this: module.exports.indexMap = function (Data, callback) { client.indices.getMapp...
(0) odpowiedzi
2017-01-06 11:01 how to push an element at index 0 of an array »
i have a situation like this, i have 2 array1 as array1 = ["fruit","vegetables"]; and array2 = [["apple","banana"],["tomato"]]; // index 0:repre...
(2) odpowiedzi
2017-01-06 11:01 How to display all eslint warnings of the whole project in Atom? »
Currently my client-side project is build by webpack. Linting the project is part of the build process. All lint warnings/errors in the project are di...
(1) odpowiedzi
2017-01-05 21:01 nodejs: why calling hasOwnProperty ist different from global.hasOwnProperty? »
Maybe this is a newbie question, but I cannot find or think out the explanation. Start the Node.js console. > global.hasOwnProperty === hasOwnProp...
(4) odpowiedzi
2017-01-05 17:01 Passing a sql table created with alasql from Server (node.js) to Client (ejs) »
I would be very glad to get some help on the following topic, given I didn't manage to get through it. My objective is to gather some data on the serv...
(1) odpowiedzi
2017-01-05 14:01 How to shrink size of Docker image with NodeJs »
I created new Angular2 app by angular-cli and run it in Docker. At first I init app on my local machine: ng new project && cd project &&...
(2) odpowiedzi
2017-01-05 14:01 Error: request entity too large in graphql services of node »
I am working on node based graphql project, trying to send base64 formate image to server. I am using bodyparser module and configured it as bellow. ...
(1) odpowiedzi
2017-01-05 09:01 Express app with EJS template giving Error: Failed to lookup view "/id" in views directory "/home/USER/Desktop/scholarship-app/views" »
I am trying to render the request url for id in my express app and getting the following error Error: Failed to lookup view "/id" in views directory ...
(1) odpowiedzi
2017-01-04 16:01 How can I retrieve the properties of a data object in EJS/node.js? »
I am passing a data object, as a parameter, to the render method, and assigning to it the variable name "values". app.get('/', function(req, res) { ...
(2) odpowiedzi
2017-01-04 14:01 Using csurf with react-server »
I would like to add csurf as an express middleware inside the react-server for a universal app. What I want to achieve is adding the csrf token to a ...
(0) odpowiedzi
2017-01-04 13:01 Is there a nice way to route using EJS teamplate avoiding repetition with Express server? »
Let's say that my app has two view: index.ejs, profile/index.ejs I want to route using express code like below. /* GET home page. */ router.get('/', ...
(2) odpowiedzi
2017-01-04 11:01 Mongoose - deprecated mongodb@2.2.16: Please upgrade to 2.2.19 or higher? »
Why do I keep getting this warning message below when I try to install mongoose? npm WARN deprecated mongodb@2.2.16: Please upgrade to 2.2.19 or h...
(1) odpowiedzi
2017-01-04 07:01 Getting TypeError: Unknown encoding: 1 while running the server script with Mongoose »
I am running the following code to insert fruit names into the database with Mongoose. It does insert the object but then it throws a TypeError: Unkno...
(2) odpowiedzi
2017-01-04 02:01 how let html-webpack-plugin works with backend render ejs? »
I want use it with the backend render template ejs . But the plugin render it as a front template. does any one know how to deal this case ? ...
(0) odpowiedzi
2017-01-03 22:01 Combining Observables - waiting 'til all observables fire »
I have this code let $obs = Rx.Observable.merge( this.obsEnqueue, Rx.Observable.timer(2000) ); but this isn't doing want I want - want I wo...
(2) odpowiedzi
2017-01-03 22:01 EJS error: Unexpected token < in NodeJS app »
I'm building a NodeJS application with the EJS template engine. I've used the same syntax as I did in an app I've build earlier, but on every rendered...
(0) odpowiedzi
2017-01-03 19:01 Will Stripe API retry a Webhook request if my server was unable to receive it? »
If I set up a Stripe Webhook to send a request to http://my.website.io but, for whatever reason, my server is down at the time or somehow unable to pr...
(1) odpowiedzi