Doesn't work with Express.js
See original GitHub issueI wrote simple Express app and got an error.
var fs = require('fs');
var express = require('express');
var app = express();
app.get('/', function (req, res) {
res.send('hello!')
})
var options = {
key: fs.readFileSync('./ssl/key.pem'),
cert: fs.readFileSync('./ssl/cert.pem')
};
require('http2').createServer(options, app).listen(8080);
// require('https').createServer(options, app).listen(8080);// https module works well
_stream_readable.js:505
dest.end();
^
TypeError: undefined is not a function
at Stream.onend (_stream_readable.js:505:10)
at Stream.g (events.js:199:16)
at Stream.emit (events.js:129:20)
at _stream_readable.js:908:16
at process._tickCallback (node.js:355:11)
Is that a node-http2’s matter or Node’s one? It is hard to debug for me…
Node: v0.12.0 node-http2: v3.2.0 express: v4.11.2
Issue Analytics
- State:
- Created 9 years ago
- Comments:43 (10 by maintainers)
Top Results From Across the Web
Express Node.js doesn't work - Stack Overflow
So I have no idea of which port express is running on or whether or not it is running at all.
Read more >Express/Node introduction - Learn web development | MDN
js ) is an open-source, cross-platform runtime environment that allows developers to create all kinds of server-side tools and applications in ...
Read more >Top 10 Most Common Node.js Developer Mistakes - Toptal
Mistake #4: Expecting Callbacks to Run Synchronously. Asynchronous programming with callbacks may not be something unique to JavaScript and Node.js, but they ...
Read more >Node.js Error: Cannot GET/ from running the url on the web ...
Problem Statement: On running a Node. · Example: Let's create a simple Node. · Step 1: Initializes NPM: · Step 2: Install Dependencies:...
Read more >app.use not working · Issue #4390 · expressjs/express - GitHub
Our first request would be for you to create a very small program that demonstrates the issue and the http requests you are...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@gajus could you put that big log code block into a gist at all? It is making the page very large.
Using:
Does not work.
The complete log output: https://gist.github.com/gajus/843fd2d682f946680af161b7054b01f2