@stoker-platform/web-app 0.5.242 → 0.5.245

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,28 @@
1
1
  # @stoker-platform/web-app
2
2
 
3
+ ## 0.5.245
4
+
5
+ ### Patch Changes
6
+
7
+ - fix: add development env file to web app
8
+
9
+ ## 0.5.244
10
+
11
+ ### Patch Changes
12
+
13
+ - feat: support NPM 12
14
+ - Updated dependencies
15
+ - @stoker-platform/node-client@0.5.103
16
+ - @stoker-platform/utils@0.5.89
17
+ - @stoker-platform/web-client@0.5.106
18
+
19
+ ## 0.5.243
20
+
21
+ ### Patch Changes
22
+
23
+ - Updated dependencies
24
+ - @stoker-platform/node-client@0.5.102
25
+
3
26
  ## 0.5.242
4
27
 
5
28
  ### Patch Changes
package/bin/build.js CHANGED
@@ -393,7 +393,12 @@ try {
393
393
  writeFileSync(file, transformed)
394
394
  }
395
395
  }
396
- cpSync(join(process.cwd(), ".env", `.env.${process.env.GCP_PROJECT}`), join(__dirname, "..", ".env"))
396
+ const projectEnvLines = readFileSync(join(process.cwd(), ".env", `.env.${process.env.GCP_PROJECT}`), "utf8").split(
397
+ "\n",
398
+ )
399
+ const isDebugTokenLine = (line) => line.startsWith("STOKER_FB_APP_CHECK_DEBUG_TOKEN=")
400
+ writeFileSync(join(__dirname, "..", ".env"), projectEnvLines.filter((line) => !isDebugTokenLine(line)).join("\n"))
401
+ writeFileSync(join(__dirname, "..", ".env.development"), projectEnvLines.filter(isDebugTokenLine).join("\n"))
397
402
  if (process.env.SKIP_ESLINT_DISABLE) {
398
403
  await appendFile(join(__dirname, "..", ".env"), "\nSKIP_ESLINT_DISABLE=true")
399
404
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stoker-platform/web-app",
3
- "version": "0.5.242",
3
+ "version": "0.5.245",
4
4
  "type": "module",
5
5
  "license": "SEE LICENSE IN LICENSE.md",
6
6
  "scripts": {
@@ -51,9 +51,9 @@
51
51
  "@radix-ui/react-tooltip": "^1.2.16",
52
52
  "@react-google-maps/api": "^2.20.8",
53
53
  "@sentry/react": "^10.70.0",
54
- "@stoker-platform/node-client": "0.5.101",
55
- "@stoker-platform/utils": "0.5.88",
56
- "@stoker-platform/web-client": "0.5.105",
54
+ "@stoker-platform/node-client": "0.5.103",
55
+ "@stoker-platform/utils": "0.5.89",
56
+ "@stoker-platform/web-client": "0.5.106",
57
57
  "@tanstack/react-table": "^8.21.3",
58
58
  "@types/react": "18.3.13",
59
59
  "@types/react-dom": "18.3.1",
@@ -98,7 +98,7 @@
98
98
  },
99
99
  "engines": {
100
100
  "node": ">=22",
101
- "npm": "11"
101
+ "npm": ">=12"
102
102
  },
103
103
  "devDependencies": {
104
104
  "@types/react-helmet": "^6.1.11",
package/vite.config.ts CHANGED
@@ -1,12 +1,19 @@
1
1
  import { defineConfig, loadEnv } from "vite"
2
2
  import react from "@vitejs/plugin-react"
3
3
  import eslint from "vite-plugin-eslint"
4
- import { join, resolve } from "node:path"
4
+ import { createRequire } from "node:module"
5
+ import { dirname, join, resolve } from "node:path"
5
6
  import { pathToFileURL } from "node:url"
6
7
  import { VitePWA } from "vite-plugin-pwa"
7
8
  import { tryPromise } from "@stoker-platform/node-client"
8
9
  import { watch } from "fs"
9
10
 
11
+ const require = createRequire(import.meta.url)
12
+
13
+ function resolvePackageRoot(name: string) {
14
+ return dirname(require.resolve(`${name}/package.json`))
15
+ }
16
+
10
17
  export default defineConfig(async ({ mode }) => {
11
18
  const env = loadEnv(mode, import.meta.dirname, "")
12
19
  const skipEslintDisable = (env.SKIP_ESLINT_DISABLE || process.env.SKIP_ESLINT_DISABLE) === "true"
@@ -82,8 +89,8 @@ export default defineConfig(async ({ mode }) => {
82
89
  resolve: {
83
90
  alias: {
84
91
  "@": resolve(import.meta.dirname, "./src"),
85
- react: skipEslintDisable ? resolve(import.meta.dirname, "./node_modules/react") : "react",
86
- "react-dom": skipEslintDisable ? resolve(import.meta.dirname, "./node_modules/react-dom") : "react-dom",
92
+ react: skipEslintDisable ? resolvePackageRoot("react") : "react",
93
+ "react-dom": skipEslintDisable ? resolvePackageRoot("react-dom") : "react-dom",
87
94
  },
88
95
  },
89
96
  optimizeDeps: {