Merge branch 'dev' into dev2

This commit is contained in:
MichaelDvP
2023-11-21 11:24:04 +01:00
13 changed files with 131 additions and 123 deletions

View File

@@ -29,7 +29,7 @@
"@table-library/react-table-library": "4.1.7",
"@types/imagemin": "^8.0.4",
"@types/lodash-es": "^4.17.11",
"@types/node": "^20.9.1",
"@types/node": "^20.9.2",
"@types/react": "^18.2.37",
"@types/react-dom": "^18.2.15",
"@types/react-router-dom": "^5.3.3",
@@ -55,7 +55,7 @@
"@typescript-eslint/eslint-plugin": "^6.11.0",
"@typescript-eslint/parser": "^6.11.0",
"concurrently": "^8.2.2",
"eslint": "^8.53.0",
"eslint": "^8.54.0",
"eslint-config-airbnb": "^19.0.4",
"eslint-config-airbnb-typescript": "^17.1.0",
"eslint-config-prettier": "^9.0.0",

View File

@@ -498,8 +498,8 @@ function createStructureReader(structure, firstId) {
key === '__proto__'
? '__proto_:r()'
: validName.test(key)
? key + ':r()'
: '[' + JSON.stringify(key) + ']:r()'
? key + ':r()'
: '[' + JSON.stringify(key) + ']:r()'
)
.join(',') +
'})}'

View File

@@ -5,7 +5,6 @@ import viteImagemin from 'vite-plugin-imagemin';
import { visualizer } from 'rollup-plugin-visualizer';
export default defineConfig(({ command, mode }) => {
// standalone build for development - runs the server
if (command === 'serve') {
console.log('Preparing for standalone build with server, mode=' + mode);
return {
@@ -30,9 +29,17 @@ export default defineConfig(({ command, mode }) => {
};
}
if (command === 'build' && mode === 'hosted') {
return {
plugins: [preact(), viteTsconfigPaths()],
build: {
chunkSizeWarningLimit: 1024
}
};
}
// production build, both for hosted and building the firmware
if (command === 'build') {
console.log('Preparing for production build, mode is ' + mode);
return {
plugins: [
preact(),
@@ -79,11 +86,7 @@ export default defineConfig(({ command, mode }) => {
build: {
// target: 'es2022',
outDir: 'dist',
reportCompressedSize: false,
chunkSizeWarningLimit: 1024,
sourcemap: false,
manifest: false,
minify: 'terser',
terserOptions: {
compress: {
@@ -109,16 +112,6 @@ export default defineConfig(({ command, mode }) => {
nameCache: null,
safari10: false,
toplevel: false
},
rollupOptions: {
// Ignore "use client" waning since we are not using SSR
onwarn(warning, warn) {
if (warning.code === 'MODULE_LEVEL_DIRECTIVE' && warning.message.includes(`"use client"`)) {
return;
}
warn(warning);
}
}
}
};

View File

@@ -746,10 +746,10 @@ __metadata:
languageName: node
linkType: hard
"@eslint/js@npm:8.53.0":
version: 8.53.0
resolution: "@eslint/js@npm:8.53.0"
checksum: a372d55aa2bbe0d9399acc8de3c892dcfe507fd914d29fde6826ae54a13452619be626aa7eb70b1ec4d4da5302b6ed8e8ac9bf1f830003f15c0ad56c30b4f520
"@eslint/js@npm:8.54.0":
version: 8.54.0
resolution: "@eslint/js@npm:8.54.0"
checksum: 4d491ff234cd94b54499428cb3435623270ff8cc59950e13e6e1ac2fa350ec60502dac7bfd4f486523fee65ad7a358034570fe776b81b14dbfe5525d1e26e1d8
languageName: node
linkType: hard
@@ -1478,12 +1478,12 @@ __metadata:
languageName: node
linkType: hard
"@types/node@npm:^20.9.1":
version: 20.9.1
resolution: "@types/node@npm:20.9.1"
"@types/node@npm:^20.9.2":
version: 20.9.2
resolution: "@types/node@npm:20.9.2"
dependencies:
undici-types: "npm:~5.26.4"
checksum: b2b3f9ee31db63ccd3d48e5597d359c3385879679f37a749e473b47068aae181d0e280f39f153d75ce704640b3ec09d029aecd2a686e5658fb866254dc7e781b
checksum: 8bab2870bfc02efc988c53dfb0149634f8feb824132cc7f20b36f3d55d89ef893e3a43d545524a5cb3a284f4ce68ae4181d75a4a39cee6b79c586d719e6b7461
languageName: node
linkType: hard
@@ -1745,7 +1745,7 @@ __metadata:
"@table-library/react-table-library": "npm:4.1.7"
"@types/imagemin": "npm:^8.0.4"
"@types/lodash-es": "npm:^4.17.11"
"@types/node": "npm:^20.9.1"
"@types/node": "npm:^20.9.2"
"@types/react": "npm:^18.2.37"
"@types/react-dom": "npm:^18.2.15"
"@types/react-router-dom": "npm:^5.3.3"
@@ -1754,7 +1754,7 @@ __metadata:
alova: "npm:^2.13.1"
async-validator: "npm:^4.2.5"
concurrently: "npm:^8.2.2"
eslint: "npm:^8.53.0"
eslint: "npm:^8.54.0"
eslint-config-airbnb: "npm:^19.0.4"
eslint-config-airbnb-typescript: "npm:^17.1.0"
eslint-config-prettier: "npm:^9.0.0"
@@ -3842,14 +3842,14 @@ __metadata:
languageName: node
linkType: hard
"eslint@npm:^8.53.0":
version: 8.53.0
resolution: "eslint@npm:8.53.0"
"eslint@npm:^8.54.0":
version: 8.54.0
resolution: "eslint@npm:8.54.0"
dependencies:
"@eslint-community/eslint-utils": "npm:^4.2.0"
"@eslint-community/regexpp": "npm:^4.6.1"
"@eslint/eslintrc": "npm:^2.1.3"
"@eslint/js": "npm:8.53.0"
"@eslint/js": "npm:8.54.0"
"@humanwhocodes/config-array": "npm:^0.11.13"
"@humanwhocodes/module-importer": "npm:^1.0.1"
"@nodelib/fs.walk": "npm:^1.2.8"
@@ -3886,7 +3886,7 @@ __metadata:
text-table: "npm:^0.2.0"
bin:
eslint: bin/eslint.js
checksum: e305a71ce2b9a8631b293266fe53e346c76f28bc8d004af33f10e537cf133db1fb87af3599376e70ed6e0f89a78be10c4f08ddd0c1c9c0c497cd143b4a270420
checksum: 379827964fd7885a4d48611a5237cf5c534eff0ad3d0c1a1d6a14d52ac6758f4efdccd924c9bb3a9aa4dc80a3446d48dc49f61733cd5bd5f74419d0240970e7b
languageName: node
linkType: hard