soonjs 0.0.9 → 0.0.11
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/index.js +5 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -5204,7 +5204,7 @@ const So = /* @__PURE__ */ Gs(vs), V1 = `declare module 'soonjs/auto/client' {
|
|
|
5204
5204
|
body?: any;
|
|
5205
5205
|
url?: string;
|
|
5206
5206
|
query?: Record<string, string>;
|
|
5207
|
-
extra?: Record<string,
|
|
5207
|
+
extra?: Record<string, any>;
|
|
5208
5208
|
};
|
|
5209
5209
|
type SoonOnFetch = (args: SoonFetchOptions) => Promise<any>;
|
|
5210
5210
|
function soonClientConfig(options: { baseUrl: string; onFetch: SoonOnFetch; defaultMethod: string }): Promise<any>;
|
|
@@ -5426,7 +5426,8 @@ function lK(e) {
|
|
|
5426
5426
|
+ '\\n };';
|
|
5427
5427
|
|
|
5428
5428
|
const serviecsImport = exportedServices.filter(v => v.services.length).map(v => \`import { \${v.services.map(vv => \`\${vv.key} as \${vv.importName}\`).join(', ')} } from '\${v.importPath}';\`).join('\\n');
|
|
5429
|
-
const servicesContent = exportedServices.filter(v => v.services.length).map(v => v.services.map(vv => \` '\${vv.serviceName}' : ReturnRealType<typeof \${vv.importName}>;\`)
|
|
5429
|
+
const servicesContent = exportedServices.filter(v => v.services.length).map(v => v.services.map(vv => \` '\${vv.serviceName}' : ReturnRealType<typeof \${vv.importName}>;\`).join('
|
|
5430
|
+
')).join('\\n');
|
|
5430
5431
|
const servicesType = \`
|
|
5431
5432
|
type services = {
|
|
5432
5433
|
\` + servicesContent + '\\n };';
|
|
@@ -5435,7 +5436,8 @@ function lK(e) {
|
|
|
5435
5436
|
|
|
5436
5437
|
/** server **/
|
|
5437
5438
|
const autoInjectServiecsImport = autoInjectServices.filter(v => v.services.length).map(v => \`import { \${v.services.map(vv => \`\${vv.key} as \${vv.importName}\`).join(', ')} } from '\${v.importPath}';\`).join('\\n');
|
|
5438
|
-
const autoInjectServicesContent = autoInjectServices.filter(v => v.services.length).map(v => v.services.map(vv => \` '\${vv.serviceName}' : ReturnRealType<typeof \${vv.importName}>;\`)
|
|
5439
|
+
const autoInjectServicesContent = autoInjectServices.filter(v => v.services.length).map(v => v.services.map(vv => \` '\${vv.serviceName}' : ReturnRealType<typeof \${vv.importName}>;\`).join('
|
|
5440
|
+
')).join('\\n');
|
|
5439
5441
|
const contentServerDts = \`${K1}\`;
|
|
5440
5442
|
const contentServerTypes = \`${q1}\`.replace('$$$services-imports$$$', autoInjectServiecsImport).replace('$$$services-content$$$', autoInjectServicesContent);
|
|
5441
5443
|
|