Files
talk/src/core/client/stream/index.tsx
T
VinhandWyatt Johnson 7c2e56b751 [CORL-719] A11y runtime checks using react-axe (#2725)
* feature: use react-axe and fix some a11y issues in stream

* fix: adapt snapshots

* chore: fix axe warnings in auth and account bundle

* chore: improve accessibility in install bundle

* chore: add some comments
2019-11-22 19:10:51 +00:00

37 lines
961 B
TypeScript

import { Child as PymChild } from "pym.js";
import React, { FunctionComponent } from "react";
import ReactDOM from "react-dom";
import potentiallyInjectAxe from "coral-framework/helpers/potentiallyInjectAxe";
import { createManaged } from "coral-framework/lib/bootstrap";
import AppContainer from "./App";
import { initLocalState } from "./local";
import localesData from "./locales";
// Import css variables.
import "coral-ui/theme/variables.css";
async function main() {
const pym = new PymChild({
polling: 100,
});
// Potentially inject react-axe for runtime a11y checks.
await potentiallyInjectAxe(pym.parentUrl);
const ManagedCoralContextProvider = await createManaged({
initLocalState,
localesData,
pym,
});
const Index: FunctionComponent = () => (
<ManagedCoralContextProvider>
<AppContainer />
</ManagedCoralContextProvider>
);
ReactDOM.render(<Index />, document.getElementById("app"));
}
main();