Quick starter template for DTS projects making use of one of our commonly-used Next.js setups.
This template uses the basic Next.js create-next-app
bootstrap template.
This project uses
- Next.js
- Tailwind CSS
- Jest for unit testing
- Cypress for end-to-end testing.
Search "next-template", replace in package.json, run "npm i" in terminal and confirm package-lock.json is updated
In order to use any licence with your repository, you will need DG approval. Your PO should send an email to the DG resposible for the product to request a licence ("MIT" or other).
Until you have approval from your DG your LICENCE file should only state the following (updating the year)
All Rights Reserved
Copyright (c) Her Majesty the Queen in Right of Canada, as represented by the Employment and Social Development Canada, 2021
Once approved by the DG, the copyright statement must still be included in the LICENCE.
In the helm template, the application name is next-template. this will need to be changed by the current application name.
For every Kubernetes cluster, a context.sh file needs to be defined. For example, one might be called context-dev.sh and the other context-prod.sh.
For more information, please visit the DTS SRE deployment templates.
Have at least one person reviewing each PR before it can be merged. Each branch should be prefixed with the ID of the relevant ADO task. Eg. "379-update-readme"
First, run the development server:
npm run dev
# or
yarn dev
Open http://localhost:3000 with your browser to see the result.
You can start editing the page by modifying pages/index.js
. The page auto-updates as you edit the file.
API routes can be accessed on http://localhost:3000/api/hello. This endpoint can be edited in pages/api/hello.js
.
The pages/api
directory is mapped to /api/*
. Files in this directory are treated as API routes instead of React pages.
To learn more about Next.js, take a look at the following resources:
- Next.js Documentation - learn about Next.js features and API.
- Learn Next.js - an interactive Next.js tutorial.
You can check out the Next.js GitHub repository - your feedback and contributions are welcome!