|
1 | | -# CDL Website 2.0 |
| 1 | +# The new CivicDataLab website |
| 2 | + |
| 3 | +## Architecture/Tech Stack |
| 4 | + |
| 5 | +🖼️ Framework: [Gatsby](https://www.gatsbyjs.com/) |
| 6 | +🎨 Styling: [styled-components](https://styled-components.com/) |
| 7 | +✏️ Content source: markdown files inside the `content` folder |
| 8 | +📊 Analytics: [Plausible](https://plausible.io/) |
| 9 | + |
| 10 | +## Run it locally |
| 11 | + |
| 12 | +Prerequisites: NodeJS must be installed on your machine. |
| 13 | +1. Clone this repo. |
| 14 | +2. Run `npm start` command inside the root folder of the project. |
| 15 | +3. To build the website, run `npm run build`. |
| 16 | +4. To run the local build, run the following command: `npm run serve`. |
| 17 | + |
| 18 | +## Adding/Updating content |
| 19 | + |
| 20 | +### How to add a bandhu |
| 21 | +1. Create a new branch. |
| 22 | +2. Navigate to `content/team` folder. |
| 23 | +3. Create a new folder with the bandhu's first name in lowercase. Include the last name if there's another bandhu with the same first name. |
| 24 | +4. Create an index.md file inside the folder and the details like in the below template: |
| 25 | +``` |
| 26 | +--- |
| 27 | +name: |
| 28 | +role: |
| 29 | +description: |
| 30 | +quote: |
| 31 | +medium: |
| 32 | +github: |
| 33 | +twitter: |
| 34 | +linkedin: |
| 35 | +behance: |
| 36 | +image: image.jpg |
| 37 | +sectors: Sector 1, Sector 2 |
| 38 | +projects: Project 1, Project 2 |
| 39 | +--- |
| 40 | +``` |
| 41 | +5. If the description has more than one paragraph, add it is raw text below the metadata of the `index.md` file. |
| 42 | +``` |
| 43 | +--- |
| 44 | +name: |
| 45 | +role: |
| 46 | +description: |
| 47 | +quote: |
| 48 | +medium: |
| 49 | +github: |
| 50 | +twitter: |
| 51 | +linkedin: |
| 52 | +behance: |
| 53 | +image: image.jpg |
| 54 | +sectors: Sector 1, Sector 2 |
| 55 | +projects: Project 1, Project 2 |
| 56 | +--- |
| 57 | +
|
| 58 | +Paragraph 1 of the bandhu's description. |
| 59 | +
|
| 60 | +This is paragraph 2. |
| 61 | +``` |
| 62 | +6. Follow the same pattern for updating an existing bandhu's details. |
| 63 | +7. Create a pull request when you are done. |
| 64 | + |
| 65 | + |
| 66 | +### How to add a sector |
| 67 | +1. Create a new branch. |
| 68 | +2. Navigate to `content/work/` folder. |
| 69 | +3. Create a new folder with the sector's name in lowercase and without spaces. |
| 70 | +4. Create an `index.md` file inside the folder and add the details like in the below template: |
| 71 | +``` |
| 72 | +--- |
| 73 | +name: |
| 74 | +description: |
| 75 | +image: ./image.jpg |
| 76 | +color: '#FBC740' |
| 77 | +type: sector |
| 78 | +projects: Project 1, Project 2 |
| 79 | +events: |
| 80 | + - { |
| 81 | + url: '', |
| 82 | + title: '', |
| 83 | + project: '', |
| 84 | + type: '' |
| 85 | + } |
| 86 | + - { |
| 87 | + url: '', |
| 88 | + title: '', |
| 89 | + project: '', |
| 90 | + type: '' |
| 91 | + } |
| 92 | +--- |
| 93 | +
|
| 94 | +``` |
| 95 | +5. The sector's image must be inside the same folder and its name should match what's written in the `index.md` file's metadata. |
| 96 | +6. To update an existing sector, simply edit the metadata of its `index.md` file. |
| 97 | +7. Create a pull request with your changes. |
| 98 | + |
| 99 | +### How to add a project |
| 100 | +1. Create a new branch. |
| 101 | +2. Navigate to `content/work/sectorone` folder, where `sectorone` is the name of the sector to which the project belongs. |
| 102 | +3. Create a new folder with the project's name in lowercase and without spaces. |
| 103 | +4. Create an `index.md` file inside the folder and add the details like in the below template: |
| 104 | +``` |
| 105 | +--- |
| 106 | +name: |
| 107 | +image: ./image.jpg |
| 108 | +summary: A 1-2 lines summary here. |
| 109 | +context: |
| 110 | +solution: |
| 111 | +aim: |
| 112 | +url: |
| 113 | +twitter: |
| 114 | +linkedin: |
| 115 | +github: |
| 116 | +newsletter: |
| 117 | +sector: Sector 1 |
| 118 | +type: project |
| 119 | +resources: |
| 120 | + - { |
| 121 | + link: '', |
| 122 | + title: '', |
| 123 | + type: '' |
| 124 | + } |
| 125 | + - { |
| 126 | + link: '', |
| 127 | + title: '', |
| 128 | + type: '' |
| 129 | + } |
| 130 | +--- |
| 131 | +
|
| 132 | +``` |
| 133 | +5. The project's image must be inside the same folder and its name should match what's written in the `index.md` file's metadata. |
| 134 | +6. To update an existing project, simply edit the metadata of its `index.md` file. |
| 135 | +7. Create a pull request with your changes. |
| 136 | + |
| 137 | +### How to add a job opening |
| 138 | +1. Create a new branch. |
| 139 | +2. Navigate to `content/openings` folder. |
| 140 | +3. Create a markdown file with its name as the title of the job in lowercase. |
| 141 | +4. Add a url where the job post is listed and the proper title of the job inside the markdown file created in the previous step. |
| 142 | +``` |
| 143 | +--- |
| 144 | +title: Front-end Engineer |
| 145 | +url: https://angel.co/company/civicdatalab/jobs/1279092-front-end-engineer |
| 146 | +--- |
| 147 | +``` |
| 148 | +5. Create a pull request with the changes. |
0 commit comments