@websolutespa/bom-mixer-store 1.7.1 → 1.7.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 CHANGED
@@ -1,5 +1,11 @@
1
1
  # @websolutespa/bom-mixer-store
2
2
 
3
+ ## 1.7.2
4
+
5
+ ### Patch Changes
6
+
7
+ - 7898849: Modified: exporting getRemoteApiUrl
8
+
3
9
  ## 1.7.1
4
10
 
5
11
  ### Patch Changes
package/dist/index.d.ts CHANGED
@@ -152,6 +152,7 @@ declare class RemotePageService<T extends ICategorized = ICategorized> extends R
152
152
  protected decorateMany_<B extends T = T>(items: B[], params?: QueryParams): Promise<B[]>;
153
153
  }
154
154
 
155
+ declare function getRemoteApiUrl(pathname: string): string;
155
156
  declare function remoteApiFetch<T = unknown>(pathname: string, options?: ApiRequestOptions): Promise<T>;
156
157
  declare function remoteApiGet<T = unknown>(url: string, options?: ApiRequestOptions): Promise<T>;
157
158
  declare function remoteApiPost<T = unknown>(url: string, payload: unknown, options?: ApiRequestOptions): Promise<T>;
@@ -235,4 +236,4 @@ declare function findRoute(store: IStore, pathname: string, href: string, hrefBe
235
236
 
236
237
  declare function getStore<T extends IStore>(): Promise<T>;
237
238
 
238
- export { ApiRequestOptions, BuildStrategy, COLLECTIONS, IApiHandler, ICrudMethod, IField, IHandler, IPageResolvedRelation, KNOWN_COLLECTIONS, MAX_INT, MOCK_COLLECTIONS, MapTo, MockMenuService, MockPageService, MockService, NextPhase, RemoteMenuService, RemotePageService, RemoteService, RemoteServiceStrategy, SERVICE_DEFAULT_DEPTH, STATIC_COLLECTIONS, StaticService, StaticServiceConfig, StaticServiceSrc, StoreStrategy, apiHandler, buildStrategy, collectionDelete, collectionGet, collectionPatch, collectionPost, decorateCategories_, decorateCategory_, decorateHref_, decorateHrefs_, decorateLocalizable_, decorateLocalizables_, decorateMenu_, decorateMenus_, decorateNav_, decorateNavs_, decorateRelation_, decorateRelations_, decorateSchema_, decorateSchemas_, decorateStaticRelation_, decorateStaticRelations_, defaultApiRequestOptions, errorHandler, findRoute, fromCache, getDefaultApiRequestOptions, getLocalApiUrl, getMockStore, getMockStoreFromData_, getRemoteStore, getStore, isApiRequest, isNextRequest, isStaticRequest, localApiDelete, localApiFetch, localApiGet, localApiPatch, localApiPost, localApiPut, mockApiDelete, mockApiFetch, mockApiGet, mockApiPatch, mockApiPost, mockApiPut, mockHandler, nextPhase, optimizeMany_, optimizeOne_, remoteApiDelete, remoteApiFetch, remoteApiGet, remoteApiPatch, remoteApiPost, remoteApiPut, routePost, staticCollections, storeApiDelete, storeApiGet, storeApiPatch, storeApiPost, storeApiPut, storeCacheDuration, storeHandler, storeIndexHandler, storeStrategy };
239
+ export { ApiRequestOptions, BuildStrategy, COLLECTIONS, IApiHandler, ICrudMethod, IField, IHandler, IPageResolvedRelation, KNOWN_COLLECTIONS, MAX_INT, MOCK_COLLECTIONS, MapTo, MockMenuService, MockPageService, MockService, NextPhase, RemoteMenuService, RemotePageService, RemoteService, RemoteServiceStrategy, SERVICE_DEFAULT_DEPTH, STATIC_COLLECTIONS, StaticService, StaticServiceConfig, StaticServiceSrc, StoreStrategy, apiHandler, buildStrategy, collectionDelete, collectionGet, collectionPatch, collectionPost, decorateCategories_, decorateCategory_, decorateHref_, decorateHrefs_, decorateLocalizable_, decorateLocalizables_, decorateMenu_, decorateMenus_, decorateNav_, decorateNavs_, decorateRelation_, decorateRelations_, decorateSchema_, decorateSchemas_, decorateStaticRelation_, decorateStaticRelations_, defaultApiRequestOptions, errorHandler, findRoute, fromCache, getDefaultApiRequestOptions, getLocalApiUrl, getMockStore, getMockStoreFromData_, getRemoteApiUrl, getRemoteStore, getStore, isApiRequest, isNextRequest, isStaticRequest, localApiDelete, localApiFetch, localApiGet, localApiPatch, localApiPost, localApiPut, mockApiDelete, mockApiFetch, mockApiGet, mockApiPatch, mockApiPost, mockApiPut, mockHandler, nextPhase, optimizeMany_, optimizeOne_, remoteApiDelete, remoteApiFetch, remoteApiGet, remoteApiPatch, remoteApiPost, remoteApiPut, routePost, staticCollections, storeApiDelete, storeApiGet, storeApiPatch, storeApiPost, storeApiPut, storeCacheDuration, storeHandler, storeIndexHandler, storeStrategy };
package/dist/index.js CHANGED
@@ -77,6 +77,7 @@ __export(src_exports, {
77
77
  getLocalApiUrl: () => getLocalApiUrl,
78
78
  getMockStore: () => getMockStore,
79
79
  getMockStoreFromData_: () => getMockStoreFromData_,
80
+ getRemoteApiUrl: () => getRemoteApiUrl,
80
81
  getRemoteStore: () => getRemoteStore,
81
82
  getStore: () => getStore,
82
83
  isApiRequest: () => isApiRequest,
@@ -2076,6 +2077,7 @@ async function storeApiDelete(url, options = {}) {
2076
2077
  getLocalApiUrl,
2077
2078
  getMockStore,
2078
2079
  getMockStoreFromData_,
2080
+ getRemoteApiUrl,
2079
2081
  getRemoteStore,
2080
2082
  getStore,
2081
2083
  isApiRequest,
package/dist/index.mjs CHANGED
@@ -1967,6 +1967,7 @@ export {
1967
1967
  getLocalApiUrl,
1968
1968
  getMockStore,
1969
1969
  getMockStoreFromData_,
1970
+ getRemoteApiUrl,
1970
1971
  getRemoteStore,
1971
1972
  getStore,
1972
1973
  isApiRequest,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@websolutespa/bom-mixer-store",
3
- "version": "1.7.1",
3
+ "version": "1.7.2",
4
4
  "description": "Mixer Store module of the BOM Repository",
5
5
  "keywords": [
6
6
  "bom",
@@ -8,7 +8,7 @@ import { ApiRequestOptions, getDefaultApiRequestOptions } from '../api/api';
8
8
  const API_URL = process.env.STORE_URL;
9
9
  const API_BASE = process.env.STORE_API || '/api';
10
10
 
11
- function getRemoteApiUrl(pathname: string): string {
11
+ export function getRemoteApiUrl(pathname: string): string {
12
12
  let url = `${API_URL}${API_BASE}${pathname}`;
13
13
  // !!! node 18 issue -> require('dns').setDefaultResultOrder('ipv4first');
14
14
  url = isBrowser ? url : url.replace('://localhost', '://127.0.0.1');