📜  express 获取斜线值 - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:03:39.837000             🧑  作者: Mango

代码示例1
app.get('/new/:url(.*)', (req, res) => {
  console.log(req.params.url) // will output 'https://www.google.com'
// --- OR ---
app.get('/new/:url(*)', (req, res) => {
  console.log(req.params.url) // will output 'https://www.google.com'