@websolutespa/bom-mixer-store 3.0.0 → 3.0.2
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/CHANGELOG.md +353 -339
- package/dist/exports/server.js +3 -4
- package/dist/exports/server.js.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/{src-fjNC1rqq.js → src-bMn1KJCJ.js} +4 -7
- package/dist/src-bMn1KJCJ.js.map +1 -0
- package/package.json +6 -6
- package/src/local/local.api.ts +1 -3
- package/src/local_/local.api.ts +1 -3
- package/src/mock/mock.api.ts +2 -4
- package/src/remote/remote.api.ts +1 -3
- package/src/session/session.service.ts +1 -1
- package/dist/src-fjNC1rqq.js.map +0 -1
package/dist/exports/server.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { COLLECTIONS, DEFAULT_DEPTH, KNOWN_COLLECTIONS, MOCK_COLLECTIONS, NextPhase, StoreStrategy, buildStrategy, decorateCategories_, decorateCategory_, decorateHref_, decorateHrefs_, decorateLocalizable_, decorateLocalizables_, decorateMenu_, decorateMenus_, decorateNav_, decorateRelation_, decorateRelations_, decorateSchema_, decorateSchemas_, fromCache, getLocalApiRequestOptions, getRemoteApiRequestOptions, nextPhase, remoteApiDelete, remoteApiGet, remoteApiPatch, remoteApiPost, staticCollections, storeCacheDuration, storeStrategy } from "../src-
|
|
1
|
+
import { COLLECTIONS, DEFAULT_DEPTH, KNOWN_COLLECTIONS, MOCK_COLLECTIONS, NextPhase, StoreStrategy, buildStrategy, decorateCategories_, decorateCategory_, decorateHref_, decorateHrefs_, decorateLocalizable_, decorateLocalizables_, decorateMenu_, decorateMenus_, decorateNav_, decorateRelation_, decorateRelations_, decorateSchema_, decorateSchemas_, fromCache, getLocalApiRequestOptions, getRemoteApiRequestOptions, nextPhase, remoteApiDelete, remoteApiGet, remoteApiPatch, remoteApiPost, staticCollections, storeCacheDuration, storeStrategy } from "../src-bMn1KJCJ.js";
|
|
2
2
|
import { createRequire } from "node:module";
|
|
3
3
|
import { JsonService, asCategoryId, asEquatable, defaultLocale, defaultMarket, findRouteOfCategory, getHost, getOrigin, getRootCategory, httpFetch, httpGet, isBrowser, isDevelopment, isProduction, localize, merge, qsDeserialize, qsSerialize } from "@websolutespa/bom-core";
|
|
4
4
|
import { createPayloadRequest, getPayload } from "payload";
|
|
@@ -49,8 +49,7 @@ function errorHandler(error, response) {
|
|
|
49
49
|
const API_URL = process.env.STORE_URL;
|
|
50
50
|
const API_BASE = process.env.STORE_API || "/api";
|
|
51
51
|
function getLocalApiUrl(pathname) {
|
|
52
|
-
|
|
53
|
-
url = isBrowser ? url : url.replace("://localhost", "://127.0.0.1");
|
|
52
|
+
const url = `${API_URL}${API_BASE}${pathname}`;
|
|
54
53
|
return url;
|
|
55
54
|
}
|
|
56
55
|
async function localApiFetch(pathname, options = {}) {
|
|
@@ -473,7 +472,7 @@ var MockPageService = class extends MockService {
|
|
|
473
472
|
//#region src/session/session.service.ts
|
|
474
473
|
async function getSession(request, response) {
|
|
475
474
|
const COOKIE_NAME = "websolutespa-next-js";
|
|
476
|
-
const COOKIE_PASSWORD = process.env.MIXER_SECRET || "
|
|
475
|
+
const COOKIE_PASSWORD = process.env.MIXER_SECRET || "MIXER_SECRET_32_CHARS_LONG_12345";
|
|
477
476
|
const sessionOptions = {
|
|
478
477
|
cookieName: COOKIE_NAME,
|
|
479
478
|
cookieOptions: { secure: !isDevelopment },
|