我会很容易地解释我的问题:
我想与 github webhooks 交互以在我的用户(或登录用户)单击 repo 上的 star(应该是这个钩子事件)时获取。
我有一个带有 node + express 的简单服务器,但我真的不明白如何执行它。有人可以帮助我吗?
const chalk = require('chalk');
const express = require('express');
const serverConfig = require('./config/server.config');
const app = express();
const port = process.env.PORT || serverConfig.port;
console.log(chalk.bgGreen(chalk.black('### Starting server... ###'))); // eslint-disable-line
app.listen(port, () => {
const uri = `http://localhost:${port}`;
console.log(chalk.red(`> Listening ${chalk.white(serverConfig.env)} server at: ${chalk.bgRed(chalk.white(uri))}`)); // eslint-disable-line
});
Run Code Online (Sandbox Code Playgroud)