create-better-t-stack 3.6.8 → 3.7.1
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/cli.js +1 -1
- package/dist/index.js +1 -1
- package/dist/{src-BMcSQ5Qw.js → src-BmyCNYPk.js} +13 -20
- package/package.json +1 -1
package/dist/cli.js
CHANGED
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { a as router, i as init, n as createBtsCli, o as sponsors, r as docs, t as builder } from "./src-
|
|
2
|
+
import { a as router, i as init, n as createBtsCli, o as sponsors, r as docs, t as builder } from "./src-BmyCNYPk.js";
|
|
3
3
|
|
|
4
4
|
export { builder, createBtsCli, docs, init, router, sponsors };
|
|
@@ -1355,33 +1355,26 @@ function isTelemetryEnabled() {
|
|
|
1355
1355
|
|
|
1356
1356
|
//#endregion
|
|
1357
1357
|
//#region src/utils/analytics.ts
|
|
1358
|
-
const
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1358
|
+
const CONVEX_INGEST_URL = "https://striped-seahorse-863.convex.site/api/analytics/ingest";
|
|
1359
|
+
async function sendConvexEvent(payload) {
|
|
1360
|
+
try {
|
|
1361
|
+
await fetch(CONVEX_INGEST_URL, {
|
|
1362
|
+
method: "POST",
|
|
1363
|
+
headers: { "Content-Type": "application/json" },
|
|
1364
|
+
body: JSON.stringify(payload)
|
|
1365
|
+
});
|
|
1366
|
+
} catch (_error) {}
|
|
1363
1367
|
}
|
|
1364
1368
|
async function trackProjectCreation(config, disableAnalytics = false) {
|
|
1365
1369
|
if (!isTelemetryEnabled() || disableAnalytics) return;
|
|
1366
|
-
const sessionId = generateSessionId();
|
|
1367
1370
|
const { projectName, projectDir, relativePath,...safeConfig } = config;
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
|
|
1371
|
-
properties: {
|
|
1371
|
+
try {
|
|
1372
|
+
await sendConvexEvent({
|
|
1373
|
+
event: "project_created",
|
|
1372
1374
|
...safeConfig,
|
|
1373
1375
|
cli_version: getLatestCLIVersion(),
|
|
1374
1376
|
node_version: typeof process !== "undefined" ? process.version : "",
|
|
1375
|
-
platform: typeof process !== "undefined" ? process.platform : ""
|
|
1376
|
-
$ip: null
|
|
1377
|
-
},
|
|
1378
|
-
distinct_id: sessionId
|
|
1379
|
-
};
|
|
1380
|
-
try {
|
|
1381
|
-
await fetch(`${POSTHOG_HOST}/capture`, {
|
|
1382
|
-
method: "POST",
|
|
1383
|
-
headers: { "Content-Type": "application/json" },
|
|
1384
|
-
body: JSON.stringify(payload)
|
|
1377
|
+
platform: typeof process !== "undefined" ? process.platform : ""
|
|
1385
1378
|
});
|
|
1386
1379
|
} catch (_error) {}
|
|
1387
1380
|
}
|
package/package.json
CHANGED