@spfn/core 0.1.0-alpha.84 → 0.1.0-alpha.86
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/cache/index.js +12 -1
- package/dist/cache/index.js.map +1 -1
- package/dist/client/index.d.ts +192 -46
- package/dist/client/index.js +181 -9
- package/dist/client/index.js.map +1 -1
- package/dist/client/nextjs/index.d.ts +557 -0
- package/dist/client/nextjs/index.js +371 -0
- package/dist/client/nextjs/index.js.map +1 -0
- package/dist/codegen/generators/index.js +12 -1
- package/dist/codegen/generators/index.js.map +1 -1
- package/dist/codegen/index.js +12 -1
- package/dist/codegen/index.js.map +1 -1
- package/dist/db/index.js +12 -1
- package/dist/db/index.js.map +1 -1
- package/dist/env/index.js +12 -1
- package/dist/env/index.js.map +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.js +148 -13
- package/dist/index.js.map +1 -1
- package/dist/logger/index.js +12 -1
- package/dist/logger/index.js.map +1 -1
- package/dist/middleware/index.js +12 -1
- package/dist/middleware/index.js.map +1 -1
- package/dist/route/index.js +15 -3
- package/dist/route/index.js.map +1 -1
- package/dist/server/index.d.ts +53 -2
- package/dist/server/index.js +148 -13
- package/dist/server/index.js.map +1 -1
- package/package.json +7 -1
package/dist/db/index.js
CHANGED
|
@@ -133,7 +133,18 @@ function formatConsole(metadata, colorize = true) {
|
|
|
133
133
|
}
|
|
134
134
|
if (metadata.context && Object.keys(metadata.context).length > 0) {
|
|
135
135
|
Object.entries(metadata.context).forEach(([key, value]) => {
|
|
136
|
-
|
|
136
|
+
let valueStr;
|
|
137
|
+
if (typeof value === "string") {
|
|
138
|
+
valueStr = value;
|
|
139
|
+
} else if (typeof value === "object" && value !== null) {
|
|
140
|
+
try {
|
|
141
|
+
valueStr = JSON.stringify(value);
|
|
142
|
+
} catch (error) {
|
|
143
|
+
valueStr = "[circular]";
|
|
144
|
+
}
|
|
145
|
+
} else {
|
|
146
|
+
valueStr = String(value);
|
|
147
|
+
}
|
|
137
148
|
if (colorize) {
|
|
138
149
|
parts.push(`${COLORS.dim}[${key}=${valueStr}]${COLORS.reset}`);
|
|
139
150
|
} else {
|