roads-starter
v2.3.1
Published
A starter project for building websites with roads and roads-api
Downloads
10
Readme
roads-starter
Getting Started
Trying the example
- Pop open the
config
folder and make duplicates of every file in there. Remove the word "example" from the copies. - In each of those new non-example files, fill in the appropriate values.
- From the example folder run
./docker-compose.sh up
to test the example
Building a new project
- Copy the contents of the example folder to a new project
- Create a package.json file with a dependency on roads-starter (remember to make it private if you need to!)
- Update all
../index.js
references (such as the one in server.js) to reference roads-starter - Pop open the
config
folder and make duplicates of every file in there. Remove the word "example" from the copies. - In each of those new non-example files, fill in the appropriate values.
- Run
./docker-compose.sh up
to test the copied example - Add new API routes in the API folder and reference them via server.js.
- Add new web routes in the privateRoutes.js (for routes that access private data or endpoints) or publicRoutes.js (for routes that can safely be sent to the client and executed in the browser)