• Stars
    star
    168
  • Rank 225,466 (Top 5 %)
  • Language
    JavaScript
  • License
    MIT License
  • Created about 8 years ago
  • Updated 7 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Ignite UI components for React

Ignite UI Component Wrappers for React

Node.js CI Coverage Status npm version

Use the declarations available in igniteui-react.js (or igniteui-react.min.js) to use Ignite UI controls as React components. Work with the running samples here.

IMPORTANT The package and repository have been renamed from igniteui-react to igniteui-react-wrappers. There is a new product Ignite UI for React from Infragistics that you may want to consider when starting your next React project. It features a high-performance data grid, high-volume data charts and a complete Microsoft Excel Solution. Please check out the announcement here.

Requirements

Install

You can install the package with npm.

npm install igniteui-react-wrappers

Build

The build will bundle all files available in src/* producing dist/npm/igniteui-react.js and then minify it producing dist/npm/igniteui-react.min.js. Either can be used for obtaining the Ignite UI React components, however, the minified file is preferable for production due to its reduced size. You need Node.js installed on your machine.

To build the project use the following steps:

  1. Open a console in the folder where the igniteui-react-wrappers project is located
  2. run npm install
  3. run npm run build

igniteui-react-wrappers depends on the ignite-ui-full licensed package. Follow this guide on setting up access to the Ignite UI private npm feed and add the dependency to the package.json.

"dependencies": {
	"@infragistics/ignite-ui-full": "latest"
}

Getting Started

Ignite UI CLI

To get started with the Ignite UI CLI and the Ignite UI React wrappers:

npm i -g igniteui-cli
ig new <project name> --framework=react
cd <project name>
ig add combo <component name>
ig start

Page setup

In the page markup include the Ignite UI React components bundle found in dist/npm/igniteui-react.min.js along with the Ignite UI scripts:

<script src="jquery.min.js"></script>
<script src="jquery-ui.min.js"></script>
<script src="react.min.js"></script>

<script src="infragistics.core.js"></script>
<script src="infragistics.lob.js"></script>

<script src="igniteui-react.min.js"></script>

Optionally include browser.js found in the Babel-core package for JSX support.

<script src="browser.js"></script>

This provides all supported Ignite UI components as React classes available in the global namespace.

Initializing controls

In general React components can be initialized in two ways:

  1. In JavaScript using React's API.
  2. With pseudo-markup by utilizing JSX syntax.

Examples:

Control Name JavaScript JSX
igCombo React.createElement(IgCombo, null); <IgCombo/>
igGrid React.createElement(IgGrid, null); <IgGrid/>
igTreeGrid React.createElement(IgTreeGrid, null); <IgTreeGrid/>
igDataChart React.createElement(IgDataChart, null); <IgDataChart/>
igDialog React.createElement(IgDialog, null); <IgDialog/>
igDateEditor React.createElement(IgDateEditor, null); <IgDateEditor/>
igMaskEditor React.createElement(IgMaskEditor, null); <IgMaskEditor/>
igNumericEditor React.createElement(IgNumericEditor, null); <igNumericEditor/>
igPercentEditor React.createElement(IgPercentEditor, null); <igPercentEditor/>
igTextEditor React.createElement(IgTextEditor, null); <igTextEditor/>
igDatePicker React.createElement(IgDatePicker, null); <igDatePicker/>
igTree React.createElement(IgTree, null); <igTree/>
igMap React.createElement(IgMap, null); <igMap/>
igUpload React.createElement(IgUpload, null); <igUpload/>
igVideoPlayer React.createElement(IgVideoPlayer, null); <igVideoPlayer/>

Note: All Ignite UI React class names are in PascalCase so that they are JSX-friendly.

Configuring Control Options

If you are using JavaScript options can be applied by adding them as an object to the createElement call. In JSX they are represented by attributes to the component's pseudo-element.

Examples:

Option JavaScript JSX
igGrid.options.autoGenerateColumns React.createElement(IgGrid, { autoGenerateColumns: false }); <IgGrid autoGenerateColumns={false} />
igCombo.options.width React.createElement(IgCombo, { width: "700px" }); <IgCombo width="700px" />

Defining complex type control options (arrays & objects) in JSX is done by wrapping their declarations braces {}.

Example:

<IgGrid
	id="grid1"
	columns={[
		{ headerText: "Product ID", key: "ProductID", dataType: "number" },
		{ headerText: "Stock", key: "UnitsInStock", dataType: "number" },
		{ headerText: "Description", key: "ProductDescription", dataType: "string" },
		{ headerText: "UnitPrice", key: "UnitPrice", dataType: "number", format: "#.##" },
		{ headerText: "DateAdded", key: "DateAdded", dataType: "date", format: "dateTime" }
	]}
/>

Note: Some Ignite UI controls require an id attribute for the DOM element they initialize on. It can be passed through the control's React class id property.

Updating options

Option updates during runtime can be achieved by using React's setState method. Some of Ignite UI widgets options are not settable at runtime. For these, prop changes have no effect.

Example:

var App = createReactClass({
	getInitialState: function () {
		return {
			alternateRowStyles: true
		}
	},
	render: function () {
		return (
			<div>
				<IgGrid
					id="grid1"
					autoGenerateColumns={true}
					dataSource={sourceData}
					alternateRowStyles={this.state.alternateRowStyles}
				/>
				<button onClick={this.buttonClick}>Change</button>
			</div>
		);
	},
	buttonClick: function (evt) {
		this.setState({ alternateRowStyles: !this.state.alternateRowStyles });
	}
});

Handling events

Binding to control events is done by passing the event name as a property and assigning the handling function as its value.

Example:

<IgTextEditor
	id="editor1"
	valueChanged={this.editorValueChanged}
/>

In addition to the events available for each Ignite UI widget the React controls will also invoke the function passed for the initialized property when the widget is ready for use.

Example:

<IgTextEditor
	id="editor1"
	initialized={this.controlInitialized}
/>

Calling widget methods

Calling widget methods can be done in two ways both utilizing functions available in the $.ig.react.core namespace. You can either obtain the widget's instance using the React component and its name directly.

Example:

	$.ig.react.core.getWidgetInstance(gridComponent, "igGrid").commit();

Or get the DOM element it is initialized on and calling the method through jQuery UI's plugin.

Example:

	$.ig.react.core.getElement(gridComponent).igGrid("commit");

Running our samples:

Go to the folder of the sample you want to run:

npm install
npm start

Alternatively you can view them from here.

Testing

Testing IgniteUI React is done through Unit tests. All of them are written in Jasmine.

Setup

npm install

Running the tests

The easiest way to run the unit tests is to use the npm script:

npm test

This will start the Karma test runner and execute the tests. By default the browser is Chrome.

Code coverage

After running the Karma test a coverage file will be created for the src/util/ignite-react.js file containing the bulk of the functionality available for the Ignite UI React components. The report is available at coverage/karma-tmp/**/lcov-report/.


What is Ignite UI?

Ignite UI Logo

Ignite UI is an advanced HTML5+ toolset that helps you create stunning, modern Web apps. Building on jQuery and jQuery UI, it primarily consists of feature rich, high-performing UI controls/widgets such as all kinds of charts, data visualization maps, (hierarchical, editable) data grids, pivot grids, enhanced editors (combo box, masked editors, HTML editor, date picker, to name a few), flexible data source connectors, and a whole lot more. Too many to list here - check out the site for more info and to download a trial.

Ignite UI is not just another library created in someone's free time. It is commercial-ready, extremely well-tested, tuned for top performance, designed for good UX, and backed by Infragistics, an experience-focused company with a track record of over 24 years of experience in providing enterprise-ready, high-performance user interface tools for web, windows and mobile environments.

Infragistics Logo

More Repositories

1

igniteui-angular

Ignite UI for Angular is a complete library of Angular-native, Material-based Angular UI components with the fastest grids and charts, Pivot Grid, Dock Manager, Hierarchical Grid, and more.
TypeScript
571
star
2

ignite-ui

Ignite UI for jQuery by Infragistics
JavaScript
477
star
3

igniteui-angular-wrappers

Ignite UI Angular component extensions by Infragistics
TypeScript
148
star
4

igniteui-cli

Ignite UI Command-Line Interface by Infragistics
TypeScript
118
star
5

igniteui-webcomponents

Ignite UI for Web Components is a complete library of UI components, giving you the ability to build modern web applications using encapsulation and the concept of reusable components in a dependency-free approach.
TypeScript
117
star
6

igniteui-angularjs

Ignite UI extensions for AngularJS
JavaScript
106
star
7

app-builder

App Builder™ is a cloud-based WYSIWYG drag & drop tool that helps teams design and build complete business apps 80% faster than before. It has an integrated design system – Indigo.Design – and packs real UI components for Angular, Blazor, and Web Components.
86
star
8

igniteui-angular-ui-kits

UI Kits for Ignite UI for Angular
85
star
9

warehouse-js-blocks

Sample Warehousing application built with Ignite UI for Angular
TypeScript
81
star
10

crypto-portfolio-app

Application that uses Ignite UI for Angular components along with Firebase data storage and a lot more ..
TypeScript
75
star
11

help-topics

Ignite UI Help Topics
JavaScript
42
star
12

igniteui-dockmanager

Ignite UI Dock Manager Web Component provides means to manage the layout of your application.
37
star
13

igniteui-angular-samples

Ignite UI for Angular demos for all available components and features
TypeScript
36
star
14

igniteui-docfx

Ignite UI for Angular topics for all available components and features
JavaScript
29
star
15

marketing-dashboard-sample

The Marketing Dashboard sample makes use of the Ignite UI date picker, data chart, map, doughnut chart and bullet graph controls to tackle specific analytical challenges. The dashboard view brings together different data points a marketing expert would want to track like sessions, conversions and conversion costs.
JavaScript
24
star
16

COVID-19-Dashboard

COVID-19 spread and data dashboard built with Ignite UI for Angular
TypeScript
21
star
17

typedoc-plugin-localization

TypeScript
20
star
18

finance-sample

The Finance Dashboard sample demonstrates the data chart, combo, dialog, and zoom bar controls for the Financial Services industry. The data chart is optimized for high-speed financial charting. This sample uses large datasets with millions of data points and real-time updates. The data chart enables key statistical and technical indicators and comparisons to key competitors.
JavaScript
16
star
19

project-management-dashboard-sample

The Project Management Dashboard sample showcases jQuery controls like the doughnut chart and the hierarchical grid to represent task progress and time allocation. This sample even combines the grid and linear gauge to help users easily identify risks and adjust project plans accordingly.
JavaScript
16
star
20

material-icons-extended

A subset of icons that extends the official Material Design Icons by Google.
TypeScript
15
star
21

er-dashboard-sample

The ER Dashboard sample demonstrates the capabilities of multiple Ignite UI controls working together into a single complex view designed for mobile tablet devices. The main part of the sample is several charts displaying different kinds of information about patients admitted to the emergency ward of a hospital. The sample shows how the same information can be displayed in a grid and how to switch between views. Combo boxes are used to select different medical parameters to be displayed dynamically update the data behind the charts. Additional buttons let you change the chart visualization with the same data.
JavaScript
14
star
22

ng-conf-2020-workshop

TypeScript
13
star
23

igniteui-blazor-examples

samples browser app and individual samples on how to use Ignite UI for Blazor components
C#
12
star
24

personal-finance-sample

The Personal Finance Dashboard sample demonstrates the chart controls from the Ignite UI library acting together with grids, combo boxes and editors in a complex application. The sample is designed with mobile tablet devices in mind taking into account screen size and performance. The view displays several aspects of personal finances in graphic and tabular form separated into panels. It shows selecting different periods of time changes the data behind a chart and how to dynamically change the data series rendered by a chart.
JavaScript
12
star
25

igniteui-theming

A set of Sass mixins, functions, and variables used to create themes for a variety of UI frameworks built by Infragistics.
SCSS
11
star
26

igniteui-react-examples

samples browser app and individual samples on how to use Ignite UI for React components
TypeScript
11
star
27

igniteui-xplat-docs

cross-platform docs for Ignite UI for Angular, Blazor, React, and WebComponents
TypeScript
10
star
28

personal-health-tracker-sample

The Personal Health Tracker sample demos using Ignite UI inside the PhoneGap framework for native-like, installed app experiences.
JavaScript
9
star
29

autosales-dashboard-sample

The Auto Sales Tracking sample is an example application showcasing some of the most powerful Ignite UI controls including the map, grid, and various charts. The map control shows the geographical region represented in the sales data. Bullet graphs, data charts, and pie charts show sales figures over time and in relation to target figures. Sales are detailed using the grid control by dealership and manufacturer and bullet graphs embedded in the grid provide glanceable sales summaries. The application demonstrates how Ignite UI controls are used together to build an immersive and attractive user experience.
JavaScript
9
star
30

igniteui-typedoc-theme

infragistics typedoc theme
TypeScript
8
star
31

indigo-design-docfx

JavaScript
8
star
32

igniteui-wc-examples

samples browser app and individual samples on how to use Ignite UI for Web Components
TypeScript
7
star
33

generator-igniteui

A Yeoman (http://yeoman.io) generator for Ignite UI.
HTML
7
star
34

igniteui-docfx-template

TypeScript
7
star
35

igniteui-react

High-Performance Data Grid and High-Volume Data Charts
6
star
36

TaskPlanner

Task Planner app created with Ignite UI For Angular
TypeScript
6
star
37

igniteui-angular-i18n

Moved to https://github.com/IgniteUI/igniteui-angular/tree/master/projects/igniteui-angular-i18n
TypeScript
5
star
38

finjs-web-api

C#
4
star
39

sassdoc-plugin-localization

Plugin localization for sassdoc documentation
TypeScript
4
star
40

igniteui-live-editing-samples

This repository is used for StackBlitz and CodeSandbox config samples
TypeScript
4
star
41

ignite-ui-IntelliSense-for-VS-Code

Ignite UI IntelliSense extension
TypeScript
3
star
42

ignite-ui-bower

Less
3
star
43

dock-manager-electron-app

Dock Manager Electron App
TypeScript
3
star
44

ERDashboard-Angular

ER Dashboard in Angular
TypeScript
3
star
45

ig-editor

TypeScript
3
star
46

igniteui-angular-examples

angular sample browser with stand-alone sample projects
JavaScript
3
star
47

igniteui-blazor

Ignite UI for Blazor component library packs 35+ native Blazor UI Controls with 60+ high-performance Charts designed for any Blazor WASM or Server-side app scenario.
3
star
48

help-samples-src

JavaScript
3
star
49

NorthwindAPI

C#
3
star
50

igniteui-xplat-examples

C#
3
star
51

igniteui-theme-service

Ignite UI theme service will serve your app with a theme in CSS or SASS format
3
star
52

Stackblitz-IgniteuiAngular-Startup-Project

TypeScript
2
star
53

create-webcomponents-ts-app

generator for a vanilla TS Web Components app.
JavaScript
2
star
54

app-builder-docfx

JavaScript
2
star
55

InventoryManagementApp

TypeScript
2
star
56

ig-pkg-html

Base HTML package for Ignite UI Web Designer.
JavaScript
2
star
57

world-stats-sample

The WorldStats application sample shows the amazing Motion Framework of the Ignite UI Data Chart control that animates data over time to provide users with an extra layer of temporal insight into their data. This sample gives users rich insight into statistical data about all countries in the world by leveraging the Ignite UI Data Chart, Data Grid, Dialog Window, and more. Each chart supports zooming and drag-to-zoom, along with multiple series, series, types, and scales.
JavaScript
2
star
58

app-builder-client

1
star
59

DockManager-DataAnalysis

TypeScript
1
star
60

HRApplication

C#
1
star
61

ng-universal-example

HTML
1
star
62

igniteui-angular-marketing-dashboard

TypeScript
1
star
63

ASP.NET-Core-Samples

The repository consists of samples using the Ignite UI For Javascript library in a context of ASP.NET Core Web Application.
C#
1
star
64

ig-pkg-bootstrap

Bootstrap package for the Ignite UI Web designer.
JavaScript
1
star
65

igniteui-angular-api-i18n

1
star
66

ig-pkg-igniteui

Ignite UI package for the Ignite UI Web designer.
JavaScript
1
star
67

ig-typedoc-theme

Feel and look of Infragistics API documentation with internationalization
TypeScript
1
star