@plurid/plurid-react-server 0.0.0-7 → 0.0.0-8

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.
@@ -18,6 +18,8 @@ import { routing } from "@plurid/plurid-engine";
18
18
 
19
19
  import { PluridProvider, PluridRouterStatic, serverComputeMetastate } from "@plurid/plurid-react";
20
20
 
21
+ import { minify } from "html-minifier";
22
+
21
23
  import React from "react";
22
24
 
23
25
  import { renderToString } from "react-dom/server";
@@ -154,7 +156,7 @@ const defaultStillerOptions = {
154
156
  ignore: []
155
157
  };
156
158
 
157
- const cleanTemplate = template => template.replace(/(?:\r\n|\r|\n)/g, " ").replace(/ +/g, " ").trim();
159
+ const cleanTemplate = template => minify(template);
158
160
 
159
161
  const resolveBackgroundStyle = store => {
160
162
  var _a;
@@ -24,6 +24,8 @@ var pluridEngine = require("@plurid/plurid-engine");
24
24
 
25
25
  var pluridReact = require("@plurid/plurid-react");
26
26
 
27
+ var htmlMinifier = require("html-minifier");
28
+
27
29
  var React = require("react");
28
30
 
29
31
  var server = require("react-dom/server");
@@ -202,7 +204,7 @@ const defaultStillerOptions = {
202
204
  ignore: []
203
205
  };
204
206
 
205
- const cleanTemplate = template => template.replace(/(?:\r\n|\r|\n)/g, " ").replace(/ +/g, " ").trim();
207
+ const cleanTemplate = template => htmlMinifier.minify(template);
206
208
 
207
209
  const resolveBackgroundStyle = store => {
208
210
  var _a;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@plurid/plurid-react-server",
3
- "version": "0.0.0-7",
3
+ "version": "0.0.0-8",
4
4
  "description": "React implementation of Plurid to view and explore the web in three dimensions with server-side rendering",
5
5
  "keywords": [
6
6
  "plurid",
@@ -71,63 +71,65 @@
71
71
  "body-parser": "^1.20.0",
72
72
  "compression": "^1.7.4",
73
73
  "detect-port": "^1.3.0",
74
- "express": "^4.17.3",
74
+ "express": "^4.18.1",
75
+ "html-minifier": "^4.0.0",
75
76
  "open": "^8.4.0"
76
77
  },
77
78
  "devDependencies": {
78
- "@apollo/client": "^3.5.10",
79
- "@babel/core": "^7.17.9",
79
+ "@apollo/client": "^3.6.9",
80
+ "@babel/core": "^7.18.6",
80
81
  "@plurid/elementql": "^0.0.0-1",
81
82
  "@plurid/elementql-client-react": "^0.0.0-1",
82
83
  "@plurid/plurid-data": "0.0.0-13",
83
84
  "@plurid/plurid-engine": "0.0.0-11",
84
- "@plurid/plurid-functions": "0.0.0-22",
85
+ "@plurid/plurid-functions": "0.0.0-25",
85
86
  "@plurid/plurid-functions-react": "0.0.0-5",
86
- "@plurid/plurid-icons-react": "0.0.0-3",
87
+ "@plurid/plurid-icons-react": "0.0.0-4",
87
88
  "@plurid/plurid-pubsub": "0.0.0-6",
88
- "@plurid/plurid-react": "0.0.0-19",
89
+ "@plurid/plurid-react": "0.0.0-21",
89
90
  "@plurid/plurid-themes": "0.0.0-2",
90
- "@plurid/plurid-ui-components-react": "0.0.0-11",
91
- "@plurid/plurid-ui-state-react": "0.0.0-2",
91
+ "@plurid/plurid-ui-components-react": "0.0.0-13",
92
+ "@plurid/plurid-ui-state-react": "0.0.0-3",
92
93
  "@redux-devtools/extension": "^3.2.2",
93
- "@rollup/plugin-node-resolve": "^13.2.1",
94
+ "@rollup/plugin-node-resolve": "^13.3.0",
94
95
  "@types/body-parser": "^1.19.2",
95
96
  "@types/compression": "^1.7.2",
96
97
  "@types/detect-port": "^1.3.2",
97
98
  "@types/express": "^4.17.13",
98
99
  "@types/hammerjs": "^2.0.41",
99
- "@types/jest": "^27.4.1",
100
- "@types/node": "^17.0.24",
101
- "@types/react": "^18.0.5",
102
- "@types/react-dom": "^18.0.1",
100
+ "@types/html-minifier": "^4.0.2",
101
+ "@types/jest": "^28.1.5",
102
+ "@types/node": "^18.0.4",
103
+ "@types/react": "^18.0.15",
104
+ "@types/react-dom": "^18.0.6",
103
105
  "@types/react-redux": "^7.1.24",
104
106
  "@types/react-stripe-elements": "^6.0.6",
105
107
  "@types/styled-components": "^5.1.25",
106
- "@typescript-eslint/eslint-plugin": "^5.19.0",
107
- "@typescript-eslint/parser": "^5.19.0",
108
+ "@typescript-eslint/eslint-plugin": "^5.30.6",
109
+ "@typescript-eslint/parser": "^5.30.6",
108
110
  "@zerollup/ts-transform-paths": "^1.7.18",
109
111
  "cross-fetch": "^3.1.5",
110
- "eslint": "^8.13.0",
111
- "graphql": "^16.3.0",
112
+ "eslint": "^8.19.0",
113
+ "graphql": "^16.5.0",
112
114
  "hammerjs": "^2.0.8",
113
- "jest": "^27.5.1",
114
- "jest-config": "^27.5.1",
115
- "react": "^18.0.0",
116
- "react-dom": "^18.0.0",
115
+ "jest": "^28.1.3",
116
+ "jest-config": "^28.1.3",
117
+ "react": "^18.2.0",
118
+ "react-dom": "^18.2.0",
117
119
  "react-helmet-async": "^1.3.0",
118
- "react-redux": "^8.0.0",
119
- "redux": "^4.1.2",
120
+ "react-redux": "^8.0.2",
121
+ "redux": "^4.2.0",
120
122
  "redux-thunk": "^2.4.1",
121
- "rollup": "^2.70.2",
123
+ "rollup": "^2.76.0",
122
124
  "rollup-plugin-peer-deps-external": "^2.2.4",
123
125
  "rollup-plugin-terser": "^7.0.2",
124
- "rollup-plugin-typescript2": "^0.31.2",
126
+ "rollup-plugin-typescript2": "^0.32.1",
125
127
  "styled-components": "^5.3.5",
126
- "ts-jest": "^27.1.4",
127
- "ts-node": "^10.7.0",
128
- "tslib": "^2.3.1",
128
+ "ts-jest": "^28.0.6",
129
+ "ts-node": "^10.9.1",
130
+ "tslib": "^2.4.0",
129
131
  "ttypescript": "^1.5.13",
130
- "typescript": "^4.6.3",
132
+ "typescript": "^4.7.4",
131
133
  "typescript-transform-paths": "^3.3.1"
132
134
  }
133
135
  }