Skip to content

Commit

Permalink
[fix] xarc/react AppContext export
Browse files Browse the repository at this point in the history
  • Loading branch information
jchip committed Apr 26, 2021
1 parent a8e2ac8 commit 51b5c27
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 9 deletions.
1 change: 1 addition & 0 deletions packages/xarc-react/src/browser/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import { ReactClientRenderPipeline } from "./react-render-pipeline";
export * from "../common";
export * from "./feat-static-props-browser";
export * from "./subapp-as-component";
export { AppContext } from "../common/app-context";
export { appContextFeature };

/**
Expand Down
7 changes: 3 additions & 4 deletions packages/xarc-react/src/common/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,12 @@ export { xarcV2 } from "@xarc/subapp";
* ```tsx
* import { ReactSubApp, React } from "@xarc/react";
*
* const Sample = () => <div>sample react component</div>
* const Sample = () => <div>sample react component</div>;
*
* export subapp: ReactSubApp = {
* export const subapp: ReactSubApp = {
* Component: Sample
* }
* };
* ```
*
*/
export type ReactSubApp = SubApp<React.Component | React.FunctionComponent>;

Expand Down
8 changes: 3 additions & 5 deletions packages/xarc-react/src/node/feat-app-context-node.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,10 @@ import {
* );
* };
*
* export subapp: ReactSubApp = {
* export const subapp: ReactSubApp = {
* Component: Sample,
* wantFeatures: [
* appContextFeature()
* ]
* }
* wantFeatures: [appContextFeature()],
* };
* ```
*
* @param options - app context feature options
Expand Down
1 change: 1 addition & 0 deletions packages/xarc-react/src/node/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ export * from "../common/index";
export * from "@xarc/tag-renderer";
export * from "./feat-static-props-node";
export * from "./subapp-as-component";
export { AppContext } from "../common/app-context";
export { SSRReactLib, subAppReady, loadSubApp, appContextFeature, RenderOptions, PageRenderer };

/**
Expand Down

0 comments on commit 51b5c27

Please sign in to comment.