Skip to content

Latest commit

 

History

History

go

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Go with Nx

standalone application

An example repository showing how to use Go with Nx.

What's inside

This repositry contains:

  • A Go Todo Application (API Server)
  • A Go Todo Library
  • Unit tests for the API Server

How to run it

Build

To build the application you run this command at the root of your workspace.

npx nx build

Serve

To serve the application, you run this command at the root of your workspace.

npx nx serve

Then you can navigate to http://localhost:8080/api/todos to your current list of todos.

All other API endpoints are at http://localhost:8080/api/todo. It uses HTTP verbs to determine the action to take. Only GET, POST, PUT, and DELETE are supported. Optionally, you can pass a query parameter id to specify which todo to act on.

Test

To run the unit test for the application, you run this command at the root of your workspace.

npx nx test

Learn more