nails-boilerplate 0.12.2 → 0.12.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,14 @@
1
+ const bodyParser = require('body-parser');
2
+
1
3
  /**
2
4
  * Singleton express application.
3
5
  */
4
6
  var express = require('express');
5
7
  var app = express();
8
+ // Parse application/x-www-form-urlencoded
9
+ app.use(bodyParser.urlencoded({ extended: false }));
10
+ // Parse application/json
11
+ app.use(bodyParser.json());
6
12
  module.exports = app;
7
13
 
8
14
  app.Router = express.Router;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nails-boilerplate",
3
- "version": "0.12.2",
3
+ "version": "0.12.3",
4
4
  "description": "A node.js webserver scaffold",
5
5
  "main": "index.js",
6
6
  "bin": {
@@ -25,6 +25,7 @@
25
25
  "dependencies": {
26
26
  "@babel/core": "*",
27
27
  "@babel/preset-react": "*",
28
+ "body-parser": "^1.20.2",
28
29
  "ejs": "*",
29
30
  "express": "*",
30
31
  "express-react-views": "*",