Routes and How To Create Them

In this lesson, we'll learn how to define routes within AdonisJS and how those routes work.

Published
Jan 24
Duration
5m 24s

Developer, dog lover, and burrito eater. Currently teaching AdonisJS, a fully featured NodeJS framework, and running Adocasts where I post new lessons weekly. Professionally, I work with JavaScript, .Net C#, and SQL Server.

Adocasts

Burlington, KY

Join The Discussion! (2 Comments)

Please sign in or sign up for free to join in on the dicussion.

  1. Commented 1 month ago

    Question, why I encountered error when I tried to make a request from REST Client or curl?

    GET http://localhost:3333/movies http/1.1

    It said,

    The connection was rejected. Either the requested service isn’t running on the requested server/port, the proxy settings in vscode are misconfigured, or a firewall is blocking requests. Details: RequestError: connect ECONNREFUSED 127.0.0.1:3333.

    1

    Please sign in or sign up for free to reply

    1. Commented 1 month ago

      Hey Fadli! Are you using WSL by chance? If so, try giving ::1 in place of http://localhost:3333 a shot. So, I think it'd be ::1:3333/movies. You can also try enabling mirroring mode in WSL, noted here:

      https://learn.microsoft.com/en-us/windows/wsl/networking#mirrored-mode-networking

      1

      Please sign in or sign up for free to reply

Playing Next Lesson In
seconds