Releases: SuiteBee/NorthWindWeb
Releases · SuiteBee/NorthWindWeb
Version 0.1.0
Initial release for Northwind Web
Usage
Important
Login credentials
username: adodsworth
password: Northwind1
Steps to run locally as Release
Warning
Serving the release build will also require the API back-end to be running the release executable
This method should have the least number of dependencies required to run
Steps
Prerequisites
- Download latest release of NorthWindAPI.NET
- Install npm package local-web-server
$ npm install -g local-web-server
- Download the attached release zip below
Start API
- Extract files from NorthWindAPI release
- Open NorthWindAPI.exe and leave running
- This will start the API listening on port 5000
Start web server
- Extract files from attached release below
- Open a command prompt or bash window
- Navigate to the location of the extracted release
- Execute the following
$ ws --spa index.html
- This will start the web server and display the ports where it is served
- Open browser and navigate to
http://localhost:8000/
- Login with supplied credentials (token is valid for 30 minutes)
Steps to build from source
Warning
Building from source also requires the API back-end to also be built from source
This method will require an IDE like visual studio and potentially some .NET runtimes or other dependencies to build
Steps
Prerequisites
- Visual Studio or the .NET CLI
- IIS Express
- React development environment
Start API
- Open NorthWindAPI.sln
- Run targeting IIS Express
- Browser will open and display the OpenAPI specification page
- Take note of the port within this URL
Start web server
- Within your react dev environment
- Run the following command
npm run dev
- Browser will open to the login page
- Login with supplied credentials (token is valid for 30 minutes)
Pitfalls
If the login page displays an error questioning if the API server is running, verify the URL port in
NorthWindWeb/src/components/api/NorthWindClient.jsx
matches the one that the OpenAPI spec is displayed at
If it still doesn't work you may need to add the port that the site is being served on to the CORS whitelist in
NorthWindAPI.NET\Program.cs