hof 20.1.7 → 20.1.9

Sign up to get free protection for your applications and to get access to all the features.
@@ -116,7 +116,7 @@ module.exports = config => {
116
116
 
117
117
  if (process.env.HOF_SANDBOX === 'true') {
118
118
  const rootDir = require('path').resolve(__dirname, '../../../');
119
- ignored.push(`${rootDir}/frontend/govuk-template/govuk_template.html`);
119
+ ignored.push(`${rootDir}/frontend/govuk-template/govuk_template_generated.html`);
120
120
  watchLocation = [rootDir, '.'];
121
121
  }
122
122
 
@@ -53,6 +53,18 @@ module.exports = {
53
53
 
54
54
  base64decode(value) {
55
55
  return Buffer.from(value, 'base64').toString();
56
+ },
57
+
58
+ ukPostcode(value) {
59
+ if (typeof value !== 'string' || value === '') {
60
+ return value;
61
+ }
62
+
63
+ const postcode = this.uppercase(this.removespaces(value));
64
+ const firstPart = postcode.slice(0, -3);
65
+ const secondPart = postcode.slice(-3);
66
+
67
+ return `${firstPart} ${secondPart}`;
56
68
  }
57
69
 
58
70
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "hof",
3
3
  "description": "A bootstrap for HOF projects",
4
- "version": "20.1.7",
4
+ "version": "20.1.9",
5
5
  "license": "MIT",
6
6
  "main": "index.js",
7
7
  "author": "HomeOffice",