title: express js route matching url that doesn't start with a string
body: <p>I want my route to match URL that doesn't start with "/api/"</p>
  
  <p>For example, "/", "/home", "/profile" will trigger the route, but "/api/user/get" and "/api/xx" will not.</p>
  
  <p>I have tried the following regular expression and its modifications:</p>
  
  <pre><code>app.get('/^(?!api)', function(req, res) {})
  </code></pre>