01 / 02

How to implement routing in express.js?

You define routing using methods of the Express app object that correspond to HTTP methods; for example, app.get() to handle GET requests and app.post to handle POST requests.

javascript
All available methods are:
  1. 1

    get

  2. 2

    post

  3. 3

    put

  4. 4

    delete

  5. 5

    head

  6. 6

    options

  7. 7

    checkout

  8. 8

    copy

  9. 9

    lock

  10. 10

    merge

  11. 11

    mkactivity

  12. 12

    mkcol

  13. 13

    move

  14. 14

    m-search

  15. 15

    notify

  16. 16

    patch

  17. 17

    purge

  18. 18

    report

  19. 19

    search

  20. 20

    subscribe

  21. 21

    trace

  22. 22

    unlock

  23. 23

    unsubscribe

Share

Share via WhatsApp, X, Facebook, LinkedIn or copy link. Open Graph preview enabled.