@zengenti/contensis-react-base 3.0.2-beta.25 → 3.0.2-beta.26

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,6 +1,6 @@
1
1
  import 'isomorphic-fetch';
2
2
  import React from 'react';
3
- import { AppConfig } from '~/config';
3
+ import { AppConfig } from "../config";
4
4
  type ReactAppProps = {
5
5
  routes: any;
6
6
  withEvents: any;
@@ -1,3 +1,3 @@
1
1
  import ClientApp from './client';
2
- export { default as ReactApp } from '~/app/App';
2
+ export { default as ReactApp } from "../app/App";
3
3
  export default ClientApp;
package/models/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
- export * from '~/config';
2
- export * from '~/routing/routes';
3
- export { default as linkDepthApi } from '~/server/features/linkdepth-api/api';
4
- import internalServer from '~/server/internalServer';
5
- export { default as ReactApp } from '~/app/App';
1
+ export * from "./config";
2
+ export * from "./routing/routes";
3
+ export { default as linkDepthApi } from "./server/features/linkdepth-api/api";
4
+ import internalServer from "./server/internalServer";
5
+ export { default as ReactApp } from "./app/App";
6
6
  export default internalServer;
@@ -5,5 +5,5 @@ declare namespace _default {
5
5
  }
6
6
  export default _default;
7
7
  import * as navigation from "./navigation";
8
- import * as routing from "~/routing/redux/actions";
8
+ import * as routing from "../../routing/redux/actions";
9
9
  import * as version from "./version";
@@ -2,7 +2,7 @@ import { VersionStatus } from 'contensis-core-api';
2
2
  import { Entry, Node } from 'contensis-delivery-api/lib/models';
3
3
  import { Group, User } from 'contensis-management-api/lib/models';
4
4
  import { MatchedRoute } from 'react-router-config';
5
- import { StaticRoute } from '~/routing/routes';
5
+ import { StaticRoute } from "../routing/routes";
6
6
  export type AppState = {
7
7
  navigation: {
8
8
  root: Node | null;
@@ -5,5 +5,5 @@ declare namespace _default {
5
5
  }
6
6
  export default _default;
7
7
  import * as navigation from "./navigation";
8
- import * as routing from "~/routing/redux/selectors";
8
+ import * as routing from "../../routing/redux/selectors";
9
9
  import * as version from "./version";
@@ -1,6 +1,6 @@
1
1
  import { AppState } from '../appstate';
2
2
  import { History, MemoryHistory } from 'history';
3
- import { StateType } from '~/config';
3
+ import { StateType } from "../../config";
4
4
  export declare let reduxStore: any;
5
5
  declare const _default: (featureReducers: any, initialState: AppState, history: History | MemoryHistory, stateType: StateType) => Promise<any>;
6
6
  export default _default;
@@ -5,5 +5,5 @@ declare namespace _default {
5
5
  }
6
6
  export default _default;
7
7
  import * as navigation from "./navigation";
8
- import * as routing from "~/routing/redux/types";
8
+ import * as routing from "../../routing/redux/types";
9
9
  import * as version from "./version";
@@ -2,7 +2,7 @@ import { useLocation } from 'react-router-dom';
2
2
  import { Entry } from 'contensis-delivery-api/lib/models';
3
3
  import { MatchedRoute, RouteConfig } from 'react-router-config';
4
4
  import { AppRoutes, WithEvents } from '../routes';
5
- import { CookieHelper } from '~/user/util/CookieHelper.class';
5
+ import { CookieHelper } from "../../user/util/CookieHelper.class";
6
6
  export declare const setNavigationPath: (path: string, location: ReturnType<typeof useLocation>, staticRoute: MatchedRoute<any, RouteConfig> | undefined, withEvents: WithEvents, statePath: string, routes: AppRoutes, cookies: CookieHelper) => any;
7
7
  export declare const setCurrentProject: (project: string, allowedGroups: any, hostname: string) => any;
8
8
  export declare const setRoute: (path: string, state?: any) => any;
@@ -1,5 +1,5 @@
1
- import { StateType } from '~/config';
2
- import { AppState } from '~/redux/appstate';
1
+ import { StateType } from "../../config";
2
+ import { AppState } from "../../redux/appstate";
3
3
  export declare const selectRouteEntry: (state: AppState, returnType?: StateType) => any;
4
4
  export declare const selectMappedEntry: (state: AppState, returnType?: StateType) => any;
5
5
  export declare const selectSurrogateKeys: (state: AppState) => any;
@@ -1,8 +1,8 @@
1
1
  import { MatchedRoute, RouteConfig } from 'react-router-config';
2
2
  import { Entry, Node } from 'contensis-delivery-api/lib/models';
3
3
  import React from 'react';
4
- import { AppState } from '~/redux/appstate';
5
- import { CookieHelper } from '~/user/util/CookieHelper.class';
4
+ import { AppState } from "../redux/appstate";
5
+ import { CookieHelper } from "../user/util/CookieHelper.class";
6
6
  type RouteComponent<Props> = React.ComponentType<Props>;
7
7
  export type RouteNode = Node & {
8
8
  ancestors: Node[];
@@ -1,2 +1,2 @@
1
- import { Query } from '~/util/ContensisDeliveryApi';
1
+ import { Query } from "../../util/ContensisDeliveryApi";
2
2
  export declare const routeEntryByFieldsQuery: (id: string, language?: string, fields?: string[], versionStatus?: 'published' | 'latest') => Query;
@@ -1,4 +1,4 @@
1
- import { FilterExpression, SearchQueryOptions } from '~/search';
1
+ import { FilterExpression, SearchQueryOptions } from "../../../search";
2
2
  import { Query } from 'contensis-core-api';
3
3
  import { Entry } from 'contensis-delivery-api/lib/models';
4
4
  import { LinkDepthApiFilters } from './api.d';
@@ -4,7 +4,7 @@ import { Express } from 'express';
4
4
  import http from 'http';
5
5
  import React from 'react';
6
6
  import { deliveryProxy } from './features/reverse-proxy';
7
- import { ServerConfig } from '~/config';
7
+ import { ServerConfig } from "../config";
8
8
  type Exporting = {
9
9
  app: Express;
10
10
  apiProxy: typeof deliveryProxy;
@@ -1,5 +1,5 @@
1
1
  import { ChunkExtractor } from '@loadable/server';
2
- import { ServerConfig } from '~/config';
2
+ import { ServerConfig } from "../../config";
3
3
  export declare const loadableBundleData: ({ stats, templates }: ServerConfig, staticRoutePath: string, build?: string) => {
4
4
  stats?: string | null | undefined;
5
5
  templates?: {
@@ -1,5 +1,5 @@
1
1
  import { Response } from 'express';
2
- import { AppState } from '~/redux/appstate';
2
+ import { AppState } from "../../redux/appstate";
3
3
  export declare const addStandardHeaders: (state: AppState, response: Response, packagejson: any, groups: {
4
4
  globalGroups?: any[];
5
5
  allowedGroups?: any[];
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  import { Express } from 'express';
3
- import { ServerConfig } from '~/config';
3
+ import { ServerConfig } from "../config";
4
4
  declare const webApp: (app: Express, ReactApp: React.ComponentType<any>, config: ServerConfig & {
5
5
  allowedGroups?: string[];
6
6
  globalGroups?: string[];
@@ -1,5 +1,5 @@
1
- import { StateType } from '~/config';
2
- import { AppState } from '~/redux/appstate';
1
+ import { StateType } from "../../config";
2
+ import { AppState } from "../../redux/appstate";
3
3
  export declare const selectUserIsLoading: (state: AppState) => any;
4
4
  export declare const selectUserIsAuthenticated: (state: AppState) => any;
5
5
  export declare const selectUserIsAuthenticationError: (state: AppState) => any;
@@ -1,3 +1,3 @@
1
1
  import { Group } from 'contensis-management-api/lib/models';
2
- import { RequireLogin } from '~/routing/routes';
2
+ import { RequireLogin } from "../../routing/routes";
3
3
  export declare const matchUserGroup: (userGroups?: Group[], requiredGroups?: RequireLogin) => boolean;
@@ -1,6 +1,6 @@
1
- export { default as setCachingHeaders } from '~/server/features/caching/setCachingHeaders';
1
+ export { default as setCachingHeaders } from "../server/features/caching/setCachingHeaders";
2
2
  export { cachedSearch, cachedSearchWithCookies, deliveryApi, deliveryApiWithCookies, getClientConfig, } from './ContensisDeliveryApi';
3
3
  export { default as stringifyStrings } from './stringifyStrings';
4
4
  export { default as urls } from './urls';
5
5
  export * from './json-mapper';
6
- export { default as VersionInfo } from '~/app/pages/VersionInfo';
6
+ export { default as VersionInfo } from "../app/pages/VersionInfo";
@@ -1,8 +1,8 @@
1
1
  import { Entry } from 'contensis-delivery-api/lib/models';
2
2
  import mapJson from 'jsonpath-mapper';
3
3
  import MappingTemplate, { PureJsFunction } from 'jsonpath-mapper/dist/models/Template';
4
- import { AppState } from '~/redux/appstate';
5
- import { EntryMapper, RouteNode } from '~/routing/routes';
4
+ import { AppState } from "../redux/appstate";
5
+ import { EntryMapper, RouteNode } from "../routing/routes";
6
6
  export { default as mapJson, jpath } from 'jsonpath-mapper';
7
7
  type Mappers<S> = {
8
8
  [contentTypeId: string]: MappingTemplate<S>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zengenti/contensis-react-base",
3
- "version": "3.0.2-beta.25",
3
+ "version": "3.0.2-beta.26",
4
4
  "repository": "https://github.com/zengenti/contensis-react-base",
5
5
  "license": "None",
6
6
  "description": "Turbocharge your React web apps with Contensis. This package handles all dependencies for creating full featured web apps in React with Contensis and Site View. Routing is driven by Site View, Redux is used for global state management and server-side rendering (SSR) is handled for you. Also taking care of intricate hosting issues such as cache invalidation and supporting authenticated content where required.",
@@ -8,10 +8,9 @@
8
8
  "module": "esm/contensis-react-base.js",
9
9
  "types": "models",
10
10
  "scripts": {
11
- "prepare": "ts-patch install -s",
12
11
  "start": "npm run roll:watch",
13
12
  "debug:server": "npm start",
14
- "build": "npm run clean:lib && tsc && npm run copymodels && npm run roll:lib",
13
+ "build": "npm run clean:lib && ttsc && npm run copymodels && npm run roll:lib",
15
14
  "build:lib": "npm i zengenti-search-package zengenti-forms-package && npm run build",
16
15
  "roll:lib": "cross-env NODE_ENV=production rollup -c rollup/rollup.config.lib.js",
17
16
  "roll:watch": "cross-env NODE_ENV=production rollup -c rollup/rollup.config.lib.js --watch",
@@ -87,7 +86,7 @@
87
86
  "rimraf": "^3.0.2",
88
87
  "rollup": "^2.70.2",
89
88
  "rollup-plugin-peer-deps-external": "^2.2.4",
90
- "ts-patch": "^3.0.2",
89
+ "ttypescript": "^1.5.15",
91
90
  "typescript": "^4.9.5",
92
91
  "typescript-transform-paths": "^3.4.6",
93
92
  "zengenti-forms-package": "git+https://gitlab+deploy-token-11:DRbTWzdaRzkjDWc_VixQ@gitlab.zengenti.com/zengenti-packages/forms.git#next",