@salesforce/webapp-template-app-react-sample-b2x-experimental 1.84.0 → 1.85.0
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/dist/.a4drules/skills/{webapp-react-add-component → webapp-react}/SKILL.md +5 -3
- package/dist/.a4drules/skills/{webapp-react-add-component → webapp-react}/implementation/header-footer.md +8 -0
- package/dist/.a4drules/skills/{webapp-react-add-component → webapp-react}/implementation/page.md +8 -7
- package/dist/.a4drules/skills/webapp-ui-ux/SKILL.md +11 -8
- package/dist/.a4drules/webapp-react.md +54 -0
- package/dist/CHANGELOG.md +16 -0
- package/dist/README.md +24 -0
- package/dist/force-app/main/default/data/Property_Image__c.json +1 -1
- package/dist/force-app/main/default/data/Property_Listing__c.json +1 -1
- package/dist/force-app/main/default/data/prepare-import-unique-fields.js +85 -0
- package/dist/force-app/main/default/permissionsets/Property_Management_Access.permissionset-meta.xml +0 -7
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/index.html +6 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/package.json +3 -3
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/api/applicationApi.ts +9 -9
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/api/graphql-operations-types.ts +296 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/api/graphqlClient.ts +12 -7
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/api/maintenanceRequestApi.ts +50 -38
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/api/propertyDetailGraphQL.ts +50 -102
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/api/propertyListingGraphQL.ts +211 -43
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/api/userApi.ts +43 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/appLayout.tsx +9 -208
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/assets/icons/appliances.svg +13 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/assets/icons/electrical.svg +39 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/assets/icons/hvac.svg +78 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/assets/icons/pest.svg +5 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/assets/icons/plumbing.svg +7 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/assets/icons/zen-logo.svg +5 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/components/MaintenanceRequestIcon.tsx +46 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/components/NavMenu.tsx +53 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/components/PropertyListingCard.tsx +55 -58
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/components/PropertyMap.tsx +93 -11
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/components/PropertySearchFilters.tsx +315 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/components/StatusBadge.tsx +36 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/components/TopBar.tsx +107 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/hooks/usePropertyAddresses.ts +2 -2
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/hooks/usePropertyListingAmenities.ts +55 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/hooks/usePropertyListingPriceRange.ts +64 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/hooks/usePropertyListingSearch.ts +14 -5
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/hooks/usePropertyMapMarkers.ts +54 -11
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/hooks/usePropertyPrimaryImages.ts +1 -1
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/pages/Application.tsx +42 -39
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/pages/Contact.tsx +10 -10
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/pages/Dashboard.tsx +64 -91
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/pages/HelpCenter.tsx +1 -1
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/pages/Home.tsx +19 -9
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/pages/Maintenance.tsx +79 -100
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/pages/NotFound.tsx +1 -1
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/pages/PropertyDetails.tsx +62 -47
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/pages/PropertyListings.tsx +3 -3
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/pages/PropertySearch.tsx +230 -34
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/routes.tsx +10 -1
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/styles/global.css +64 -0
- package/dist/force-app/main/default/webapplications/appreactsampleb2x/src/utils/geocode.ts +30 -5
- package/dist/package.json +1 -1
- package/dist/setup-cli.mjs +271 -0
- package/package.json +1 -1
- /package/dist/.a4drules/skills/{webapp-react-add-component → webapp-react}/implementation/component.md +0 -0
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Geocode an address to lat/lng using OpenStreetMap Nominatim (free, no API key).
|
|
3
|
-
* Results are cached in memory
|
|
3
|
+
* Results are cached in memory (including 200 responses with empty results).
|
|
4
|
+
* Allows limited parallel in-flight requests (maxConcurrent).
|
|
4
5
|
*/
|
|
5
6
|
|
|
6
|
-
const
|
|
7
|
+
const CACHED_EMPTY = Symbol("cached empty geocode");
|
|
8
|
+
type CacheEntry = { lat: number; lng: number } | typeof CACHED_EMPTY;
|
|
9
|
+
|
|
10
|
+
const CACHE = new Map<string, CacheEntry>();
|
|
7
11
|
const MAX_CONCURRENT = 6;
|
|
8
12
|
let inFlight = 0;
|
|
9
13
|
const queue: Array<() => void> = [];
|
|
@@ -32,11 +36,26 @@ export interface GeocodeResult {
|
|
|
32
36
|
lng: number;
|
|
33
37
|
}
|
|
34
38
|
|
|
39
|
+
/**
|
|
40
|
+
* Extracts "State Zip" from a US-style full address (e.g. "123 Main St, Unit 4B, Los Angeles, CA 90028" → "CA 90028").
|
|
41
|
+
* Used as a fallback when geocoding the full address fails.
|
|
42
|
+
*/
|
|
43
|
+
export function getStateZipFromAddress(address: string): string {
|
|
44
|
+
const parts = address
|
|
45
|
+
.split(",")
|
|
46
|
+
.map((p) => p.trim())
|
|
47
|
+
.filter(Boolean);
|
|
48
|
+
if (parts.length >= 1) {
|
|
49
|
+
return parts[parts.length - 1];
|
|
50
|
+
}
|
|
51
|
+
return address.trim();
|
|
52
|
+
}
|
|
53
|
+
|
|
35
54
|
export async function geocodeAddress(address: string): Promise<GeocodeResult | null> {
|
|
36
55
|
const key = address.trim().replace(/\s+/g, " ").toLowerCase();
|
|
37
56
|
if (!key) return null;
|
|
38
57
|
const cached = CACHE.get(key);
|
|
39
|
-
if (cached) return cached;
|
|
58
|
+
if (cached !== undefined) return cached === CACHED_EMPTY ? null : cached;
|
|
40
59
|
|
|
41
60
|
await acquire();
|
|
42
61
|
try {
|
|
@@ -50,10 +69,16 @@ export async function geocodeAddress(address: string): Promise<GeocodeResult | n
|
|
|
50
69
|
if (!res.ok) return null;
|
|
51
70
|
const data = (await res.json()) as Array<{ lat?: string; lon?: string }>;
|
|
52
71
|
const first = data?.[0];
|
|
53
|
-
if (!first?.lat || !first?.lon)
|
|
72
|
+
if (!first?.lat || !first?.lon) {
|
|
73
|
+
CACHE.set(key, CACHED_EMPTY);
|
|
74
|
+
return null;
|
|
75
|
+
}
|
|
54
76
|
const lat = Number(first.lat);
|
|
55
77
|
const lng = Number(first.lon);
|
|
56
|
-
if (Number.isNaN(lat) || Number.isNaN(lng))
|
|
78
|
+
if (Number.isNaN(lat) || Number.isNaN(lng)) {
|
|
79
|
+
CACHE.set(key, CACHED_EMPTY);
|
|
80
|
+
return null;
|
|
81
|
+
}
|
|
57
82
|
const result = { lat, lng };
|
|
58
83
|
CACHE.set(key, result);
|
|
59
84
|
return result;
|
package/dist/package.json
CHANGED
|
@@ -0,0 +1,271 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* One-command setup: login, deploy, data import, GraphQL schema/codegen, web app build.
|
|
4
|
+
* Provided by the property management feature. Run from the SFDX project root (e.g. dist/).
|
|
5
|
+
*
|
|
6
|
+
* Usage:
|
|
7
|
+
* node setup-cli.mjs --target-org <alias> # run all steps
|
|
8
|
+
* node setup-cli.mjs --target-org afv5 --skip-login
|
|
9
|
+
* node setup-cli.mjs --target-org afv5 --skip-data --skip-webapp-build
|
|
10
|
+
* node setup-cli.mjs --target-org myorg --app appreactsampleb2x # when multiple web apps
|
|
11
|
+
*
|
|
12
|
+
* Steps (in order):
|
|
13
|
+
* 1. login — sf org login web only if org not already connected (skip with --skip-login)
|
|
14
|
+
* 2. deploy — sf project deploy start --target-org <alias>
|
|
15
|
+
* 3. permset — sf org assign permset (default: Property_Management_Access; override with --permset)
|
|
16
|
+
* 4. data — prepare unique fields + sf data import tree (skipped if no data-plan.json)
|
|
17
|
+
* 5. graphql — (in webapp) npm run graphql:schema then npm run graphql:codegen
|
|
18
|
+
* 6. webapp — (in webapp) npm install && npm run build
|
|
19
|
+
* 7. dev — (in webapp) npm run dev — launch dev server (skip with --skip-dev)
|
|
20
|
+
*/
|
|
21
|
+
|
|
22
|
+
import { spawnSync } from "node:child_process";
|
|
23
|
+
import { readdirSync, existsSync } from "node:fs";
|
|
24
|
+
import { resolve, dirname, basename } from "node:path";
|
|
25
|
+
import { fileURLToPath } from "node:url";
|
|
26
|
+
|
|
27
|
+
const __dirname = dirname(fileURLToPath(import.meta.url));
|
|
28
|
+
/** SFDX project root: when run from dist/, the script lives in dist/ and force-app is under dist/ */
|
|
29
|
+
const ROOT = __dirname;
|
|
30
|
+
const WEBAPPLICATIONS_DIR = resolve(ROOT, "force-app/main/default/webapplications");
|
|
31
|
+
const DATA_DIR = resolve(ROOT, "force-app/main/default/data");
|
|
32
|
+
const DATA_PLAN = resolve(DATA_DIR, "data-plan.json");
|
|
33
|
+
const PREPARE_SCRIPT = resolve(DATA_DIR, "prepare-import-unique-fields.js");
|
|
34
|
+
|
|
35
|
+
function parseArgs() {
|
|
36
|
+
const args = process.argv.slice(2);
|
|
37
|
+
let targetOrg = null;
|
|
38
|
+
let appName = null;
|
|
39
|
+
let permsetName = "Property_Management_Access";
|
|
40
|
+
const flags = {
|
|
41
|
+
skipLogin: false,
|
|
42
|
+
skipDeploy: false,
|
|
43
|
+
skipPermset: false,
|
|
44
|
+
skipData: false,
|
|
45
|
+
skipGraphql: false,
|
|
46
|
+
skipWebappBuild: false,
|
|
47
|
+
skipDev: false,
|
|
48
|
+
};
|
|
49
|
+
for (let i = 0; i < args.length; i++) {
|
|
50
|
+
if (args[i] === "--target-org" && args[i + 1]) {
|
|
51
|
+
targetOrg = args[++i];
|
|
52
|
+
} else if (args[i] === "--app" && args[i + 1]) {
|
|
53
|
+
appName = args[++i];
|
|
54
|
+
} else if (args[i] === "--permset" && args[i + 1]) {
|
|
55
|
+
permsetName = args[++i];
|
|
56
|
+
} else if (args[i] === "--skip-login") flags.skipLogin = true;
|
|
57
|
+
else if (args[i] === "--skip-deploy") flags.skipDeploy = true;
|
|
58
|
+
else if (args[i] === "--skip-permset") flags.skipPermset = true;
|
|
59
|
+
else if (args[i] === "--skip-data") flags.skipData = true;
|
|
60
|
+
else if (args[i] === "--skip-graphql") flags.skipGraphql = true;
|
|
61
|
+
else if (args[i] === "--skip-webapp-build") flags.skipWebappBuild = true;
|
|
62
|
+
else if (args[i] === "--skip-dev") flags.skipDev = true;
|
|
63
|
+
else if (args[i] === "--help" || args[i] === "-h") {
|
|
64
|
+
console.log(`
|
|
65
|
+
Setup CLI (property management feature)
|
|
66
|
+
|
|
67
|
+
Usage:
|
|
68
|
+
node setup-cli.mjs --target-org <alias> [options]
|
|
69
|
+
|
|
70
|
+
Required:
|
|
71
|
+
--target-org <alias> Target Salesforce org alias (e.g. afv5)
|
|
72
|
+
|
|
73
|
+
Options:
|
|
74
|
+
--app <name> Web app folder name (default: auto-detect if only one in force-app/.../webapplications/)
|
|
75
|
+
--permset <name> Permission set to assign (default: Property_Management_Access)
|
|
76
|
+
--skip-login Skip login step (login is auto-skipped if org is already connected)
|
|
77
|
+
--skip-deploy Do not deploy metadata
|
|
78
|
+
--skip-permset Do not assign permission set
|
|
79
|
+
--skip-data Do not prepare data or run data import
|
|
80
|
+
--skip-graphql Do not fetch schema or run GraphQL codegen
|
|
81
|
+
--skip-webapp-build Do not npm install / build the web application
|
|
82
|
+
--skip-dev Do not launch the dev server at the end
|
|
83
|
+
-h, --help Show this help
|
|
84
|
+
`);
|
|
85
|
+
process.exit(0);
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
if (!targetOrg) {
|
|
89
|
+
console.error("Error: --target-org <alias> is required.");
|
|
90
|
+
process.exit(1);
|
|
91
|
+
}
|
|
92
|
+
return { targetOrg, appName, permsetName, ...flags };
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
function discoverWebAppDir(appNameOverride) {
|
|
96
|
+
if (appNameOverride) {
|
|
97
|
+
const dir = resolve(WEBAPPLICATIONS_DIR, appNameOverride);
|
|
98
|
+
if (!existsSync(dir)) {
|
|
99
|
+
console.error(`Error: Web app directory not found: ${dir}`);
|
|
100
|
+
process.exit(1);
|
|
101
|
+
}
|
|
102
|
+
return dir;
|
|
103
|
+
}
|
|
104
|
+
if (!existsSync(WEBAPPLICATIONS_DIR)) {
|
|
105
|
+
console.error(`Error: Web applications directory not found: ${WEBAPPLICATIONS_DIR}`);
|
|
106
|
+
process.exit(1);
|
|
107
|
+
}
|
|
108
|
+
const entries = readdirSync(WEBAPPLICATIONS_DIR, { withFileTypes: true });
|
|
109
|
+
const dirs = entries.filter((e) => e.isDirectory());
|
|
110
|
+
if (dirs.length === 0) {
|
|
111
|
+
console.error(
|
|
112
|
+
"Error: No web application folder found under force-app/main/default/webapplications/",
|
|
113
|
+
);
|
|
114
|
+
process.exit(1);
|
|
115
|
+
}
|
|
116
|
+
if (dirs.length > 1) {
|
|
117
|
+
console.error(
|
|
118
|
+
"Error: Multiple web applications found. Specify one with --app <name>. Choices:",
|
|
119
|
+
dirs.map((d) => d.name).join(", "),
|
|
120
|
+
);
|
|
121
|
+
process.exit(1);
|
|
122
|
+
}
|
|
123
|
+
return resolve(WEBAPPLICATIONS_DIR, dirs[0].name);
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
function isOrgConnected(targetOrg) {
|
|
127
|
+
const result = spawnSync("sf", ["org", "display", "--target-org", targetOrg, "--json"], {
|
|
128
|
+
cwd: ROOT,
|
|
129
|
+
stdio: "pipe",
|
|
130
|
+
shell: true,
|
|
131
|
+
});
|
|
132
|
+
return result.status === 0;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
function run(name, cmd, args, opts = {}) {
|
|
136
|
+
const { cwd = ROOT, optional = false } = opts;
|
|
137
|
+
console.log("\n---", name, "---");
|
|
138
|
+
const result = spawnSync(cmd, args, {
|
|
139
|
+
cwd,
|
|
140
|
+
stdio: "inherit",
|
|
141
|
+
shell: true,
|
|
142
|
+
...(opts.timeout && { timeout: opts.timeout }),
|
|
143
|
+
});
|
|
144
|
+
if (result.status !== 0 && !optional) {
|
|
145
|
+
console.error(`\nSetup failed at step: ${name}`);
|
|
146
|
+
process.exit(result.status ?? 1);
|
|
147
|
+
}
|
|
148
|
+
return result;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
function main() {
|
|
152
|
+
const {
|
|
153
|
+
targetOrg,
|
|
154
|
+
appName: appNameOverride,
|
|
155
|
+
permsetName,
|
|
156
|
+
skipLogin,
|
|
157
|
+
skipDeploy,
|
|
158
|
+
skipPermset,
|
|
159
|
+
skipData,
|
|
160
|
+
skipGraphql,
|
|
161
|
+
skipWebappBuild,
|
|
162
|
+
skipDev,
|
|
163
|
+
} = parseArgs();
|
|
164
|
+
|
|
165
|
+
const WEBAPP_DIR = discoverWebAppDir(appNameOverride);
|
|
166
|
+
const webAppName = appNameOverride || basename(WEBAPP_DIR);
|
|
167
|
+
|
|
168
|
+
console.log("Setup — target org:", targetOrg, "| web app:", webAppName);
|
|
169
|
+
console.log(
|
|
170
|
+
"Steps: login=%s deploy=%s permset=%s data=%s graphql=%s webapp=%s dev=%s",
|
|
171
|
+
!skipLogin,
|
|
172
|
+
!skipDeploy,
|
|
173
|
+
!skipPermset,
|
|
174
|
+
!skipData,
|
|
175
|
+
!skipGraphql,
|
|
176
|
+
!skipWebappBuild,
|
|
177
|
+
!skipDev,
|
|
178
|
+
);
|
|
179
|
+
|
|
180
|
+
if (!skipLogin) {
|
|
181
|
+
if (isOrgConnected(targetOrg)) {
|
|
182
|
+
console.log("\n--- Login ---");
|
|
183
|
+
console.log(`Org ${targetOrg} is already authenticated; skipping browser login.`);
|
|
184
|
+
} else {
|
|
185
|
+
run("Login (browser)", "sf", ["org", "login", "web", "--alias", targetOrg], {
|
|
186
|
+
optional: true,
|
|
187
|
+
});
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
if (!skipDeploy) {
|
|
192
|
+
run("Deploy metadata", "sf", ["project", "deploy", "start", "--target-org", targetOrg], {
|
|
193
|
+
timeout: 180000,
|
|
194
|
+
});
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
if (!skipPermset) {
|
|
198
|
+
console.log("\n--- Assign permission set ---");
|
|
199
|
+
const permsetResult = spawnSync(
|
|
200
|
+
"sf",
|
|
201
|
+
["org", "assign", "permset", "--name", permsetName, "--target-org", targetOrg],
|
|
202
|
+
{
|
|
203
|
+
cwd: ROOT,
|
|
204
|
+
stdio: "pipe",
|
|
205
|
+
shell: true,
|
|
206
|
+
},
|
|
207
|
+
);
|
|
208
|
+
if (permsetResult.status === 0) {
|
|
209
|
+
console.log("Permission set assigned.");
|
|
210
|
+
} else {
|
|
211
|
+
const out =
|
|
212
|
+
(permsetResult.stderr?.toString() || "") + (permsetResult.stdout?.toString() || "");
|
|
213
|
+
if (out.includes("Duplicate") && out.includes("PermissionSet")) {
|
|
214
|
+
console.log("Permission set already assigned; skipping.");
|
|
215
|
+
} else {
|
|
216
|
+
process.stdout.write(permsetResult.stdout?.toString() || "");
|
|
217
|
+
process.stderr.write(permsetResult.stderr?.toString() || "");
|
|
218
|
+
console.error("\nSetup failed at step: Assign permission set");
|
|
219
|
+
process.exit(permsetResult.status ?? 1);
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
const hasDataPlan = existsSync(DATA_PLAN);
|
|
225
|
+
const hasPrepareScript = existsSync(PREPARE_SCRIPT);
|
|
226
|
+
|
|
227
|
+
if (!skipData) {
|
|
228
|
+
if (hasPrepareScript) {
|
|
229
|
+
run("Prepare data (unique fields)", "node", [PREPARE_SCRIPT], { cwd: DATA_DIR });
|
|
230
|
+
} else {
|
|
231
|
+
console.log("\n--- Prepare data ---");
|
|
232
|
+
console.log("No prepare-import-unique-fields.js found; skipping.");
|
|
233
|
+
}
|
|
234
|
+
if (hasDataPlan) {
|
|
235
|
+
run(
|
|
236
|
+
"Data import tree",
|
|
237
|
+
"sf",
|
|
238
|
+
["data", "import", "tree", "--plan", DATA_PLAN, "--target-org", targetOrg],
|
|
239
|
+
{
|
|
240
|
+
timeout: 120000,
|
|
241
|
+
},
|
|
242
|
+
);
|
|
243
|
+
} else {
|
|
244
|
+
console.log("\n--- Data import ---");
|
|
245
|
+
console.log("No data-plan.json found; skipping data import.");
|
|
246
|
+
}
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
if (!skipGraphql || !skipWebappBuild) {
|
|
250
|
+
run("Web app npm install", "npm", ["install"], { cwd: WEBAPP_DIR });
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
if (!skipGraphql) {
|
|
254
|
+
run("Set default org for schema", "sf", ["config", "set", "target-org", targetOrg, "--global"]);
|
|
255
|
+
run("GraphQL schema (introspect)", "npm", ["run", "graphql:schema"], { cwd: WEBAPP_DIR });
|
|
256
|
+
run("GraphQL codegen", "npm", ["run", "graphql:codegen"], { cwd: WEBAPP_DIR });
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
if (!skipWebappBuild) {
|
|
260
|
+
run("Web app build", "npm", ["run", "build"], { cwd: WEBAPP_DIR });
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
console.log("\n--- Setup complete ---");
|
|
264
|
+
|
|
265
|
+
if (!skipDev) {
|
|
266
|
+
console.log("\n--- Launching dev server (Ctrl+C to stop) ---\n");
|
|
267
|
+
run("Dev server", "npm", ["run", "dev"], { cwd: WEBAPP_DIR });
|
|
268
|
+
}
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
main();
|
package/package.json
CHANGED
|
File without changes
|