@acrool/rtk-query-codegen-openapi 1.4.0-alpha.4 → 1.4.0-alpha.5
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/lib/bin/cli.mjs +17 -24
- package/lib/bin/cli.mjs.map +1 -1
- package/lib/index.js +3 -17
- package/lib/index.js.map +1 -1
- package/lib/index.mjs +3 -17
- package/lib/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/generators/rtk-enhance-endpoints-generator.ts +2 -23
package/lib/index.js
CHANGED
|
@@ -1208,27 +1208,13 @@ export default injectedRtkApi;
|
|
|
1208
1208
|
// src/generators/rtk-enhance-endpoints-generator.ts
|
|
1209
1209
|
init_cjs_shims();
|
|
1210
1210
|
function generateRtkEnhanceEndpointsFile(endpointInfos, options) {
|
|
1211
|
-
|
|
1212
|
-
if (info.isQuery) {
|
|
1213
|
-
return ` ${info.operationName}: {
|
|
1214
|
-
providesTags: (result, error, arg) => [],
|
|
1215
|
-
},`;
|
|
1216
|
-
} else {
|
|
1217
|
-
return ` ${info.operationName}: {
|
|
1218
|
-
invalidatesTags: (result, error, arg) => [],
|
|
1219
|
-
},`;
|
|
1220
|
-
}
|
|
1221
|
-
}).join("\n");
|
|
1222
|
-
const importStatements = `/* eslint-disable */
|
|
1211
|
+
return `/* eslint-disable */
|
|
1223
1212
|
// [Warning] Generated automatically - do not edit manually
|
|
1224
1213
|
|
|
1225
1214
|
import api from "./query.generated";
|
|
1226
|
-
|
|
1227
|
-
return `${importStatements}
|
|
1215
|
+
|
|
1228
1216
|
const enhancedApi = api.enhanceEndpoints({
|
|
1229
|
-
endpoints: {
|
|
1230
|
-
${endpointConfigs}
|
|
1231
|
-
},
|
|
1217
|
+
endpoints: {},
|
|
1232
1218
|
});
|
|
1233
1219
|
|
|
1234
1220
|
export default enhancedApi;
|