jQuery Calx - Interactive Examples

Welcome! jQuery Calx is a powerful jQuery plugin that turns your HTML into a spreadsheet-like calculation engine. Explore the examples below to see what you can build with it.

๐Ÿ“š Getting Started

๐ŸŽฏ Basic Example

Learn the fundamentals of jQuery Calx with simple calculations. Perfect for beginners to understand data-cell and data-formula attributes.

View Example โ†’

๐Ÿ”ข Data Types

Explore how jQuery Calx handles different data types including numbers, text, dates, and booleans with automatic type conversion.

View Example โ†’

๐Ÿ“‹ Dynamic Forms

Build dynamic forms that add and remove rows on the fly while maintaining calculations across all elements.

View Example โ†’

๐ŸŽจ Advanced Features

๐Ÿ’ฐ Formatters & Input Masks

Master value formatting with currency, percent, and number formatters. Includes input-mask behavior and conditional styling for negative values.

View Example โ†’

๐Ÿ“Š Multiple Sheets

Work with multiple calculation sheets and reference cells across sheets using Sheet1!A1 notation.

View Example โ†’

๐Ÿ  Mortgage Calculator

Real-world complex example with PMT function, named variables, currency formatting, and amortization schedule. Perfect for understanding advanced calculations!

View Example โ†’

๐Ÿš€ Advanced Features

Explore complex formulas, named ranges, custom functions, and advanced calculation patterns for real-world applications.

View Example โ†’

๐Ÿงช Testing & Development

โœ… Test Suite

Comprehensive test suite demonstrating various formulas, functions, and edge cases with expected results.

View Tests โ†’

๐Ÿ”ง Auto CALX Addresses

Test automatic cell address assignment for elements with data-formula but no data-cell attribute.

View Test โ†’

โš™๏ธ Create Cell API

Test the programmatic cell creation and manipulation API for building dynamic spreadsheets.

View Test โ†’

โœจ Key Features

๐Ÿ“

Excel-Like Formulas

Support for 300+ functions including SUM, AVERAGE, IF, VLOOKUP, and more

๐ŸŽฏ

Cell References

Use A1, B2 notation or named variables like TAX, TOTAL in your formulas

๐Ÿ’ฑ

Smart Formatters

Currency, percent, number formatting with intelligent input parsing

๐ŸŽจ

Conditional Styling

Apply CSS styles based on cell values (e.g., red for negative numbers)

๐Ÿ”„

Auto-Calculate

Formulas recalculate automatically when dependent values change

๐Ÿ“Š

Multiple Sheets

Create workbooks with multiple sheets and cross-sheet references

๐Ÿš€ Quick Start

HTML Setup

<!-- Include jQuery and Calx -->
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
<script src="dist/jquery.calx.js"></script>

<!-- Create a form with calculations -->
<form id="calculator">
    <input data-cell="A1" value="100">
    <input data-cell="A2" value="50">
    <input data-formula="A1+A2" readonly>
</form>

<!-- Initialize Calx -->
<script>
    $('#calculator').calx({ autoCalculate: true });
</script>

Features at a Glance