@@ -233,11 +233,11 @@ To check the current Docker context, use:
233
233
docker context show
234
234
```
235
235
236
- ## Recreating frontend static resources (GDS & MoJ templates )
236
+ ## Recreating frontend static resources (CCMS stylesheets )
237
237
238
238
> ** _ INFORMATION:_ ** When cloning this project for the first time, you do not need
239
239
> to run gulp as the static resources should already be created within the project.
240
- > This tool is just incase you wish to recreate them.
240
+ > This tool is just in case you wish to recreate them.
241
241
242
242
To provide a clean way of recreating the static resources, a gulp workflow has been implemented. This
243
243
helps automate the creation of frontend static resources when new versions of frontend toolkits
@@ -247,8 +247,7 @@ browser performance for the end user.
247
247
### Prerequisites
248
248
249
249
In order to download/recompile frontend static resources, you will need to have ` npm ` installed.
250
- This will be used to manage the GOVUK and MoJ frontends as a package manager. It will also be used to
251
- download the dev dependencies required to compile the various resources.
250
+ It will also be used to download the dev dependencies required to compile the various resources.
252
251
253
252
With ` npm ` installed on your machine, you will need to ensure you have ` gulp ` installed on your
254
253
system globally rather than at project level.
@@ -274,54 +273,16 @@ npm install
274
273
275
274
Recreating the frontend resources can be done by just running gulp.
276
275
277
- There are three tasks defined in the ` gulpfile.js ` :
278
-
279
- | Task | Description |
280
- | -----------------| --------------------------------------------------------------------|
281
- | default | Runs all the below tasks |
282
- | copyGOVUKAssets | Copies all the GOV UK Frontend assets from ` node_modules ` |
283
- | copyMoJAssets | Copies and compiles of the MoJ Frontend assets from ` node_modules ` |
284
-
285
- You can also view all the available tasks using the command:
286
- ``` shell
287
- # Whilst in the project directory
288
- gulp --tasks
289
- ```
276
+ There is just one task defined in ` gulpfile.js ` called ` default ` . When that task runs,
277
+ it will re-compile all the ` .scss ` files within the project into minified stylesheets, which are
278
+ then stored in ` src/main/resources/static/ccms ` .
290
279
291
280
To run the default task, you can just run gulp without any additional parameters:
292
281
``` shell
293
282
# Whilst in the project directory
294
283
gulp
295
284
```
296
285
297
- To run a specific task, define the name of the task:
298
- ``` shell
299
- # Whilst in the project directory
300
- gulp copyGOVUKAssets
301
- gulp copyMoJAssets
302
- ```
303
-
304
- ### Updating the various frontend toolkits
305
-
306
- To change which version of the toolkit is downloaded, check the file ` ./package.json ` . From this
307
- file, change the
308
- version number to whichever version you require.
309
-
310
- - To check what versions are available for the GOV UK Frontend,
311
- go [ here] ( https://www.npmjs.com/package/govuk-frontend ) .
312
- - To check what versions are available for the MoJ UK Frontend,
313
- go [ here] ( https://www.npmjs.com/package/@ministryofjustice/frontend ) .
314
-
315
- If a version has been modified within this file, you will need to download the new version using
316
- ` npm ` , and then copy the new files to the Spring Boot resources folder using gulp as described above.
317
-
318
- ``` sh
319
- # Whilst in the project directory
320
- npm install
321
- # Runs the default task as described below
322
- gulp
323
- ```
324
-
325
286
## Snyk code analysis (CI/CD)
326
287
This project publishes vulnerability scans to the [ LAA Snyk Dashboard (Google SSO)] ( https://app.snyk.io/org/legal-aid-agency ) .
327
288
0 commit comments