問題タブ [node-libcurl]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票する
1 に答える
81 参照

javascript - Node js working on second or third call

I have written a node.js server which creates a server and prints the output when done with an asynchronous function. While I am able to get the correct output always in the console.log. The same is not getting reflected in my response. Here is my code snippet :-

Now on starting the server and accessing it in browser with parameters link and position as get, I am getting output on second or third refresh. I am getting perfect output in console.log though !

Can anyone help or guide me in this regard ?

Thanks !

0 投票する
2 に答える
921 参照

javascript - node-libcurl からステータス、本文、およびヘッダーを取得する

Node.js アプリケーションに次のコードがあります。

にブレークポイントを配置すると、 、、およびが正常に読み込まれていることがreturn {status: curlStatus, body: curlBody, headers: curlHeaders};示されます。ただし、後にブレークポイントを配置すると、、、および変数がまだ空の文字列であることがわかります。親関数に情報を渡すにはどうすればよいですか? bodyheadersstatusCodecurl.perform()curlStatuscurlBodycurlHeaders

0 投票する
1 に答える
1212 参照

node.js - node-libcurl が原因でコマンド npm install が失敗する

実行npm installすると、node-libcurl が原因で失敗します。MacOSXでは正常に動作していますが、ubuntuボックスでは動作していません。何がうまくいかないのか、それを修正するために何ができるかについての提案。

Node.js バージョン: v9.4.0 NPM バージョン: 5.6.0 Ubuntu 17.10