Set up the report viewer in React, load a template, and connect the component to the application.

Viewer setup. Configure the viewer, load the report, assign it to the component, and process the requests or events raised by the UI.
import { Viewer, Stimulsoft } from 'stimulsoft-reports-js-react/viewer';

function App() {
    var report = new Stimulsoft.Report.StiReport();
    report.loadFile('Reports/SimpleList.mrt');

    var viewerOptions = new Stimulsoft.Viewer.StiViewerOptions();
    viewerOptions.appearance.fullScreenMode = true;

    Stimulsoft.Base.Localization.StiLocalization.setLocalizationFile('Localizations/pt.xml');

    return <Viewer options={viewerOptions} report={report} />;
}
StiLocalization.setLocalizationFile loads the language file for the whole Stimulsoft interface. The localization files are shipped with the product and can be edited or created, so the viewer can speak any language you need.

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.