Basic Viewport App
Copyright © 2019 Bentley Systems, Incorporated. All rights reserved.
An iModel.js sample application that demonstrates the minimum setup for opening an iModel and viewing its graphics in a viewport with basic viewing tools.
- Viewport: Renders geometric data onto an HTMLCanvasElement.
- Toolbar: Includes basic viewport tools in top-right corner of viewport (select, fit, rotate, pan, zoom).
This app serves as a guide on how you can embed one or more of these components into your own application. See http://imodeljs.org for comprehensive documentation on the iModel.js API and the various constructs used in this sample.
The purpose of this application is to demonstrate the following:
- Dependencies required for iModel.js-based frontend applications.
- Scripts recommended to build and run iModel.js-based applications.
- How to set up a simple backend for web and
- How to set up a simple frontend for web.
- How to implement OIDC sign-in to get access to iModels on iModelHub.
- How to consume iModel.js React components.
- How to setup a viewport.
- How to include tools in a viewport.
Follow the App Development Setup section under Sample Interactive Apps to configure, install dependencies, build, and run the app.