create-prisma-php-app 1.21.4 → 1.22.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.
@@ -1,36 +0,0 @@
1
- window.onload = function () {
2
- //<editor-fold desc="Changeable Configuration Block">
3
-
4
- const host = window.location.hostname;
5
- const port = window.location.port;
6
-
7
- // Set the URL dynamically based on the environment
8
- let swaggerUrl;
9
-
10
- if (host === "localhost") {
11
- // For local development, handle different possible ports
12
- swaggerUrl = `http://${host}:${
13
- port || 3000
14
- }/swagger-docs/apis/pphp-swagger.json`;
15
- } else {
16
- // For production, use the domain without hardcoding the port
17
- swaggerUrl = `https://${host}/swagger-docs/pphp-swagger.json`;
18
- }
19
-
20
- window.ui = SwaggerUIBundle({
21
- url: swaggerUrl,
22
- dom_id: "#swagger-ui",
23
- deepLinking: true,
24
- presets: [SwaggerUIBundle.presets.apis, SwaggerUIStandalonePreset],
25
- plugins: [SwaggerUIBundle.plugins.DownloadUrl],
26
- layout: "StandaloneLayout",
27
-
28
- // Add custom header using requestInterceptor
29
- requestInterceptor: (request) => {
30
- request.headers["HTTP_PPHP_X_FILE_REQUEST"] = "true"; // Set your custom header here
31
- return request;
32
- },
33
- });
34
-
35
- //</editor-fold>
36
- };