Modern Angular applications can be built from standalone components that declare their own dependencies, without a central NgModule.

Importing directly in the component. Instead of registering StimulsoftViewerModule in a module, list it in the component's own imports array:
import { Component } from '@angular/core';
import { StimulsoftViewerModule } from 'stimulsoft-viewer-angular';

@Component({
    selector: 'app-root',
    imports: [StimulsoftViewerModule],
    templateUrl: './app.component.html',
    styleUrl: './app.component.css'
})
export class AppComponent {
    title = 'viewer';
}

Using the component in the template. The viewer itself is used exactly as in a module-based application:
<stimulsoft-viewer-angular
    [requestUrl]="'/Viewer/{action}'"
    [action]="'InitViewer'"
    [height]="'100vh'">
</stimulsoft-viewer-angular>

The server side is identical to the basic integration — a controller with the InitViewer, GetReport and ViewerEvent actions supplies the options and the report.

By using this website, you agree to the use of cookies for analytics and personalized content. Cookies store useful information on your computer to help us improve efficiency and usability. For more information, please read the privacy policy and cookie policy.