mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2026-01-06 19:19:56 +00:00
21 lines
843 B
TypeScript
21 lines
843 B
TypeScript
import * as ReactDOM from "react-dom";
|
|
import "bootstrap/dist/css/bootstrap.css";
|
|
import { CosmosClient } from "../Common/CosmosClient";
|
|
import { GalleryViewerComponent } from "../Explorer/Controls/NotebookGallery/GalleryViewerComponent";
|
|
import { JunoUtils } from "../Utils/JunoUtils";
|
|
import { initializeIcons } from "office-ui-fabric-react/lib/Icons";
|
|
|
|
const onInit = async () => {
|
|
initializeIcons();
|
|
const officialSamplesData = await JunoUtils.getOfficialSampleNotebooks(CosmosClient.authorizationToken());
|
|
const galleryViewerComponent = new GalleryViewerComponent({
|
|
officialSamplesData: officialSamplesData,
|
|
likedNotebookData: undefined,
|
|
container: undefined
|
|
});
|
|
ReactDOM.render(galleryViewerComponent.render(), document.getElementById("galleryContent"));
|
|
};
|
|
|
|
// Entry point
|
|
window.addEventListener("load", onInit);
|