I have a React web application and python is api layer, and we want to implement the Aspose.Cells viewer in our application. Specifically, we want to show XLSX or XLS files in the viewer (i.e., browser) with editable capabilities. I would like to know clear details about GridJS and GridWeb in Aspose, and which one is better to integrate into our application for viewing the files in the browser.
I need information about GridJS and GridWeb in Aspose, including when and where to use them, and how to use them.
@sarathepiq
To implement an Excel viewer in your React web application using Aspose.Cells, you have two options: GridJS and GridWeb. Below, I will provide an overview of both options, including their features, when to use them, and how to integrate them into your application.
Aspose.Cells.GridJS
GridJS is designed for viewing and editing spreadsheet files through JSON operations. It provides a more modern and flexible approach to handling spreadsheets in web applications. Here are some key features:
- Lightweight: GridJS is a lightweight solution that allows for easy integration into web applications.
- JSON Operations: It uses JSON for data operations, making it suitable for modern web frameworks like React.
- Custom Calculation Engine: You can extend the default calculation engine with your custom logic.
- API Classes: GridJS includes various classes for configuration, calculation, and workbook management, allowing for extensive customization.
When to Use GridJS:
- If you need a modern, responsive interface for spreadsheet viewing and editing.
- When working with a React application, as it aligns well with the JSON-based data handling.
Basic Integration Example:
To integrate GridJS into your application, you would typically set up a controller in your backend to handle requests and serve the necessary JSON data to the GridJS component in your React frontend.
Aspose.Cells.GridWeb
GridWeb is a more traditional ASP.NET-based solution for displaying and editing Excel files in a web browser. It is a server-side component that renders spreadsheets directly in the browser.
Key Features:
- Rich UI: GridWeb provides a rich user interface similar to Excel, making it user-friendly.
- Server-Side Processing: It handles most of the processing on the server, which can be beneficial for larger files or complex operations.
- Comprehensive Features: It supports a wide range of Excel features, including formulas, charts, and formatting.
When to Use GridWeb:
- If you are working in a traditional ASP.NET environment and prefer server-side processing.
- When you need comprehensive Excel features and a familiar interface for users.
Basic Integration Example:
To use GridWeb, you would typically add it to your ASP.NET project and configure it to load and display Excel files directly.
Conclusion
For your React application with a Python API layer, GridJS is likely the better choice due to its modern architecture and compatibility with JSON data handling. It allows for a more seamless integration with your frontend framework. However, if you are looking for a more traditional approach with rich Excel features, GridWeb might be suitable if you are willing to work within an ASP.NET context.
For further details on the classes and methods available in each option, you can refer to the official documentation for GridJS and GridWeb.
Sources
[1]: Aspose.Cells.GridJs | Aspose.Cells for .NET API Reference
[2]: Aspose.Cells.GridWeb | Aspose.Cells for .NET API Reference
Is there any way to implement to Grid js with out ASP.net and java.
Can we implement in JavaScript completely?
@sarathepiq,
GridJs may not parse .xlsx
or .xls
files directly in the browser, it relies on underlying component to convert the Excel workbook into a JSON format that the JS frontend can render. Apparently, you might not use Aspose.Cells.GridJs as a 100% JavaScript-only (frontend-only) solution directly, it requires backend processing as well. Anyways, we will evaluate it in details and get back to you soon.
@sarathepiq
GridJs renders the ui using html canvas. GridWeb renders the ui using html dom. Both of them are using server side process and client side js.
GridJs has better performance. We also have Python demo for GridJs.
so our suggestion is you can use GridJs.