diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000000..9d08a1a828 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,9 @@ +root = true + +[*] +charset = utf-8 +indent_style = space +indent_size = 2 +end_of_line = lf +insert_final_newline = true +trim_trailing_whitespace = true diff --git a/.eslintrc.js b/.eslintrc.js deleted file mode 100644 index 62859ad4b5..0000000000 --- a/.eslintrc.js +++ /dev/null @@ -1,3 +0,0 @@ -module.exports = { - extends: 'react-tools' -} diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000000..5a0d5e480b --- /dev/null +++ b/.gitattributes @@ -0,0 +1,2 @@ +# Auto detect text files and perform LF normalization +* text=auto eol=lf diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml new file mode 100644 index 0000000000..e2ea8ad3b9 --- /dev/null +++ b/.github/FUNDING.yml @@ -0,0 +1,3 @@ +# These are supported funding model platforms + +github: tannerlinsley diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml new file mode 100644 index 0000000000..67bf29eb62 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -0,0 +1,100 @@ +name: '🐛 Bug report' +description: Report a reproducible bug or regression +body: + - type: markdown + attributes: + value: | + Thank you for reporting an issue :pray:. + + This issue tracker is for reporting reproducible bugs or regression's found in [react-table](https://github.com/tanstack/table) + If you have a question about how to achieve or implement something and are struggling, please post a question + inside of react-table's [Discussions tab](https://github.com/tanstack/table/discussions) instead of filing an issue. + + Before submitting a new bug/issue, please check the links below to see if there is a solution or question posted there already: + - TanStack Table's [Discussions tab](https://github.com/tanstack/table/discussions) + - TanStack Table's [Open Issues](https://github.com/tanstack/table/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc) + - TanStack Table's [Closed Issues](https://github.com/tanstack/table/issues?q=is%3Aissue+sort%3Aupdated-desc+is%3Aclosed) + + The more information you fill in, the better the community can help you. + + - type: input + id: tanstack-table-version + attributes: + label: TanStack Table version + description: | + - Please let us know the exact version of the TanStack Table framework adapter that you were using when the issue occurred. If you are using an older version, check to see if your bug has already been solved in the latest version. Please don't just put in "latest", as this is subject to change. + - The latest "table-core" version is + placeholder: | + e.g. v8.11.6 + validations: + required: true + + - type: input + id: framework-library-version + attributes: + label: Framework/Library version + description: Which framework and what version of that framework are you using? + placeholder: | + e.g. React v17.0.2 + validations: + required: true + + - type: textarea + id: description + attributes: + label: Describe the bug and the steps to reproduce it + description: Provide a clear and concise description of the challenge you are running into, and the steps we should take to try to reproduce your bug. + validations: + required: true + + - type: input + id: link + attributes: + label: Your Minimal, Reproducible Example - (Sandbox Highly Recommended) + description: | + Please add a link to a minimal reproduction. + Note: + - Your bug may get fixed much faster if we can run your code and it doesn't have dependencies other than React. + - To create a shareable code example for web, you can use CodeSandbox (https://codesandbox.io/s/new) or Stackblitz (https://stackblitz.com/). + - Please make sure the example is complete and runnable without prior dependencies and free of unnecessary abstractions + - Feel free to fork any of the official CodeSandbox examples to reproduce your issue: https://github.com/tanstack/table/tree/main/examples/ + - For React Native, you can use: https://snack.expo.dev/ + - For TypeScript related issues only, a TypeScript Playground link might be sufficient: https://www.typescriptlang.org/play + - Please read these tips for providing a minimal example: https://stackoverflow.com/help/mcve. + placeholder: | + e.g. Code Sandbox, Stackblitz, TypeScript Playground, etc. + validations: + required: true + + - type: textarea + id: screenshots_or_videos + attributes: + label: Screenshots or Videos (Optional) + description: | + If applicable, add screenshots or a video to help explain your problem. + For more information on the supported file image/file types and the file size limits, please refer + to the following link: https://docs.github.com/en/github/writing-on-github/working-with-advanced-formatting/attaching-files + placeholder: | + You can drag your video or image files inside of this editor ↓ + + - type: dropdown + attributes: + options: + - No, because I do not know how + - No, because I do not have time to dig into it + - Maybe, I'll investigate and start debugging + - Yes, I think I know how to fix it and will discuss it in the comments of this issue + - Yes, I am also opening a PR that solves the problem along side this issue + label: Do you intend to try to help solve this bug with your own PR? + description: | + If you think you know the cause of the problem, the fastest way to get it fixed is to suggest a fix, or fix it yourself! However, it is ok if you cannot solve this yourself and are just wanting help. + - type: checkboxes + id: agrees-to-terms + attributes: + label: Terms & Code of Conduct + description: By submitting this issue, you agree to follow our Code of Conduct and can verify that you have followed the requirements outlined above to the best of your ability. + options: + - label: I agree to follow this project's Code of Conduct + required: true + - label: I understand that if my bug cannot be reliable reproduced in a debuggable environment, it will probably not be fixed and this issue may even be closed. + required: true diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 0000000000..963fe444ec --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1,11 @@ +blank_issues_enabled: false +contact_links: + - name: 🤔 Feature Requests & Questions + url: https://github.com/TanStack/table/discussions + about: Please ask and answer questions here. + - name: 💬 Community Chat + url: https://discord.gg/mQd7egN + about: A dedicated discord server hosted by TanStack + - name: 🦋 TanStack Bluesky + url: https://bsky.app/profile/tanstack.com + about: Stay up to date with new releases of our libraries diff --git a/.github/pull_request_template b/.github/pull_request_template new file mode 100644 index 0000000000..2c10bc7d7d --- /dev/null +++ b/.github/pull_request_template @@ -0,0 +1,8 @@ +## 🎯 Changes + + + +## ✅ Checklist + +- [ ] I have followed the steps in the [Contributing guide](https://github.com/TanStack/table/blob/main/CONTRIBUTING.md). +- [ ] I have tested this code locally with `pnpm test:pr`. diff --git a/.github/workflows/autofix.yml b/.github/workflows/autofix.yml new file mode 100644 index 0000000000..e3bc82ecfd --- /dev/null +++ b/.github/workflows/autofix.yml @@ -0,0 +1,31 @@ +name: autofix.ci # needed to securely identify the workflow + +on: + pull_request: + push: + branches: [main, alpha, beta, rc] + +concurrency: + group: ${{ github.workflow }}-${{ github.event.number || github.ref }} + cancel-in-progress: true + +permissions: + contents: read + +jobs: + autofix: + name: autofix + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v6.0.1 + with: + fetch-depth: 0 + - name: Setup Tools + uses: tanstack/config/.github/setup@main + - name: Fix formatting + run: pnpm format + - name: Apply fixes + uses: autofix-ci/action@dd55f44df8f7cdb7a6bf74c78677eb8acd40cd0a + with: + commit-message: 'ci: apply automated fixes' diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml new file mode 100644 index 0000000000..698c3b0a35 --- /dev/null +++ b/.github/workflows/pr.yml @@ -0,0 +1,55 @@ +name: PR + +on: + pull_request: + paths-ignore: + - 'docs/**' + - 'media/**' + - '**/*.md' + +concurrency: + group: ${{ github.workflow }}-${{ github.event.number || github.ref }} + cancel-in-progress: true + +env: + NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }} + +permissions: + contents: read + +jobs: + test: + name: Test + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v6.0.1 + with: + fetch-depth: 0 + - name: Start Nx Agents + run: npx nx-cloud start-ci-run --distribute-on=".nx/workflows/dynamic-changesets.yaml" + - name: Setup Tools + uses: tanstack/config/.github/setup@main + - name: Get base and head commits for `nx affected` + uses: nrwl/nx-set-shas@v4.4.0 + with: + main-branch-name: main + - name: Run Checks + run: pnpm run test:pr --parallel=3 + - name: Stop Nx Agents + if: ${{ always() }} + run: npx nx-cloud stop-all-agents + preview: + name: Preview + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v6.0.1 + with: + fetch-depth: 0 + - name: Setup Tools + uses: tanstack/config/.github/setup@main + - name: Build Packages + run: pnpm run build:all + - name: Publish Previews + run: pnpx pkg-pr-new publish --pnpm --compact './packages/*' --template './examples/*/*' diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000000..c44687d853 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,49 @@ +name: Release + +on: + workflow_dispatch: + inputs: + tag: + description: override release tag + required: false + push: + branches: [main, alpha, beta, rc] + +concurrency: + group: ${{ github.workflow }}-${{ github.event.number || github.ref }} + cancel-in-progress: true + +env: + NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }} + +permissions: + contents: write + id-token: write + +jobs: + release: + name: Release + if: github.repository_owner == 'TanStack' + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v6.0.1 + with: + fetch-depth: 0 + - name: Start Nx Agents + run: npx nx-cloud start-ci-run --distribute-on=".nx/workflows/dynamic-changesets.yaml" + - name: Setup Tools + uses: tanstack/config/.github/setup@main + - name: Run Tests + run: pnpm run test:ci --parallel=3 + - name: Stop Nx Agents + if: ${{ always() }} + run: npx nx-cloud stop-all-agents + - name: Publish + run: | + git config --global user.name 'Tanner Linsley' + git config --global user.email 'tannerlinsley@users.noreply.github.com' + pnpm run cipublish + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + TAG: ${{ inputs.tag }} diff --git a/.gitignore b/.gitignore index 2ed1802ff3..003c036732 100644 --- a/.gitignore +++ b/.gitignore @@ -1,8 +1,57 @@ -node_modules/ -lib/ -docs/build -react-table.js -react-table.css -*.log + +# See https://help.github.com/ignore-files/ for more about ignoring files. + +# dependencies +node_modules +package-lock.json +yarn.lock + +# builds +build +dist +lib +es +artifacts +.rpt2_cache +coverage +*.tgz + +# misc +.DS_Store +.env +.env.local +.env.development.local +.env.test.local +.env.production.local +.next +.svelte-kit + +npm-debug.log* +yarn-debug.log* +yarn-error.log* +.history +size-plugin.json +stats-hydration.json +stats-react.json +stats.html +.vscode/settings.json .idea + +*.log .DS_Store +.cache +.idea +.pnpm-store + +package-lock.json +yarn.lock +*.tsbuildinfo +*.tsbuildinfo + +.svelte-kit +.nx/cache +.nx/workspace-data +vite.config.js.timestamp-* +vite.config.ts.timestamp-* + +.angular diff --git a/.npmrc b/.npmrc new file mode 100644 index 0000000000..268c392d3c --- /dev/null +++ b/.npmrc @@ -0,0 +1 @@ +provenance=true diff --git a/.nvmrc b/.nvmrc new file mode 100644 index 0000000000..b404027604 --- /dev/null +++ b/.nvmrc @@ -0,0 +1 @@ +24.8.0 diff --git a/.nx/workflows/dynamic-changesets.yaml b/.nx/workflows/dynamic-changesets.yaml new file mode 100644 index 0000000000..d3536f3ba7 --- /dev/null +++ b/.nx/workflows/dynamic-changesets.yaml @@ -0,0 +1,4 @@ +distribute-on: + small-changeset: 3 linux-medium-js + medium-changeset: 6 linux-medium-js + large-changeset: 10 linux-medium-js diff --git a/.prettierignore b/.prettierignore new file mode 100644 index 0000000000..63dd7224e6 --- /dev/null +++ b/.prettierignore @@ -0,0 +1,12 @@ +**/.nx/ +**/.nx/cache +**/.svelte-kit +**/build +**/coverage +**/dist +**/docs +**/old-examples +**/examples/**/*.svelte +pnpm-lock.yaml + +.angular diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 04f1d52d7e..0000000000 --- a/.travis.yml +++ /dev/null @@ -1,4 +0,0 @@ -language: node_js -node_js: - - "6" -script: npm test diff --git a/.vscode/extensions.json b/.vscode/extensions.json new file mode 100644 index 0000000000..1d7ac851ea --- /dev/null +++ b/.vscode/extensions.json @@ -0,0 +1,3 @@ +{ + "recommendations": ["dbaeumer.vscode-eslint", "esbenp.prettier-vscode"] +} diff --git a/CHANGELOG.md b/CHANGELOG.md deleted file mode 100644 index 97184ce132..0000000000 --- a/CHANGELOG.md +++ /dev/null @@ -1,119 +0,0 @@ -## 6.7.5 -#### Fixes & Optimizations -- Now passes `column` to `getResizerProps` (#667) -- NOTE: `getResizerProps` is now only called if the column is resizable -- Fixes the `className` ordering in defaultProps for ThComponent (#673) -- NOTE: user supplied classNames now come at the end so they can extend the defaults - -## 6.7.4 -#### Fixes & Optimizations -- Fix Prop types for columns - -## 6.7.3 -#### Fixes & Optimizations -- Fix the rest of the proptypes - -## 6.7.2 -#### Fixes & Optimizations -- `getPropTypes` proptype check - -## 6.7.1 -#### Fixes & Optimizations -- `eslint-config` moved to dev deps - -## 6.7.0 -## 6.7.0-alpha-0 -#### New Features -- Expose page/pageSize to rows/cells -- Supply sort direction to custom sort methods - -#### Fixes & Optimizations -- README updates -- Linter cleanup -- Added PropTypes node module -- Deps, linting and style upgrades - -## 6.6.0 -#### Fixes & Optimizations -- moved repo to react-tools -- Doc examples moved to codesandbox.io -- README updates -- CSS refacting for rt-tfoot to match rt-thead -- CSS more specific for input and select - -## 6.5.3 -#### Fixes & Optimizations -- `onClick` proxying and eslint - -## 6.5.2 -#### New Features -- Provide onClick handleOriginal function - #406 - -#### Fixes & Optimizations -- README updates -- `makePathArray` in utils - #326 -- Various fixes: #294, #376, #398, #415, - -## 6.5.1 -#### Fixes & Optimizations -- `defaultExpanded` now works correctly - #372 -- `column.getProps().rest` props are now applied correctly -- `makeTemplateComponent` now supports `displayName` - #289 - -## 6.5.0 -##### New Features -- `column.filterAll` - defaults to `false`, but when set to `true` will provide the entire array of rows to `filterMethod` as opposed to one row at a time. This allows for more fine-grained filtering using any method you can dream up. See the [Custom Filtering example](https://react-table.js.org/#/story/custom-filtering) for more info. - -## 6.4.0 -##### New Features -- `PadRowComponent` - the content rendered inside of a padding row. Defaults to a react component that renders ` ` - -## 6.3.0 -##### New Features -- `defaultSortDesc` - allows you to set the default sorting direction for all columns to descending. -- `column.defaultSortDesc` - allows you to set the default sorting direction for a specific column. Falls back to the global `defaultSortDesc` when not set at all. - -## 6.0.0 - -##### New Features -- New Renderers: - - `Aggregated` - Custom renderer for aggregated cells - - `Pivot` - Custom renderer for Pivoted Cells (utilizes `Expander` and `PivotValue`) - - `PivotValue` - Custom renderer for Pivot cell values (deprecates the undocumented `pivotRender` option) - - `Expander` - Custom renderer for Pivot cell Expander -- Added custom sorting methods per table via `defaultSortMethod` and per column via `column.sortMethod` -- Pivot columns are now visibly separate and sorted/filtered independently. -- Added `column.resizable` to override global table `resizable` option for specific columns. -- Added `column.sortable` to override global table `sortable` option for specific columns. -- Added `column.filterable` to override global table `filterable` option for specific columns. -- Added `defaultExpanded` table option. -- All callbacks can now be utilized without needing to hoist and manage the piece of state they export. That is what their prop counterparts are for, so now the corresponding prop is used instead of the callback to detect a "fully controlled" state. -- Prevent transitions while column resizing for a smoother resize effect. -- Disable text selection while resizing columns. - - -##### Breaking API Changes -- New Renderers: - - `Cell` - deprecates and replaces `render` - - `Header` - deprecates and replaces `header` - - `Footer` - deprecates and replaces `footer` - - `Filter`- deprecates and replaces `filterRender` -- Callbacks now provide the destination state as the primary parameter(s). This makes hoisting and controlling the state in redux or component state much easier. eg. - - `onSorting` no longer requires you to build your own toggle logic - - `onResize` no longer requires you to build your own resize logic -- Renamed `onChange` callback -> `onFetchData` which will always fire when a new data model needs to be fetched (or if not using `manual`, when new data is materialized internally). -- Renamed `filtering` -> `filtered` -- Renamed `sorting` -> `sorted` -- Renamed `expandedRows` -> `expanded` -- Renamed `resizing` -> `resized` -- Renamed `defaultResizing` -> `defaultResized` -- Renamed `defaultFiltering` -> `defaultFiltered` -- Renamed `defaultSorting` -> `defaultSorted` -- Renamed `onSortingChange` -> `onSortedChange` -- Renamed `onFilteringChange` -> `onFilteredChange` -- Renamed `onResize` -> `onResizedChange` -- Renamed `onExpandRow` -> `onExpandedChange` -- Renamed `showFilters` -> `filterable` -- Renamed `hideFilter` -> `filterable` (Column option. Note the true/false value is now flipped.) -- `cellInfo.row` and `rowInfo.row` now reference the materialize data for the table. To reference the original row, use `cellInfo.original` and `rowInfo.original` -- Removed `pivotRender` column option. You can now control how the value is displayed by overriding the `PivotValueComponent` or the individual column's `PivotValue` renderer. See [Pivoting Options Story](https://react-table.js.org/?selectedKind=2.%20Demos&selectedStory=Pivoting%20Options&full=0&down=1&left=1&panelRight=0&downPanel=kadirahq%2Fstorybook-addon-actions%2Factions-panel) for a reference on how to customize pivot column rendering. diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md new file mode 100644 index 0000000000..fa111aa2db --- /dev/null +++ b/CODE_OF_CONDUCT.md @@ -0,0 +1,81 @@ +--- +title: Code of Conduct +id: code-of-conduct +--- + +# Contributor Covenant Code of Conduct + +## Our Pledge + +In the interest of fostering an open and welcoming environment, we as +contributors and maintainers pledge to making participation in our project and +our community a harassment-free experience for everyone, regardless of age, body +size, disability, ethnicity, sex characteristics, gender identity and expression, +level of experience, education, socio-economic status, nationality, personal +appearance, race, religion, or sexual identity and orientation. + +## Our Standards + +Examples of behavior that contributes to creating a positive environment +include: + +- Using welcoming and inclusive language +- Being respectful of differing viewpoints and experiences +- Gracefully accepting constructive criticism +- Focusing on what is best for the community +- Showing empathy towards other community members + +Examples of unacceptable behavior by participants include: + +- The use of sexualized language or imagery and unwelcome sexual attention or + advances +- Trolling, insulting/derogatory comments, and personal or political attacks +- Public or private harassment +- Publishing others' private information, such as a physical or electronic + address, without explicit permission +- Other conduct which could reasonably be considered inappropriate in a + professional setting + +## Our Responsibilities + +Project maintainers are responsible for clarifying the standards of acceptable +behavior and are expected to take appropriate and fair corrective action in +response to any instances of unacceptable behavior. + +Project maintainers have the right and responsibility to remove, edit, or +reject comments, commits, code, wiki edits, issues, and other contributions +that are not aligned to this Code of Conduct, or to ban temporarily or +permanently any contributor for other behaviors that they deem inappropriate, +threatening, offensive, or harmful. + +## Scope + +This Code of Conduct applies both within project spaces and in public spaces +when an individual is representing the project or its community. Examples of +representing a project or community include using an official project e-mail +address, posting via an official social media account, or acting as an appointed +representative at an online or offline event. Representation of a project may be +further defined and clarified by project maintainers. + +## Enforcement + +Instances of abusive, harassing, or otherwise unacceptable behavior may be +reported by contacting the project team at TANNERLINSLEY@GMAIL.COM. All +complaints will be reviewed and investigated and will result in a response that +is deemed necessary and appropriate to the circumstances. The project team is +obligated to maintain confidentiality with regard to the reporter of an incident. +Further details of specific enforcement policies may be posted separately. + +Project maintainers who do not follow or enforce the Code of Conduct in good +faith may face temporary or permanent repercussions as determined by other +members of the project's leadership. + +## Attribution + +This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, +available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html + +[homepage]: https://www.contributor-covenant.org + +For answers to common questions about this code of conduct, see +https://www.contributor-covenant.org/faq diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000000..287de60920 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,53 @@ +--- +title: Contributing +id: contributing +--- + +# Contributing + +## Questions + +If you have questions about implementation details, help or support, then please use our dedicated community forum at [Github Discussions](https://github.com/tanstack/table/discussions) **PLEASE NOTE:** If you choose to instead open an issue for your question, your issue will be immediately closed and redirected to the forum. + +## Reporting Issues + +If you have found what you think is a bug, please [file an issue](https://github.com/tanstack/table/issues/new). **PLEASE NOTE:** Issues that are identified as implementation questions or non-issues will be immediately closed and redirected to [Github Discussions](https://github.com/tanstack/table/discussions) + +## Suggesting new features + +If you are here to suggest a feature, first create an issue if it does not already exist. From there, we will discuss use-cases for the feature and then finally discuss how it could be implemented. + +## Development + +Before proceeding with development, ensure you match one of the following criteria: + +- Fixing a small bug +- Fixing a larger issue that has been previously discussed and agreed-upon by maintainers +- Adding a new feature that has been previously discussed and agreed-upon by maintainers + +## Development Workflow + +- Fork this repository, we prefer the `feat-*` branch name style +- Ensure you have `pnpm` installed +- Install projects dependencies and linkages by running `pnpm install` +- Auto-build and auto-test files as you edit by running `pnpm dev` +- Implement your changes and tests +- To run examples, follow their individual directions. Usually this includes: + - cd into the example directory + - Do NOT install dependencies again or do any linking. Nx already handles this for you. Only run install from the project root. + - Starting the dev server with `pnpm dev` or `pnpm start` (from the example directory) +- To test in your own projects: + - Build/watch for changes with `pnpm build`/`pnpm dev` +- Document your changes in the appropriate documentation website markdown pages +- Commit your work and open a pull request +- Submit PR for review + +## Adding a new example + +- Clone an existing example into the appropriate `examples` directory +- Name it the example name in kebab-case +- Update the new example's package.json to match the new example name and any other details +- Check dependencies for unused packages +- Install any additional packages to the example that you may need +- Update the docs/config.json file to include the new example in the navigation sidebar +- Commit the example eg. `docs: Add example-name` diff --git a/ISSUE_TEMPLATE.md b/ISSUE_TEMPLATE.md deleted file mode 100644 index bd19e34d5a..0000000000 --- a/ISSUE_TEMPLATE.md +++ /dev/null @@ -1,14 +0,0 @@ -## What version of React-Table are you using? -Your bug may already be fixed in the latest release. Run `yarn upgrade react-table`! -Place your version here... - -## What bug are you experiencing, or what feature are you proposing? -Please include a detailed explanation here... - -## Use https://codesandbox.io/s/X6npLXPRW (by clicking the "Fork" button) to reproduce the issue. -Then paste a link to your newly forked codesandbox here... - -## What are the steps to reproduce the issue? -1. list the steps -2. to reproduce -3. the issue diff --git a/README.md b/README.md index 2a422e7d1d..4490fe2758 100644 --- a/README.md +++ b/README.md @@ -1,946 +1,117 @@ -
- React Table Logo +
+ TanStack Table
-# React Table -`react-table` is a **lightweight, fast and extendable datagrid** built for React +
- - - - - - - - - - - +
+ + npm downloads - - + + github stars - - + + bundle size +
-
-
- -[![Sponsor](https://app.codesponsor.io/embed/zpmS8V9r31sBSCeVzP7Wm6Sr/react-tools/react-table.svg)](https://app.codesponsor.io/link/zpmS8V9r31sBSCeVzP7Wm6Sr/react-tools/react-table) - -## Features -- Lightweight at 11kb (and just 2kb more for styles) -- Fully customizable (JSX, templates, state, styles, callbacks) -- Client-side & Server-side pagination -- Multi-sort -- Filters -- Pivoting & Aggregation -- Minimal design & easily themeable -- Fully controllable via optional props and callbacks -- "Why I wrote React Table and the problems it has solved for Nozzle.io" by Tanner Linsley - -## [Demos and examples](http://react-table.js.org/#/story/simple-table) - -## Versions -- This documentation is for version 6 of react-table. -- [View the Changelog](https://github.com/react-tools/react-table/blob/master/CHANGELOG.md) -- Previous versions: - - [5.x.x Readme](https://github.com/react-tools/react-table/blob/ad7d31cd3978eb45da7c6194dbab93c1e9a8594d/README.md) - -## Table of Contents -- [Installation](#installation) -- [Example](#example) -- [Data](#data) -- [Props](#props) -- [Columns](#columns) -- [Column Header Groups](#column-header-groups) -- [Custom Cell and Header and Footer Rendering](#custom-cell-header-and-footer-rendering) -- [Styles](#styles) -- [Custom Props](#custom-props) -- [Pivoting and Aggregation](#pivoting-and-aggregation) -- [Sub Tables and Sub Components](#sub-tables-and-sub-components) -- [Server-side Data](#server-side-data) -- [Fully Controlled Component](#fully-controlled-component) -- [Functional Rendering](#functional-rendering) -- [Multi-Sort](#multi-sort) -- [Filtering](#filtering) -- [Component Overrides](#component-overrides) -- [Contributing](#contributing) -- [Scripts](#scripts) -- [Used By](#used-by) - - -## Installation -1. Install React Table as a dependency -```bash -# Yarn -$ yarn add react-table - -# NPM -$ npm install react-table -``` -2. Import the `react-table` module -```javascript -// ES6 -import ReactTable from 'react-table' -// ES5 -var ReactTable = require('react-table').default -``` -3. Import styles by including `react-table.css` -```javascript -// JS (Webpack) -import 'react-table/react-table.css' -// Old-school - -``` -##### CDN -```html - - - - - - - -``` - - -## Example -```javascript -import ReactTable from 'react-table' - -render() { - const data = [{ - name: 'Tanner Linsley', - age: 26, - friend: { - name: 'Jason Maurer', - age: 23, - } - },{ - ... - }] - - const columns = [{ - Header: 'Name', - accessor: 'name' // String-based value accessors! - }, { - Header: 'Age', - accessor: 'age', - Cell: props => {props.value} // Custom cell components! - }, { - id: 'friendName', // Required because our accessor is not a string - Header: 'Friend Name', - accessor: d => d.friend.name // Custom value accessors! - }, { - Header: props => Friend Age, // Custom header components! - accessor: 'friend.age' - }] - - -} -``` - -## Data -Simply pass the `data` prop anything that resembles an array or object. Client-side sorting and pagination are built in, and your table will update gracefully as you change any props. [Server-side data](#server-side-data) is also supported! - - -## Props -These are all of the available props (and their default values) for the main `` component. -```javascript -{ - // General - data: [], - loading: false, - showPagination: true, - showPaginationTop: false, - showPaginationBottom: true - showPageSizeOptions: true, - pageSizeOptions: [5, 10, 20, 25, 50, 100], - defaultPageSize: 20, - minRows: undefined, - showPageJump: true, - collapseOnSortingChange: true, - collapseOnPageChange: true, - collapseOnDataChange: true, - freezeWhenExpanded: false, - sortable: true, - multiSort: true, - resizable: true, - filterable: false, - defaultSortDesc: false, - defaultSorted: [], - defaultFiltered: [], - defaultResized: [], - defaultExpanded: {}, - defaultFilterMethod: (filter, row, column) => { - const id = filter.pivotId || filter.id - return row[id] !== undefined ? String(row[id]).startsWith(filter.value) : true - }, - defaultSortMethod: (a, b, desc) => { - // force null and undefined to the bottom - a = (a === null || a === undefined) ? -Infinity : a - b = (b === null || b === undefined) ? -Infinity : b - // force any string values to lowercase - a = a === 'string' ? a.toLowerCase() : a - b = b === 'string' ? b.toLowerCase() : b - // Return either 1 or -1 to indicate a sort priority - if (a > b) { - return 1 - } - if (a < b) { - return -1 - } - // returning 0, undefined or any falsey value will use subsequent sorts or the index as a tiebreaker - return 0 - }, - PadRowComponent: () =>  , // the content rendered inside of a padding row - - // Controlled State Overrides (see Fully Controlled Component section) - page: undefined, - pageSize: undefined, - sorted: [], - filtered: [], - resized: [], - expanded: {}, - - // Controlled State Callbacks - onPageChange: undefined, - onPageSizeChange: undefined, - onSortedChange: undefined, - onFilteredChange: undefined, - onResizedChange: undefined, - onExpandedChange: undefined, - - // Pivoting - pivotBy: undefined, - - // Key Constants - pivotValKey: '_pivotVal', - pivotIDKey: '_pivotID', - subRowsKey: '_subRows', - aggregatedKey: '_aggregated', - nestingLevelKey: '_nestingLevel', - originalKey: '_original', - indexKey: '_index', - groupedByPivotKey: '_groupedByPivot', - - // Server-side callbacks - onFetchData: () => null, - - // Classes - className: '', - style: {}, - - // Component decorators - getProps: () => ({}), - getTableProps: () => ({}), - getTheadGroupProps: () => ({}), - getTheadGroupTrProps: () => ({}), - getTheadGroupThProps: () => ({}), - getTheadProps: () => ({}), - getTheadTrProps: () => ({}), - getTheadThProps: () => ({}), - getTheadFilterProps: () => ({}), - getTheadFilterTrProps: () => ({}), - getTheadFilterThProps: () => ({}), - getTbodyProps: () => ({}), - getTrGroupProps: () => ({}), - getTrProps: () => ({}), - getThProps: () => ({}), - getTdProps: () => ({}), - getTfootProps: () => ({}), - getTfootTrProps: () => ({}), - getTfootThProps: () => ({}), - getPaginationProps: () => ({}), - getLoadingProps: () => ({}), - getNoDataProps: () => ({}), - getResizerProps: () => ({}), - - // Global Column Defaults - column: { - // Renderers - Cell: undefined, - Header: undefined, - Footer: undefined, - Aggregated: undefined, - Pivot: undefined, - PivotValue: undefined, - Expander: undefined, - Filter: undefined, - // Standard options - sortable: undefined, // use table default - resizable: undefined, // use table default - filterable: undefined, // use table default - show: true, - minWidth: 100, - // Cells only - className: '', - style: {}, - getProps: () => ({}), - // Headers only - headerClassName: '', - headerStyle: {}, - getHeaderProps: () => ({}) - // Footers only - footerClassName: '', - footerStyle: {}, - getFooterProps: () => ({}), - filterAll: false, - filterMethod: undefined, - sortMethod: undefined, - defaultSortDesc: undefined, - }, - - // Global Expander Column Defaults - expanderDefaults: { - sortable: false, - resizable: false, - filterable: false, - width: 35 - }, - - // Global Pivot Column Defaults - pivotDefaults: {}, - - // Text - previousText: 'Previous', - nextText: 'Next', - loadingText: 'Loading...', - noDataText: 'No rows found', - pageText: 'Page', - ofText: 'of', - rowsText: 'rows', -} -``` - -You can easily override the core defaults like so: - -```javascript -import { ReactTableDefaults } from 'react-table' - -Object.assign(ReactTableDefaults, { - defaultPageSize: 10, - minRows: 3, - // etc... -}) -``` - -Or just define them as props - -```javascript - -``` - -## Columns -`` requires a `columns` prop, which is an array of objects containing the following properties - -```javascript -[{ - // Renderers - For more information, see "Renderers" section below - Cell: JSX | String | Function // Used to render a standard cell, defaults to the accessed value - Header: JSX | String | Function // Used to render the header of a column or column group - Footer: JSX | String | Function // Used to render the footer of a column - Filter: JSX | cellInfo => ( // Used to render the filter UI of a filter-enabled column - - // The value passed to onFiltersChange will be the value passed to filter.value of the filterMethod - ) - Aggregated: JSX | String | Function // Used to render aggregated cells. Defaults to a comma separated list of values. - Pivot: JSX | String | Function | cellInfo => ( // Used to render a pivoted cell - - // By default, will utilize the the PivotValue and Expander components at run time - - ), - PivotValue: JSX | String | Function // Used to render the value inside of a Pivot cell - Expander: JSX | String | Function // Used to render the expander in both Pivot and Expander cells - - // General - accessor: 'propertyName', // or Accessor eg. (row) => row.propertyName (see "Accessors" section for more details) - id: 'myProperty', // Conditional - A unique ID is required if the accessor is not a string or if you would like to override the column name used in server-side calls - sortable: boolean, // Overrides the table option - resizable: boolean, // Overrides the table option - filterable: boolean, // Overrides the table option - show: true, // can be used to hide a column - width: undefined, // A hardcoded width for the column. This overrides both min and max width options - minWidth: 100, // A minimum width for this column. If there is extra room, column will flex to fill available space (up to the max-width, if set) - maxWidth: undefined, // A maximum width for this column. - - // Special - pivot: false, - // Turns this column into a special column for specifying pivot position in your column definitions. - // The `pivotDefaults` options will be applied on top of this column's options. - // It will also let you specify rendering of the header (and header group if this special column is placed in the `columns` option of another column) - expander: false, - // Turns this column into a special column for specifying expander position and options in your column definitions. - // The `expanderDefaults` options will be applied on top of this column's options. - // It will also let you specify rendering of the header (and header group if this special column is placed in the `columns` option of another column) and - // the rendering of the expander itself via the `Expander` property - - // Cell Options - className: '', // Set the classname of the `td` element of the column - style: {}, // Set the style of the `td` element of the column - // Header & HeaderGroup Options - headerClassName: '', // Set the classname of the `th` element of the column - headerStyle: {}, // Set the style of the `th` element of the column - getHeaderProps: (state, rowInfo, column, instance) => ({}), // a function that returns props to decorate the `th` element of the column - - // Header Groups only - columns: [...], // See Header Groups section below - - // Footer - footerClassName: '', // Set the classname of the `td` element of the column's footer - footerStyle: {}, // Set the style of the `td` element of the column's footer - getFooterProps: (state, rowInfo, column, instance) => ({}), // A function that returns props to decorate the `td` element of the column's footer - - // Filtering - filterMethod: (filter, row || rows, column) => {return true}, // A function returning a boolean that specifies the filtering logic for the column - // 'filter' == an object specifying which filter is being applied. Format: {id: [the filter column's id], value: [the value the user typed in the filter field], pivotId: [if filtering on a pivot column, the pivotId will be set to the pivot column's id and the `id` field will be set to the top level pivoting column]} - // 'row' || 'rows' == the row (or rows, if filterAll is set to true) of data supplied to the table - // 'column' == the column that the filter is on - filterAll: false -}] -``` - -## Renderers -React Table supports very flexible renderers for just about everything: -- `Cell` - Renders a standard cell -- `Header` - Renders a column header or column group header -- `Footer` - Renders a column footer -- `Filter` - Renders a column's filter UI -- `Aggregated` - Renders an aggregated cell -- `Pivot` - Renders a pivoted cell (by default, will utilize `Expander` and `PivotValue` renderers) -- `PivotValue` - Renders the value inside a `Pivot` renderer -- `Expander` - Renders the Expander used in both the default `Pivot` renderer and any expander-designated column - -Any of these renderers can be one of the following: -- A React Class -- JSX or any rendered react component -- Stateless functional component -- Function that returns any primitive - -All of these formats receive the following props: -```javascript -{ - // Row-level props - row: Object, // the materialized row of data - original: , // the original row of data - index: '', // the index of the row in the original arra - viewIndex: '', // the index of the row relative to the current view - level: '', // the nesting level of this row - nestingPath: '', // the nesting path of this row - aggregated: '', // true if this row's values were aggregated - groupedByPivot: '', // true if this row was produced by a pivot - subRows: '', // any sub rows defined by the `subRowKey` prop - - // Cells-level props - isExpanded: '', // true if this row is expanded - value: '', // the materialized value of this cell - resized: '', // the resize information for this cell's column - show: '', // true if the column is visible - width: '', // the resolved width of this cell - maxWidth: '', // the resolved maxWidth of this cell - tdProps: '', // the resolved tdProps from `getTdProps` for this cell - columnProps: '', // the resolved column props from 'getProps' for this cell's column - classes: '', // the resolved array of classes for this cell - styles: '' // the resolved styles for this cell -} -``` - -## Accessors -Accessors are functions that return the value to populate the row's value for the column. -This lets the render function not have to worry about accessing the correct data, the value is automatically populated in it's props. - -If a `string` or `array` is passed the default accessor is used. -The default accessor will parse the input into an array and recursively flatten it. -Any values that contain a dot (`.`) will be split. -Any values that contain bracket (`[]`) will be split. -This array is then used as the path to the value to return. - -("$" is the placeholder value that would be returned by the default accessor) - -| value | path | data | -|--------------|-----------------|------------------------| -| "a" | ["a"] | {"a": $} | -| "a.b" | ["a", "b"] | {"a": {"b": $}} | -| "a[0]" | ["a", "0"] | {"a": [$]} | -| ["a.b", "c"] | ["a", "b", "c"] | {"a": {"b": {"c": $}}} | - -*NOTE* -If your data has a field/key with a dot (`.`) you will need to supply a custom accessor. - - -## Column Header Groups -To group columns with another header column, just nest your columns in a header column. Header columns utilize the same header properties as regular columns. -```javascript -const columns = [{ - Header: 'Favorites', - headerClassName: 'my-favorites-column-header-group' - columns: [{ - Header: 'Color', - accessor: 'favorites.color' - }, { - Header: 'Food', - accessor: 'favorites.food' - }, { - Header: 'Actor', - accessor: 'favorites.actor' - }] -}] -``` - -## Custom Cell, Header and Footer Rendering -You can use any react component or JSX to display content in column headers, cells and footers. Any component you use will be passed the following props (if available): -- `row` - Original row from your data -- `row` - The post-accessed values from the original row -- `index` - The index of the row -- `viewIndex` - the index of the row relative to the current page -- `level` - The nesting depth (zero-indexed) -- `nestingPath` - The nesting path of the row -- `aggregated` - A boolean stating if the row is an aggregation row -- `subRows` - An array of any expandable sub-rows contained in this row - -```javascript -// This column uses a stateless component to produce a different colored bar depending on the value -// You can also use stateful components or any other function that returns JSX -const columns = [{ - Header: () => Progress, - accessor: 'progress', - Cell: row => ( -
-
66 ? '#85cc00' - : row.value > 33 ? '#ffbf00' - : '#ff2e00', - borderRadius: '2px', - transition: 'all .2s ease-out' - }} - /> -
- ) -}] -``` - -## Styles -- React-table ships with a minimal and clean stylesheet to get you on your feet quickly. -- The stylesheet is located at `react-table/react-table.css`. -- There are countless ways to import a stylesheet. If you have questions on how to do so, consult the documentation of your build system. - -#### Classes -- Adding a `-striped` className to ReactTable will slightly color odd numbered rows for legibility -- Adding a `-highlight` className to ReactTable will highlight any row as you hover over it - -#### CSS -We think the default styles looks great! But, if you prefer a more custom look, all of the included styles are easily overridable. Every single component contains a unique class that makes it super easy to customize. Just go for it! - -#### JS Styles -Every single react-table element and `get[ComponentName]Props` callback supports `classname` and `style` props. - -## Custom Props - -#### Built-in Components -Every single built-in component's props can be dynamically extended using any one of these prop-callbacks: -```javascript - -``` - -If used, **a callback prop must return an valid object**, even if it's an empty one. - -These callbacks are executed with each render of the element with four parameters: - 1. Table State - 2. RowInfo (undefined if not applicable) - 3. Column (undefined if not applicable) - 4. React Table Instance - -This makes it extremely easy to add, say... a row click callback! -```javascript -// When any Td element is clicked, we'll log out some information - { - return { - onClick: (e, handleOriginal) => { - console.log('A Td Element was clicked!') - console.log('it produced this event:', e) - console.log('It was in this column:', column) - console.log('It was in this row:', rowInfo) - console.log('It was in this table instance:', instance) - - // IMPORTANT! React-Table uses onClick internally to trigger - // events like expanding SubComponents and pivots. - // By default a custom 'onClick' handler will override this functionality. - // If you want to fire the original onClick handler, call the - // 'handleOriginal' function. - if (handleOriginal) { - handleOriginal() - } - } - } - }} -/> -``` - -You can use these callbacks for dynamic styling as well! -```javascript -// Any Tr element will be green if its (row.age > 20) - { - return { - style: { - background: rowInfo.row.age > 20 ? 'green' : 'red' - } - } - }} -/> -``` - -#### Column Components -Just as core components can have dynamic props, columns and column headers can too! - -You can utilize either of these prop callbacks on columns: -```javascript -const columns = [{ - getHeaderProps: () => (...), - getProps: () => (...) -}] -``` - -In a similar fashion these can be used to dynamically style just about anything! -```javascript -// This columns cells will be red if (row.name === Santa Clause) -const columns = [{ - getProps: (state, rowInfo, column) => { - return { - style: { - background: rowInfo.row.name === 'Santa Clause' ? 'red' : null - } - } - } -}] -``` - -## Pivoting and Aggregation -Pivoting the table will group records together based on their accessed values and allow the rows in that group to be expanded underneath it. -To pivot, pass an array of `columnID`'s to `pivotBy`. Remember, a column's `id` is either the one that you assign it (when using a custom accessors) or its `accessor` string. -```javascript - -``` - -Naturally when grouping rows together, you may want to aggregate the rows inside it into the grouped column. No aggregation is done by default, however, it is very simple to aggregate any pivoted columns: -```javascript -// In this example, we use lodash to sum and average the values, but you can use whatever you want to aggregate. -const columns = [{ - Header: 'Age', - accessor: 'age', - aggregate: (values, rows) => _.round(_.mean(values)), - Aggregated: row => { - // You can even render the cell differently if it's an aggregated cell - return row.value (avg) - } -}, { - Header: 'Visits', - accessor: 'visits', - aggregate: (values, rows) => _.sum(values) -}] -``` - -Pivoted columns can be sorted just like regular columns including holding down the `` button to multi-sort. - -## Sub Tables and Sub Components -By adding a `SubComponent` props, you can easily add an expansion level to all root-level rows: -```javascript - { - return ( -
- You can put any component you want here, even another React Table! You even have access to the row-level data if you need! Spark-charts, drill-throughs, infographics... the possibilities are endless! -
- ) - }} -/> -``` - - -## Server-side Data -If you want to handle pagination, sorting, and filtering on the server, `react-table` makes it easy on you. - -1. Feed React Table `data` from somewhere dynamic. eg. `state`, a redux store, etc... -1. Add `manual` as a prop. This informs React Table that you'll be handling sorting and pagination server-side -1. Subscribe to the `onFetchData` prop. This function is called at `compomentDidMount` and any time sorting, pagination or filterting is changed in the table -1. In the `onFetchData` callback, request your data using the provided information in the params of the function (current state and instance) -1. Update your data with the rows to be displayed -1. Optionally set how many pages there are total - -```javascript - { - // show the loading overlay - this.setState({loading: true}) - // fetch your data - Axios.post('mysite.com/data', { - page: state.page, - pageSize: state.pageSize, - sorted: state.sorted, - filtered: state.filtered - }) - .then((res) => { - // Update react-table - this.setState({ - data: res.data.rows, - pages: res.data.pages, - loading: false - }) - }) - }} -/> -``` - -For a detailed example, take a peek at our async table mockup - -## Fully Controlled Component -React Table by default works fantastically out of the box, but you can achieve even more control and customization if you choose to maintain the state yourself. It is very easy to do, even if you only want to manage *parts* of the state. - -Here are the props and their corresponding callbacks that control the state of the a table: -```javascript - {...}} // Called when the page index is changed by the user - onPageSizeChange={(pageSize, pageIndex) => {...}} // Called when the pageSize is changed by the user. The resolve page is also sent to maintain approximate position in the data - onSortedChange={(newSorted, column, shiftKey) => {...}} // Called when a sortable column header is clicked with the column itself and if the shiftkey was held. If the column is a pivoted column, `column` will be an array of columns - onExpandedChange={(newExpanded, index, event) => {...}} // Called when an expander is clicked. Use this to manage `expanded` - onFilteredChange={(column, value) => {...}} // Called when a user enters a value into a filter input field or the value passed to the onFiltersChange handler by the Filter option. - onResizedChange={(newResized, event) => {...}} // Called when a user clicks on a resizing component (the right edge of a column header) -/> -``` +
+ + semantic-release + +Best of JS + Follow @TanStack +
-## Functional Rendering -Possibly one of the coolest features of React-Table is its ability to expose internal components and state for custom render logic. The easiest way to do this is to pass a function as the child of ``. +### [Become a Sponsor!](https://github.com/sponsors/tannerlinsley/) -The function you pass will be called with the following items: -- Fully-resolved state of the table -- A function that returns the standard table component -- The instance of the component +
-You can then return any JSX or react you want! This turns out to be perfect for: -- Accessing the internal state of the table without a `ref` -- Decorating the table or extending it with your own UI -- Building your own custom display logic +# TanStack Table -Accessing internal state and wrapping with more UI: -```javascript - [!NOTE] +> You may know TanStack Table by the adapter names: > - {(state, makeTable, instance) => { - return ( -
-
state.allVisibleColumns === {JSON.stringify(state.allVisibleColumns, null, 4)}
- {makeTable()} -
- ) - }} -
-``` - -The possibilities are endless! - -## Sorting -Sorting comes built in with React-Table. -- Click a column header to sort by its accessor. -- Click it again to reverse the sort. -- Set `defaultSortDesc` property to `true` to make the first sort direction default to descending. -- Override a specific column's default sort direction by using the same `defaultSortDesc` property on a column, set to `true` - -## Multi-Sort -When clicking on a column header, hold shift to multi-sort! You can toggle `ascending` `descending` and `none` for multi-sort columns. Clicking on a header without holding shift will clear the multi-sort and replace it with the single sort of that column. It's quite handy! - -You can set the `multiSort` prop to `false` to disable this feature (which may be useful for server-side sorting when you are not -going to sort multiple columns). - -## Custom Sorting Algorithm -To override the default sorting algorithm for the whole table use the `defaultSortMethod` prop. - -To override the sorting algorithm for a single column, use the `sortMethod` column property. - -Supply a function that implements the native javascript [`Array.sort`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort) interface. This is React Table's default sorting algorithm: -- `a` the first value to compare -- `b` the second value to compare -- `desc` true if sort is descending, false if ascending -```javascript -defaultSortMethod = (a, b, desc) => { - // force null and undefined to the bottom - a = (a === null || a === undefined) ? -Infinity : a - b = (b === null || b === undefined) ? -Infinity : b - // force any string values to lowercase - a = typeof a === 'string' ? a.toLowerCase() : a - b = typeof b === 'string' ? b.toLowerCase() : b - // Return either 1 or -1 to indicate a sort priority - if (a > b) { - return 1 - } - if (a < b) { - return -1 - } - // returning 0 or undefined will use any subsequent column sorting methods or the row index as a tiebreaker - return 0 -} -``` - -## Filtering -Filtering can be enabled by setting the `filterable` option on the table. - -If you don't want particular column to be filtered you can set the `filterable={false}` option on the column. - -By default the table tries to filter by checking if the row's value starts with the filter text. The default method for filtering the table can be set with the table's `defaultFilterMethod` option. - -If you want to override a particular column's filtering method, you can set the `filterMethod` option on a column. - -By default, `filterMethod` is passed a single row of data at a time, and you are responsible for returning `true` or `false`, indicating whether it should be shown. - -Alternatively, you can set `filterAll` to `true`, and `filterMethod` will be passed the entire array of rows to be filtered, and you will then be responsible for returning the new filtered array. This is extremely handy when you need to utilize a utility like fuzzy matching that requires the entire array of items. - -To completely override the filter that is shown, you can set the `Filter` column option. Using this option you can specify the JSX that is shown. The option is passed an `onChange` method which must be called with the the value that you want to pass to the `filterMethod` option whenever the filter has changed. - -See Custom Filtering demo for examples. - -## Component Overrides -Though we confidently stand by the markup and architecture behind it, `react-table` does offer the ability to change the core componentry it uses to render everything. You can extend or override these internal components by passing a react component to it's corresponding prop on either the global props or on a one-off basis like so: -```javascript -// Change the global default -import { ReactTableDefaults } from 'react-table' -Object.assign(ReactTableDefaults, { - TableComponent: component, - TheadComponent: component, - TbodyComponent: component, - TrGroupComponent: component, - TrComponent: component, - ThComponent: component, - TdComponent: component, - TfootComponent: component, - ExpanderComponent: component, - AggregatedComponent: component, - PivotValueComponent: component, - PivotComponent: component, - FilterComponent: component, - PaginationComponent: component, - PreviousComponent: undefined, - NextComponent: undefined, - LoadingComponent: component, - NoDataComponent: component, - ResizerComponent: component -}) - -// Or change per instance - -``` - -If you choose to change the core components React-Table uses to render, you must make sure your replacement components consume and utilize all of the supplied and inherited props that are needed for that component to function properly. We would suggest investigating the source for the component you wish to replace. - - -## Contributing -To suggest a feature, create an issue if it does not already exist. -If you would like to help develop a suggested feature follow these steps: - -- Fork this repo -- Install dependencies with `$ yarn` -- Auto-build files as you edit with `$ yarn run watch` -- Implement your changes to files in the `src/` directory -- Run the React Story locally with `$ yarn run docs` -- View changes as you edit `docs/src` -- Submit PR for review +> - [Angular Table](https://tanstack.com/table/alpha/docs/framework/angular/angular-table) +> - [Lit Table](https://tanstack.com/table/alpha/docs/framework/lit/lit-table) +> - [React Table](https://tanstack.com/table/alpha/docs/framework/react/react-table) +> - [Solid Table](https://tanstack.com/table/alpha/docs/framework/solid/solid-table) +> - [Svelte Table](https://tanstack.com/table/alpha/docs/framework/svelte/svelte-table) +> - [Vue Table](https://tanstack.com/table/alpha/docs/framework/vue/vue-table) + +A headless table library for building powerful datagrids with full control over markup, styles, and behavior. + +- Framework‑agnostic core with bindings for React, Vue & Solid +- 100% customizable — bring your own UI, components, and styles +- Sorting, filtering, grouping, aggregation & row selection +- Lightweight, virtualizable & server‑side friendly + +### Read the Docs → + +## Get Involved + +- We welcome issues and pull requests! +- Participate in [GitHub discussions](https://github.com/TanStack/table/discussions) +- Chat with the community on [Discord](https://discord.com/invite/WrRKjPJ) +- See [CONTRIBUTING.md](./CONTRIBUTING.md) for setup instructions + +## Partners + + + + + + + +
+ + + + + CodeRabbit + + + + + + + + Cloudflare + + + + + + + + AG Grid + + +
+ +
+Table & you? +

+We're looking for TanStack Table Partners to join our mission! Partner with us to push the boundaries of TanStack Table and build amazing things together. +

+LET'S CHAT +
-#### Scripts +## Explore the TanStack Ecosystem -- `$ yarn run watch` Watches files and builds via babel -- `$ yarn run docs` Runs the storybook server -- `$ yarn run test` Runs the test suite +- TanStack Config – Tooling for JS/TS packages +- TanStack DB – Reactive sync client store +- TanStack DevTools – Unified devtools panel +- TanStack Form – Type‑safe form state +- TanStack Pacer – Debouncing, throttling, batching
+- TanStack Query – Async state & caching +- TanStack Ranger – Range & slider primitives +- TanStack Router – Type‑safe routing, caching & URL state +- TanStack Start – Full‑stack SSR & streaming +- TanStack Store – Reactive data store +- TanStack Virtual – Virtualized rendering -## Used By +… and more at TanStack.com » - - Nozzle Logo - + diff --git a/docs/.eslintrc.js b/docs/.eslintrc.js deleted file mode 100644 index 9e5806e444..0000000000 --- a/docs/.eslintrc.js +++ /dev/null @@ -1,77 +0,0 @@ -module.exports = { - parserOptions: { - ecmaVersion: 8, - ecmaFeatures: { - experimentalObjectRestSpread: true, - jsx: true, - node: false, - classes: true - }, - sourceType: 'module' - }, - - parser: 'babel-eslint', - - extends: ['standard'], - - plugins: ['react'], - - rules: { - // Nozzle - 'jsx-quotes': [2, 'prefer-single'], - 'comma-dangle': [2, 'always-multiline'], - - // // React - 'react/jsx-boolean-value': 2, - 'react/jsx-curly-spacing': [2, 'never'], - 'react/jsx-equals-spacing': [2, 'never'], - // 'react/jsx-indent': 2, - 'react/jsx-indent-props': [2, 2], - 'react/jsx-no-duplicate-props': 2, - 'react/jsx-no-undef': 2, - 'react/jsx-tag-spacing': [ - 2, - { - closingSlash: 'never', - beforeSelfClosing: 'always', - afterOpening: 'never' - } - ], - 'react/jsx-uses-react': 2, - 'react/jsx-uses-vars': 2, - 'react/self-closing-comp': 2, - 'react/jsx-no-bind': [ - 2, - { - allowArrowFunctions: true, - allowBind: false, - ignoreRefs: true - } - ], - 'react/no-did-update-set-state': 2, - 'react/no-unknown-property': 2, - 'react/react-in-jsx-scope': 2, - 'react/jsx-closing-bracket-location': [0, 'tag-aligned'], - 'react/jsx-tag-spacing': [2, { beforeSelfClosing: 'always' }], - 'react/jsx-wrap-multilines': 2, - 'react/self-closing-comp': 2, - 'react/jsx-key': 2, - 'react/jsx-no-comment-textnodes': 2, - 'react/jsx-no-duplicate-props': 2, - 'react/jsx-no-target-blank': 2, - 'react/jsx-no-undef': 2, - 'react/jsx-uses-react': 2, - 'react/jsx-uses-vars': 2, - 'react/no-danger-with-children': 2, - 'react/no-deprecated': 2, - 'react/no-direct-mutation-state': 2, - 'react/no-find-dom-node': 2, - 'react/no-is-mounted': 2, - 'react/no-render-return-value': 2, - 'react/no-string-refs': 2, - 'react/no-unknown-property': 2, - 'react/react-in-jsx-scope': 2, - 'react/require-render-return': 2 - // 'react/jsx-max-props-per-line': [2, { maximum: 1 }] - } -} diff --git a/docs/CNAME b/docs/CNAME deleted file mode 100644 index b05ccdf5fd..0000000000 --- a/docs/CNAME +++ /dev/null @@ -1 +0,0 @@ -react-table.js.org \ No newline at end of file diff --git a/docs/README.md b/docs/README.md deleted file mode 100644 index a5203365f5..0000000000 --- a/docs/README.md +++ /dev/null @@ -1,1623 +0,0 @@ -This project was bootstrapped with [Create React App](https://github.com/facebookincubator/create-react-app). - -Below you will find some information on how to perform common tasks.
-You can find the most recent version of this guide [here](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md). - -## Table of Contents - -- [Updating to New Releases](#updating-to-new-releases) -- [Sending Feedback](#sending-feedback) -- [Folder Structure](#folder-structure) -- [Available Scripts](#available-scripts) - - [npm start](#npm-start) - - [npm test](#npm-test) - - [npm run build](#npm-run-build) - - [npm run eject](#npm-run-eject) -- [Supported Language Features and Polyfills](#supported-language-features-and-polyfills) -- [Syntax Highlighting in the Editor](#syntax-highlighting-in-the-editor) -- [Displaying Lint Output in the Editor](#displaying-lint-output-in-the-editor) -- [Debugging in the Editor](#debugging-in-the-editor) -- [Changing the Page ``](#changing-the-page-title) -- [Installing a Dependency](#installing-a-dependency) -- [Importing a Component](#importing-a-component) -- [Adding a Stylesheet](#adding-a-stylesheet) -- [Post-Processing CSS](#post-processing-css) -- [Adding a CSS Preprocessor (Sass, Less etc.)](#adding-a-css-preprocessor-sass-less-etc) -- [Adding Images and Fonts](#adding-images-and-fonts) -- [Using the `public` Folder](#using-the-public-folder) - - [Changing the HTML](#changing-the-html) - - [Adding Assets Outside of the Module System](#adding-assets-outside-of-the-module-system) - - [When to Use the `public` Folder](#when-to-use-the-public-folder) -- [Using Global Variables](#using-global-variables) -- [Adding Bootstrap](#adding-bootstrap) - - [Using a Custom Theme](#using-a-custom-theme) -- [Adding Flow](#adding-flow) -- [Adding Custom Environment Variables](#adding-custom-environment-variables) - - [Referencing Environment Variables in the HTML](#referencing-environment-variables-in-the-html) - - [Adding Temporary Environment Variables In Your Shell](#adding-temporary-environment-variables-in-your-shell) - - [Adding Development Environment Variables In `.env`](#adding-development-environment-variables-in-env) -- [Can I Use Decorators?](#can-i-use-decorators) -- [Integrating with an API Backend](#integrating-with-an-api-backend) - - [Node](#node) - - [Ruby on Rails](#ruby-on-rails) -- [Proxying API Requests in Development](#proxying-api-requests-in-development) -- [Using HTTPS in Development](#using-https-in-development) -- [Generating Dynamic `<meta>` Tags on the Server](#generating-dynamic-meta-tags-on-the-server) -- [Pre-Rendering into Static HTML Files](#pre-rendering-into-static-html-files) -- [Injecting Data from the Server into the Page](#injecting-data-from-the-server-into-the-page) -- [Running Tests](#running-tests) - - [Filename Conventions](#filename-conventions) - - [Command Line Interface](#command-line-interface) - - [Version Control Integration](#version-control-integration) - - [Writing Tests](#writing-tests) - - [Testing Components](#testing-components) - - [Using Third Party Assertion Libraries](#using-third-party-assertion-libraries) - - [Initializing Test Environment](#initializing-test-environment) - - [Focusing and Excluding Tests](#focusing-and-excluding-tests) - - [Coverage Reporting](#coverage-reporting) - - [Continuous Integration](#continuous-integration) - - [Disabling jsdom](#disabling-jsdom) - - [Snapshot Testing](#snapshot-testing) - - [Editor Integration](#editor-integration) -- [Developing Components in Isolation](#developing-components-in-isolation) -- [Making a Progressive Web App](#making-a-progressive-web-app) -- [Deployment](#deployment) - - [Static Server](#static-server) - - [Other Solutions](#other-solutions) - - [Serving Apps with Client-Side Routing](#serving-apps-with-client-side-routing) - - [Building for Relative Paths](#building-for-relative-paths) - - [Azure](#azure) - - [Firebase](#firebase) - - [GitHub Pages](#github-pages) - - [Heroku](#heroku) - - [Modulus](#modulus) - - [Netlify](#netlify) - - [Now](#now) - - [S3 and CloudFront](#s3-and-cloudfront) - - [Surge](#surge) -- [Advanced Configuration](#advanced-configuration) -- [Troubleshooting](#troubleshooting) - - [`npm start` doesn’t detect changes](#npm-start-doesnt-detect-changes) - - [`npm test` hangs on macOS Sierra](#npm-test-hangs-on-macos-sierra) - - [`npm run build` silently fails](#npm-run-build-silently-fails) - - [`npm run build` fails on Heroku](#npm-run-build-fails-on-heroku) -- [Something Missing?](#something-missing) - -## Updating to New Releases - -Create React App is divided into two packages: - -* `create-react-app` is a global command-line utility that you use to create new projects. -* `react-scripts` is a development dependency in the generated projects (including this one). - -You almost never need to update `create-react-app` itself: it delegates all the setup to `react-scripts`. - -When you run `create-react-app`, it always creates the project with the latest version of `react-scripts` so you’ll get all the new features and improvements in newly created apps automatically. - -To update an existing project to a new version of `react-scripts`, [open the changelog](https://github.com/facebookincubator/create-react-app/blob/master/CHANGELOG.md), find the version you’re currently on (check `package.json` in this folder if you’re not sure), and apply the migration instructions for the newer versions. - -In most cases bumping the `react-scripts` version in `package.json` and running `npm install` in this folder should be enough, but it’s good to consult the [changelog](https://github.com/facebookincubator/create-react-app/blob/master/CHANGELOG.md) for potential breaking changes. - -We commit to keeping the breaking changes minimal so you can upgrade `react-scripts` painlessly. - -## Sending Feedback - -We are always open to [your feedback](https://github.com/facebookincubator/create-react-app/issues). - -## Folder Structure - -After creation, your project should look like this: - -``` -my-app/ - README.md - node_modules/ - package.json - public/ - index.html - favicon.ico - src/ - App.css - App.js - App.test.js - index.css - index.js - logo.svg -``` - -For the project to build, **these files must exist with exact filenames**: - -* `public/index.html` is the page template; -* `src/index.js` is the JavaScript entry point. - -You can delete or rename the other files. - -You may create subdirectories inside `src`. For faster rebuilds, only files inside `src` are processed by Webpack.<br> -You need to **put any JS and CSS files inside `src`**, or Webpack won’t see them. - -Only files inside `public` can be used from `public/index.html`.<br> -Read instructions below for using assets from JavaScript and HTML. - -You can, however, create more top-level directories.<br> -They will not be included in the production build so you can use them for things like documentation. - -## Available Scripts - -In the project directory, you can run: - -### `npm start` - -Runs the app in the development mode.<br> -Open [http://localhost:3000](http://localhost:3000) to view it in the browser. - -The page will reload if you make edits.<br> -You will also see any lint errors in the console. - -### `npm test` - -Launches the test runner in the interactive watch mode.<br> -See the section about [running tests](#running-tests) for more information. - -### `npm run build` - -Builds the app for production to the `build` folder.<br> -It correctly bundles React in production mode and optimizes the build for the best performance. - -The build is minified and the filenames include the hashes.<br> -Your app is ready to be deployed! - -See the section about [deployment](#deployment) for more information. - -### `npm run eject` - -**Note: this is a one-way operation. Once you `eject`, you can’t go back!** - -If you aren’t satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project. - -Instead, it will copy all the configuration files and the transitive dependencies (Webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you’re on your own. - -You don’t have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn’t feel obligated to use this feature. However we understand that this tool wouldn’t be useful if you couldn’t customize it when you are ready for it. - -## Supported Language Features and Polyfills - -This project supports a superset of the latest JavaScript standard.<br> -In addition to [ES6](https://github.com/lukehoban/es6features) syntax features, it also supports: - -* [Exponentiation Operator](https://github.com/rwaldron/exponentiation-operator) (ES2016). -* [Async/await](https://github.com/tc39/ecmascript-asyncawait) (ES2017). -* [Object Rest/Spread Properties](https://github.com/sebmarkbage/ecmascript-rest-spread) (stage 3 proposal). -* [Class Fields and Static Properties](https://github.com/tc39/proposal-class-public-fields) (stage 2 proposal). -* [JSX](https://facebook.github.io/react/docs/introducing-jsx.html) and [Flow](https://flowtype.org/) syntax. - -Learn more about [different proposal stages](https://babeljs.io/docs/plugins/#presets-stage-x-experimental-presets-). - -While we recommend to use experimental proposals with some caution, Facebook heavily uses these features in the product code, so we intend to provide [codemods](https://medium.com/@cpojer/effective-javascript-codemods-5a6686bb46fb) if any of these proposals change in the future. - -Note that **the project only includes a few ES6 [polyfills](https://en.wikipedia.org/wiki/Polyfill)**: - -* [`Object.assign()`](https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Object/assign) via [`object-assign`](https://github.com/sindresorhus/object-assign). -* [`Promise`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise) via [`promise`](https://github.com/then/promise). -* [`fetch()`](https://developer.mozilla.org/en/docs/Web/API/Fetch_API) via [`whatwg-fetch`](https://github.com/github/fetch). - -If you use any other ES6+ features that need **runtime support** (such as `Array.from()` or `Symbol`), make sure you are including the appropriate polyfills manually, or that the browsers you are targeting already support them. - -## Syntax Highlighting in the Editor - -To configure the syntax highlighting in your favorite text editor, head to the [relevant Babel documentation page](https://babeljs.io/docs/editors) and follow the instructions. Some of the most popular editors are covered. - -## Displaying Lint Output in the Editor - ->Note: this feature is available with `react-scripts@0.2.0` and higher. - -Some editors, including Sublime Text, Atom, and Visual Studio Code, provide plugins for ESLint. - -They are not required for linting. You should see the linter output right in your terminal as well as the browser console. However, if you prefer the lint results to appear right in your editor, there are some extra steps you can do. - -You would need to install an ESLint plugin for your editor first. - ->**A note for Atom `linter-eslint` users** - ->If you are using the Atom `linter-eslint` plugin, make sure that **Use global ESLint installation** option is checked: - -><img src="http://i.imgur.com/yVNNHJM.png" width="300"> - - ->**For Visual Studio Code users** - ->VS Code ESLint plugin automatically detects Create React App's configuration file. So you do not need to create `eslintrc.json` at the root directory, except when you want to add your own rules. In that case, you should include CRA's config by adding this line: - ->```js -{ - // ... - "extends": "react-app" -} -``` - -Then add this block to the `package.json` file of your project: - -```js -{ - // ... - "eslintConfig": { - "extends": "react-app" - } -} -``` - -Finally, you will need to install some packages *globally*: - -```sh -npm install -g eslint-config-react-app@0.3.0 eslint@3.8.1 babel-eslint@7.0.0 eslint-plugin-react@6.4.1 eslint-plugin-import@2.0.1 eslint-plugin-jsx-a11y@4.0.0 eslint-plugin-flowtype@2.21.0 -``` - -We recognize that this is suboptimal, but it is currently required due to the way we hide the ESLint dependency. The ESLint team is already [working on a solution to this](https://github.com/eslint/eslint/issues/3458) so this may become unnecessary in a couple of months. - -## Debugging in the Editor - -**This feature is currently only supported by [Visual Studio Code](https://code.visualstudio.com) editor.** - -Visual Studio Code supports live-editing and debugging out of the box with Create React App. This enables you as a developer to write and debug your React code without leaving the editor, and most importantly it enables you to have a continuous development workflow, where context switching is minimal, as you don’t have to switch between tools. - -You would need to have the latest version of [VS Code](https://code.visualstudio.com) and VS Code [Chrome Debugger Extension](https://marketplace.visualstudio.com/items?itemName=msjsdiag.debugger-for-chrome) installed. - -Then add the block below to your `launch.json` file and put it inside the `.vscode` folder in your app’s root directory. - -```json -{ - "version": "0.2.0", - "configurations": [{ - "name": "Chrome", - "type": "chrome", - "request": "launch", - "url": "http://localhost:3000", - "webRoot": "${workspaceRoot}/src", - "userDataDir": "${workspaceRoot}/.vscode/chrome", - "sourceMapPathOverrides": { - "webpack:///src/*": "${webRoot}/*" - } - }] -} -``` - -Start your app by running `npm start`, and start debugging in VS Code by pressing `F5` or by clicking the green debug icon. You can now write code, set breakpoints, make changes to the code, and debug your newly modified code—all from your editor. - -## Changing the Page `<title>` - -You can find the source HTML file in the `public` folder of the generated project. You may edit the `<title>` tag in it to change the title from “React App” to anything else. - -Note that normally you wouldn’t edit files in the `public` folder very often. For example, [adding a stylesheet](#adding-a-stylesheet) is done without touching the HTML. - -If you need to dynamically update the page title based on the content, you can use the browser [`document.title`](https://developer.mozilla.org/en-US/docs/Web/API/Document/title) API. For more complex scenarios when you want to change the title from React components, you can use [React Helmet](https://github.com/nfl/react-helmet), a third party library. - -If you use a custom server for your app in production and want to modify the title before it gets sent to the browser, you can follow advice in [this section](#generating-dynamic-meta-tags-on-the-server). Alternatively, you can pre-build each page as a static HTML file which then loads the JavaScript bundle, which is covered [here](#pre-rendering-into-static-html-files). - -## Installing a Dependency - -The generated project includes React and ReactDOM as dependencies. It also includes a set of scripts used by Create React App as a development dependency. You may install other dependencies (for example, React Router) with `npm`: - -``` -npm install --save <library-name> -``` - -## Importing a Component - -This project setup supports ES6 modules thanks to Babel.<br> -While you can still use `require()` and `module.exports`, we encourage you to use [`import` and `export`](http://exploringjs.com/es6/ch_modules.html) instead. - -For example: - -### `Button.js` - -```js -import React, { Component } from 'react'; - -class Button extends Component { - render() { - // ... - } -} - -export default Button; // Don’t forget to use export default! -``` - -### `DangerButton.js` - - -```js -import React, { Component } from 'react'; -import Button from './Button'; // Import a component from another file - -class DangerButton extends Component { - render() { - return <Button color="red" />; - } -} - -export default DangerButton; -``` - -Be aware of the [difference between default and named exports](http://stackoverflow.com/questions/36795819/react-native-es-6-when-should-i-use-curly-braces-for-import/36796281#36796281). It is a common source of mistakes. - -We suggest that you stick to using default imports and exports when a module only exports a single thing (for example, a component). That’s what you get when you use `export default Button` and `import Button from './Button'`. - -Named exports are useful for utility modules that export several functions. A module may have at most one default export and as many named exports as you like. - -Learn more about ES6 modules: - -* [When to use the curly braces?](http://stackoverflow.com/questions/36795819/react-native-es-6-when-should-i-use-curly-braces-for-import/36796281#36796281) -* [Exploring ES6: Modules](http://exploringjs.com/es6/ch_modules.html) -* [Understanding ES6: Modules](https://leanpub.com/understandinges6/read#leanpub-auto-encapsulating-code-with-modules) - -## Adding a Stylesheet - -This project setup uses [Webpack](https://webpack.github.io/) for handling all assets. Webpack offers a custom way of “extending” the concept of `import` beyond JavaScript. To express that a JavaScript file depends on a CSS file, you need to **import the CSS from the JavaScript file**: - -### `Button.css` - -```css -.Button { - padding: 20px; -} -``` - -### `Button.js` - -```js -import React, { Component } from 'react'; -import './Button.css'; // Tell Webpack that Button.js uses these styles - -class Button extends Component { - render() { - // You can use them as regular CSS styles - return <div className="Button" />; - } -} -``` - -**This is not required for React** but many people find this feature convenient. You can read about the benefits of this approach [here](https://medium.com/seek-ui-engineering/block-element-modifying-your-javascript-components-d7f99fcab52b). However you should be aware that this makes your code less portable to other build tools and environments than Webpack. - -In development, expressing dependencies this way allows your styles to be reloaded on the fly as you edit them. In production, all CSS files will be concatenated into a single minified `.css` file in the build output. - -If you are concerned about using Webpack-specific semantics, you can put all your CSS right into `src/index.css`. It would still be imported from `src/index.js`, but you could always remove that import if you later migrate to a different build tool. - -## Post-Processing CSS - -This project setup minifies your CSS and adds vendor prefixes to it automatically through [Autoprefixer](https://github.com/postcss/autoprefixer) so you don’t need to worry about it. - -For example, this: - -```css -.App { - display: flex; - flex-direction: row; - align-items: center; -} -``` - -becomes this: - -```css -.App { - display: -webkit-box; - display: -ms-flexbox; - display: flex; - -webkit-box-orient: horizontal; - -webkit-box-direction: normal; - -ms-flex-direction: row; - flex-direction: row; - -webkit-box-align: center; - -ms-flex-align: center; - align-items: center; -} -``` - -If you need to disable autoprefixing for some reason, [follow this section](https://github.com/postcss/autoprefixer#disabling). - -## Adding a CSS Preprocessor (Sass, Less etc.) - -Generally, we recommend that you don’t reuse the same CSS classes across different components. For example, instead of using a `.Button` CSS class in `<AcceptButton>` and `<RejectButton>` components, we recommend creating a `<Button>` component with its own `.Button` styles, that both `<AcceptButton>` and `<RejectButton>` can render (but [not inherit](https://facebook.github.io/react/docs/composition-vs-inheritance.html)). - -Following this rule often makes CSS preprocessors less useful, as features like mixins and nesting are replaced by component composition. You can, however, integrate a CSS preprocessor if you find it valuable. In this walkthrough, we will be using Sass, but you can also use Less, or another alternative. - -First, let’s install the command-line interface for Sass: - -``` -npm install node-sass --save-dev -``` - -Then in `package.json`, add the following lines to `scripts`: - -```diff - "scripts": { -+ "build-css": "node-sass src/ -o src/", -+ "watch-css": "npm run build-css && node-sass src/ -o src/ --watch --recursive", - "start": "react-scripts start", - "build": "react-scripts build", - "test": "react-scripts test --env=jsdom", -``` - ->Note: To use a different preprocessor, replace `build-css` and `watch-css` commands according to your preprocessor’s documentation. - -Now you can rename `src/App.css` to `src/App.scss` and run `npm run watch-css`. The watcher will find every Sass file in `src` subdirectories, and create a corresponding CSS file next to it, in our case overwriting `src/App.css`. Since `src/App.js` still imports `src/App.css`, the styles become a part of your application. You can now edit `src/App.scss`, and `src/App.css` will be regenerated. - -To share variables between Sass files, you can use Sass imports. For example, `src/App.scss` and other component style files could include `@import "./shared.scss";` with variable definitions. - -At this point you might want to remove all CSS files from the source control, and add `src/**/*.css` to your `.gitignore` file. It is generally a good practice to keep the build products outside of the source control. - -As a final step, you may find it convenient to run `watch-css` automatically with `npm start`, and run `build-css` as a part of `npm run build`. You can use the `&&` operator to execute two scripts sequentially. However, there is no cross-platform way to run two scripts in parallel, so we will install a package for this: - -``` -npm install --save-dev npm-run-all -``` - -Then we can change `start` and `build` scripts to include the CSS preprocessor commands: - -```diff - "scripts": { - "build-css": "node-sass src/ -o src/", - "watch-css": "npm run build-css && node-sass src/ -o src/ --watch --recursive", -- "start": "react-scripts start", -- "build": "react-scripts build", -+ "start-js": "react-scripts start", -+ "start": "npm-run-all -p watch-css start-js", -+ "build": "npm run build-css && react-scripts build", - "test": "react-scripts test --env=jsdom", - "eject": "react-scripts eject" - } -``` - -Now running `npm start` and `npm run build` also builds Sass files. Note that `node-sass` seems to have an [issue recognizing newly created files on some systems](https://github.com/sass/node-sass/issues/1891) so you might need to restart the watcher when you create a file until it’s resolved. - -## Adding Images and Fonts - -With Webpack, using static assets like images and fonts works similarly to CSS. - -You can **`import` an image right in a JavaScript module**. This tells Webpack to include that image in the bundle. Unlike CSS imports, importing an image or a font gives you a string value. This value is the final image path you can reference in your code. - -Here is an example: - -```js -import React from 'react'; -import logo from './logo.png'; // Tell Webpack this JS file uses this image - -console.log(logo); // /logo.84287d09.png - -function Header() { - // Import result is the URL of your image - return <img src={logo} alt="Logo" />; -} - -export default Header; -``` - -This ensures that when the project is built, Webpack will correctly move the images into the build folder, and provide us with correct paths. - -This works in CSS too: - -```css -.Logo { - background-image: url(./logo.png); -} -``` - -Webpack finds all relative module references in CSS (they start with `./`) and replaces them with the final paths from the compiled bundle. If you make a typo or accidentally delete an important file, you will see a compilation error, just like when you import a non-existent JavaScript module. The final filenames in the compiled bundle are generated by Webpack from content hashes. If the file content changes in the future, Webpack will give it a different name in production so you don’t need to worry about long-term caching of assets. - -Please be advised that this is also a custom feature of Webpack. - -**It is not required for React** but many people enjoy it (and React Native uses a similar mechanism for images).<br> -An alternative way of handling static assets is described in the next section. - -## Using the `public` Folder - ->Note: this feature is available with `react-scripts@0.5.0` and higher. - -### Changing the HTML - -The `public` folder contains the HTML file so you can tweak it, for example, to [set the page title](#changing-the-page-title). -The `<script>` tag with the compiled code will be added to it automatically during the build process. - -### Adding Assets Outside of the Module System - -You can also add other assets to the `public` folder. - -Note that we normally encourage you to `import` assets in JavaScript files instead. -For example, see the sections on [adding a stylesheet](#adding-a-stylesheet) and [adding images and fonts](#adding-images-and-fonts). -This mechanism provides a number of benefits: - -* Scripts and stylesheets get minified and bundled together to avoid extra network requests. -* Missing files cause compilation errors instead of 404 errors for your users. -* Result filenames include content hashes so you don’t need to worry about browsers caching their old versions. - -However there is an **escape hatch** that you can use to add an asset outside of the module system. - -If you put a file into the `public` folder, it will **not** be processed by Webpack. Instead it will be copied into the build folder untouched. To reference assets in the `public` folder, you need to use a special variable called `PUBLIC_URL`. - -Inside `index.html`, you can use it like this: - -```html -<link rel="shortcut icon" href="%PUBLIC_URL%/favicon.ico"> -``` - -Only files inside the `public` folder will be accessible by `%PUBLIC_URL%` prefix. If you need to use a file from `src` or `node_modules`, you’ll have to copy it there to explicitly specify your intention to make this file a part of the build. - -When you run `npm run build`, Create React App will substitute `%PUBLIC_URL%` with a correct absolute path so your project works even if you use client-side routing or host it at a non-root URL. - -In JavaScript code, you can use `process.env.PUBLIC_URL` for similar purposes: - -```js -render() { - // Note: this is an escape hatch and should be used sparingly! - // Normally we recommend using `import` for getting asset URLs - // as described in “Adding Images and Fonts” above this section. - return <img src={process.env.PUBLIC_URL + '/img/logo.png'} />; -} -``` - -Keep in mind the downsides of this approach: - -* None of the files in `public` folder get post-processed or minified. -* Missing files will not be called at compilation time, and will cause 404 errors for your users. -* Result filenames won’t include content hashes so you’ll need to add query arguments or rename them every time they change. - -### When to Use the `public` Folder - -Normally we recommend importing [stylesheets](#adding-a-stylesheet), [images, and fonts](#adding-images-and-fonts) from JavaScript. -The `public` folder is useful as a workaround for a number of less common cases: - -* You need a file with a specific name in the build output, such as [`manifest.webmanifest`](https://developer.mozilla.org/en-US/docs/Web/Manifest). -* You have thousands of images and need to dynamically reference their paths. -* You want to include a small script like [`pace.js`](http://github.hubspot.com/pace/docs/welcome/) outside of the bundled code. -* Some library may be incompatible with Webpack and you have no other option but to include it as a `<script>` tag. - -Note that if you add a `<script>` that declares global variables, you also need to read the next section on using them. - -## Using Global Variables - -When you include a script in the HTML file that defines global variables and try to use one of these variables in the code, the linter will complain because it cannot see the definition of the variable. - -You can avoid this by reading the global variable explicitly from the `window` object, for example: - -```js -const $ = window.$; -``` - -This makes it obvious you are using a global variable intentionally rather than because of a typo. - -Alternatively, you can force the linter to ignore any line by adding `// eslint-disable-line` after it. - -## Adding Bootstrap - -You don’t have to use [React Bootstrap](https://react-bootstrap.github.io) together with React but it is a popular library for integrating Bootstrap with React apps. If you need it, you can integrate it with Create React App by following these steps: - -Install React Bootstrap and Bootstrap from npm. React Bootstrap does not include Bootstrap CSS so this needs to be installed as well: - -``` -npm install react-bootstrap --save -npm install bootstrap@3 --save -``` - -Import Bootstrap CSS and optionally Bootstrap theme CSS in the beginning of your ```src/index.js``` file: - -```js -import 'bootstrap/dist/css/bootstrap.css'; -import 'bootstrap/dist/css/bootstrap-theme.css'; -// Put any other imports below so that CSS from your -// components takes precedence over default styles. -``` - -Import required React Bootstrap components within ```src/App.js``` file or your custom component files: - -```js -import { Navbar, Jumbotron, Button } from 'react-bootstrap'; -``` - -Now you are ready to use the imported React Bootstrap components within your component hierarchy defined in the render method. Here is an example [`App.js`](https://gist.githubusercontent.com/gaearon/85d8c067f6af1e56277c82d19fd4da7b/raw/6158dd991b67284e9fc8d70b9d973efe87659d72/App.js) redone using React Bootstrap. - -### Using a Custom Theme - -Sometimes you might need to tweak the visual styles of Bootstrap (or equivalent package).<br> -We suggest the following approach: - -* Create a new package that depends on the package you wish to customize, e.g. Bootstrap. -* Add the necessary build steps to tweak the theme, and publish your package on npm. -* Install your own theme npm package as a dependency of your app. - -Here is an example of adding a [customized Bootstrap](https://medium.com/@tacomanator/customizing-create-react-app-aa9ffb88165) that follows these steps. - -## Adding Flow - -Flow is a static type checker that helps you write code with fewer bugs. Check out this [introduction to using static types in JavaScript](https://medium.com/@preethikasireddy/why-use-static-types-in-javascript-part-1-8382da1e0adb) if you are new to this concept. - -Recent versions of [Flow](http://flowtype.org/) work with Create React App projects out of the box. - -To add Flow to a Create React App project, follow these steps: - -1. Run `npm install --save-dev flow-bin` (or `yarn add --dev flow-bin`). -2. Add `"flow": "flow"` to the `scripts` section of your `package.json`. -3. Run `npm run flow -- init` (or `yarn flow -- init`) to create a [`.flowconfig` file](https://flowtype.org/docs/advanced-configuration.html) in the root directory. -4. Add `// @flow` to any files you want to type check (for example, to `src/App.js`). - -Now you can run `npm run flow` (or `yarn flow`) to check the files for type errors. -You can optionally use an IDE like [Nuclide](https://nuclide.io/docs/languages/flow/) for a better integrated experience. -In the future we plan to integrate it into Create React App even more closely. - -To learn more about Flow, check out [its documentation](https://flowtype.org/). - -## Adding Custom Environment Variables - ->Note: this feature is available with `react-scripts@0.2.3` and higher. - -Your project can consume variables declared in your environment as if they were declared locally in your JS files. By -default you will have `NODE_ENV` defined for you, and any other environment variables starting with -`REACT_APP_`. - -**The environment variables are embedded during the build time**. Since Create React App produces a static HTML/CSS/JS bundle, it can’t possibly read them at runtime. To read them at runtime, you would need to load HTML into memory on the server and replace placeholders in runtime, just like [described here](#injecting-data-from-the-server-into-the-page). Alternatively you can rebuild the app on the server anytime you change them. - ->Note: You must create custom environment variables beginning with `REACT_APP_`. Any other variables except `NODE_ENV` will be ignored to avoid accidentally [exposing a private key on the machine that could have the same name](https://github.com/facebookincubator/create-react-app/issues/865#issuecomment-252199527). Changing any environment variables will require you to restart the development server if it is running. - -These environment variables will be defined for you on `process.env`. For example, having an environment -variable named `REACT_APP_SECRET_CODE` will be exposed in your JS as `process.env.REACT_APP_SECRET_CODE`. - -There is also a special built-in environment variable called `NODE_ENV`. You can read it from `process.env.NODE_ENV`. When you run `npm start`, it is always equal to `'development'`, when you run `npm test` it is always equal to `'test'`, and when you run `npm run build` to make a production bundle, it is always equal to `'production'`. **You cannot override `NODE_ENV` manually.** This prevents developers from accidentally deploying a slow development build to production. - -These environment variables can be useful for displaying information conditionally based on where the project is -deployed or consuming sensitive data that lives outside of version control. - -First, you need to have environment variables defined. For example, let’s say you wanted to consume a secret defined -in the environment inside a `<form>`: - -```jsx -render() { - return ( - <div> - <small>You are running this application in <b>{process.env.NODE_ENV}</b> mode.</small> - <form> - <input type="hidden" defaultValue={process.env.REACT_APP_SECRET_CODE} /> - </form> - </div> - ); -} -``` - -During the build, `process.env.REACT_APP_SECRET_CODE` will be replaced with the current value of the `REACT_APP_SECRET_CODE` environment variable. Remember that the `NODE_ENV` variable will be set for you automatically. - -When you load the app in the browser and inspect the `<input>`, you will see its value set to `abcdef`, and the bold text will show the environment provided when using `npm start`: - -```html -<div> - <small>You are running this application in <b>development</b> mode.</small> - <form> - <input type="hidden" value="abcdef" /> - </form> -</div> -``` - -The above form is looking for a variable called `REACT_APP_SECRET_CODE` from the environment. In order to consume this -value, we need to have it defined in the environment. This can be done using two ways: either in your shell or in -a `.env` file. Both of these ways are described in the next few sections. - -Having access to the `NODE_ENV` is also useful for performing actions conditionally: - -```js -if (process.env.NODE_ENV !== 'production') { - analytics.disable(); -} -``` - -When you compile the app with `npm run build`, the minification step will strip out this condition, and the resulting bundle will be smaller. - -### Referencing Environment Variables in the HTML - ->Note: this feature is available with `react-scripts@0.9.0` and higher. - -You can also access the environment variables starting with `REACT_APP_` in the `public/index.html`. For example: - -```html -<title>%REACT_APP_WEBSITE_NAME% -``` - -Note that the caveats from the above section apply: - -* Apart from a few built-in variables (`NODE_ENV` and `PUBLIC_URL`), variable names must start with `REACT_APP_` to work. -* The environment variables are injected at build time. If you need to inject them at runtime, [follow this approach instead](#generating-dynamic-meta-tags-on-the-server). - -### Adding Temporary Environment Variables In Your Shell - -Defining environment variables can vary between OSes. It’s also important to know that this manner is temporary for the -life of the shell session. - -#### Windows (cmd.exe) - -```cmd -set REACT_APP_SECRET_CODE=abcdef&&npm start -``` - -(Note: the lack of whitespace is intentional.) - -#### Linux, macOS (Bash) - -```bash -REACT_APP_SECRET_CODE=abcdef npm start -``` - -### Adding Development Environment Variables In `.env` - ->Note: this feature is available with `react-scripts@0.5.0` and higher. - -To define permanent environment variables, create a file called `.env` in the root of your project: - -``` -REACT_APP_SECRET_CODE=abcdef -``` - -These variables will act as the defaults if the machine does not explicitly set them.
-Please refer to the [dotenv documentation](https://github.com/motdotla/dotenv) for more details. - ->Note: If you are defining environment variables for development, your CI and/or hosting platform will most likely need -these defined as well. Consult their documentation how to do this. For example, see the documentation for [Travis CI](https://docs.travis-ci.com/user/environment-variables/) or [Heroku](https://devcenter.heroku.com/articles/config-vars). - -## Can I Use Decorators? - -Many popular libraries use [decorators](https://medium.com/google-developers/exploring-es7-decorators-76ecb65fb841) in their documentation.
-Create React App doesn’t support decorator syntax at the moment because: - -* It is an experimental proposal and is subject to change. -* The current specification version is not officially supported by Babel. -* If the specification changes, we won’t be able to write a codemod because we don’t use them internally at Facebook. - -However in many cases you can rewrite decorator-based code without decorators just as fine.
-Please refer to these two threads for reference: - -* [#214](https://github.com/facebookincubator/create-react-app/issues/214) -* [#411](https://github.com/facebookincubator/create-react-app/issues/411) - -Create React App will add decorator support when the specification advances to a stable stage. - -## Integrating with an API Backend - -These tutorials will help you to integrate your app with an API backend running on another port, -using `fetch()` to access it. - -### Node -Check out [this tutorial](https://www.fullstackreact.com/articles/using-create-react-app-with-a-server/). -You can find the companion GitHub repository [here](https://github.com/fullstackreact/food-lookup-demo). - -### Ruby on Rails - -Check out [this tutorial](https://www.fullstackreact.com/articles/how-to-get-create-react-app-to-work-with-your-rails-api/). -You can find the companion GitHub repository [here](https://github.com/fullstackreact/food-lookup-demo-rails). - -## Proxying API Requests in Development - ->Note: this feature is available with `react-scripts@0.2.3` and higher. - -People often serve the front-end React app from the same host and port as their backend implementation.
-For example, a production setup might look like this after the app is deployed: - -``` -/ - static server returns index.html with React app -/todos - static server returns index.html with React app -/api/todos - server handles any /api/* requests using the backend implementation -``` - -Such setup is **not** required. However, if you **do** have a setup like this, it is convenient to write requests like `fetch('/api/todos')` without worrying about redirecting them to another host or port during development. - -To tell the development server to proxy any unknown requests to your API server in development, add a `proxy` field to your `package.json`, for example: - -```js - "proxy": "http://localhost:4000", -``` - -This way, when you `fetch('/api/todos')` in development, the development server will recognize that it’s not a static asset, and will proxy your request to `http://localhost:4000/api/todos` as a fallback. The development server will only attempt to send requests without a `text/html` accept header to the proxy. - -Conveniently, this avoids [CORS issues](http://stackoverflow.com/questions/21854516/understanding-ajax-cors-and-security-considerations) and error messages like this in development: - -``` -Fetch API cannot load http://localhost:4000/api/todos. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:3000' is therefore not allowed access. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled. -``` - -Keep in mind that `proxy` only has effect in development (with `npm start`), and it is up to you to ensure that URLs like `/api/todos` point to the right thing in production. You don’t have to use the `/api` prefix. Any unrecognized request without a `text/html` accept header will be redirected to the specified `proxy`. - -The `proxy` option supports HTTP, HTTPS and WebSocket connections.
-If the `proxy` option is **not** flexible enough for you, alternatively you can: - -* Enable CORS on your server ([here’s how to do it for Express](http://enable-cors.org/server_expressjs.html)). -* Use [environment variables](#adding-custom-environment-variables) to inject the right server host and port into your app. - -## Using HTTPS in Development - ->Note: this feature is available with `react-scripts@0.4.0` and higher. - -You may require the dev server to serve pages over HTTPS. One particular case where this could be useful is when using [the "proxy" feature](#proxying-api-requests-in-development) to proxy requests to an API server when that API server is itself serving HTTPS. - -To do this, set the `HTTPS` environment variable to `true`, then start the dev server as usual with `npm start`: - -#### Windows (cmd.exe) - -```cmd -set HTTPS=true&&npm start -``` - -(Note: the lack of whitespace is intentional.) - -#### Linux, macOS (Bash) - -```bash -HTTPS=true npm start -``` - -Note that the server will use a self-signed certificate, so your web browser will almost definitely display a warning upon accessing the page. - -## Generating Dynamic `` Tags on the Server - -Since Create React App doesn’t support server rendering, you might be wondering how to make `` tags dynamic and reflect the current URL. To solve this, we recommend to add placeholders into the HTML, like this: - -```html - - - - - -``` - -Then, on the server, regardless of the backend you use, you can read `index.html` into memory and replace `__OG_TITLE__`, `__OG_DESCRIPTION__`, and any other placeholders with values depending on the current URL. Just make sure to sanitize and escape the interpolated values so that they are safe to embed into HTML! - -If you use a Node server, you can even share the route matching logic between the client and the server. However duplicating it also works fine in simple cases. - -## Pre-Rendering into Static HTML Files - -If you’re hosting your `build` with a static hosting provider you can use [react-snapshot](https://www.npmjs.com/package/react-snapshot) to generate HTML pages for each route, or relative link, in your application. These pages will then seamlessly become active, or “hydrated”, when the JavaScript bundle has loaded. - -There are also opportunities to use this outside of static hosting, to take the pressure off the server when generating and caching routes. - -The primary benefit of pre-rendering is that you get the core content of each page _with_ the HTML payload—regardless of whether or not your JavaScript bundle successfully downloads. It also increases the likelihood that each route of your application will be picked up by search engines. - -You can read more about [zero-configuration pre-rendering (also called snapshotting) here](https://medium.com/superhighfives/an-almost-static-stack-6df0a2791319). - -## Injecting Data from the Server into the Page - -Similarly to the previous section, you can leave some placeholders in the HTML that inject global variables, for example: - -```js - - - - -``` - -Then, on the server, you can replace `__SERVER_DATA__` with a JSON of real data right before sending the response. The client code can then read `window.SERVER_DATA` to use it. **Make sure to [sanitize the JSON before sending it to the client](https://medium.com/node-security/the-most-common-xss-vulnerability-in-react-js-applications-2bdffbcc1fa0) as it makes your app vulnerable to XSS attacks.** - -## Running Tests - ->Note: this feature is available with `react-scripts@0.3.0` and higher.
->[Read the migration guide to learn how to enable it in older projects!](https://github.com/facebookincubator/create-react-app/blob/master/CHANGELOG.md#migrating-from-023-to-030) - -Create React App uses [Jest](https://facebook.github.io/jest/) as its test runner. To prepare for this integration, we did a [major revamp](https://facebook.github.io/jest/blog/2016/09/01/jest-15.html) of Jest so if you heard bad things about it years ago, give it another try. - -Jest is a Node-based runner. This means that the tests always run in a Node environment and not in a real browser. This lets us enable fast iteration speed and prevent flakiness. - -While Jest provides browser globals such as `window` thanks to [jsdom](https://github.com/tmpvar/jsdom), they are only approximations of the real browser behavior. Jest is intended to be used for unit tests of your logic and your components rather than the DOM quirks. - -We recommend that you use a separate tool for browser end-to-end tests if you need them. They are beyond the scope of Create React App. - -### Filename Conventions - -Jest will look for test files with any of the following popular naming conventions: - -* Files with `.js` suffix in `__tests__` folders. -* Files with `.test.js` suffix. -* Files with `.spec.js` suffix. - -The `.test.js` / `.spec.js` files (or the `__tests__` folders) can be located at any depth under the `src` top level folder. - -We recommend to put the test files (or `__tests__` folders) next to the code they are testing so that relative imports appear shorter. For example, if `App.test.js` and `App.js` are in the same folder, the test just needs to `import App from './App'` instead of a long relative path. Colocation also helps find tests more quickly in larger projects. - -### Command Line Interface - -When you run `npm test`, Jest will launch in the watch mode. Every time you save a file, it will re-run the tests, just like `npm start` recompiles the code. - -The watcher includes an interactive command-line interface with the ability to run all tests, or focus on a search pattern. It is designed this way so that you can keep it open and enjoy fast re-runs. You can learn the commands from the “Watch Usage” note that the watcher prints after every run: - -![Jest watch mode](http://facebook.github.io/jest/img/blog/15-watch.gif) - -### Version Control Integration - -By default, when you run `npm test`, Jest will only run the tests related to files changed since the last commit. This is an optimization designed to make your tests runs fast regardless of how many tests you have. However it assumes that you don’t often commit the code that doesn’t pass the tests. - -Jest will always explicitly mention that it only ran tests related to the files changed since the last commit. You can also press `a` in the watch mode to force Jest to run all tests. - -Jest will always run all tests on a [continuous integration](#continuous-integration) server or if the project is not inside a Git or Mercurial repository. - -### Writing Tests - -To create tests, add `it()` (or `test()`) blocks with the name of the test and its code. You may optionally wrap them in `describe()` blocks for logical grouping but this is neither required nor recommended. - -Jest provides a built-in `expect()` global function for making assertions. A basic test could look like this: - -```js -import sum from './sum'; - -it('sums numbers', () => { - expect(sum(1, 2)).toEqual(3); - expect(sum(2, 2)).toEqual(4); -}); -``` - -All `expect()` matchers supported by Jest are [extensively documented here](http://facebook.github.io/jest/docs/expect.html).
-You can also use [`jest.fn()` and `expect(fn).toBeCalled()`](http://facebook.github.io/jest/docs/expect.html#tohavebeencalled) to create “spies” or mock functions. - -### Testing Components - -There is a broad spectrum of component testing techniques. They range from a “smoke test” verifying that a component renders without throwing, to shallow rendering and testing some of the output, to full rendering and testing component lifecycle and state changes. - -Different projects choose different testing tradeoffs based on how often components change, and how much logic they contain. If you haven’t decided on a testing strategy yet, we recommend that you start with creating simple smoke tests for your components: - -```js -import React from 'react'; -import ReactDOM from 'react-dom'; -import App from './App'; - -it('renders without crashing', () => { - const div = document.createElement('div'); - ReactDOM.render(, div); -}); -``` - -This test mounts a component and makes sure that it didn’t throw during rendering. Tests like this provide a lot value with very little effort so they are great as a starting point, and this is the test you will find in `src/App.test.js`. - -When you encounter bugs caused by changing components, you will gain a deeper insight into which parts of them are worth testing in your application. This might be a good time to introduce more specific tests asserting specific expected output or behavior. - -If you’d like to test components in isolation from the child components they render, we recommend using [`shallow()` rendering API](http://airbnb.io/enzyme/docs/api/shallow.html) from [Enzyme](http://airbnb.io/enzyme/). You can write a smoke test with it too: - -```sh -npm install --save-dev enzyme react-addons-test-utils -``` - -```js -import React from 'react'; -import { shallow } from 'enzyme'; -import App from './App'; - -it('renders without crashing', () => { - shallow(); -}); -``` - -Unlike the previous smoke test using `ReactDOM.render()`, this test only renders `` and doesn’t go deeper. For example, even if `` itself renders a ` + `, +}) +export class CellActionsComponent { + readonly cell = injectTableCellContext() + + onAction() { + console.log('Cell:', this.cell()) + } +} +``` + +```html + + + + +``` + +Each directive uses Angular's `providers` array to register a factory that reads its own input signal. + +This means the token is scoped to the directive's host element and its descendants. Multiple `[tanStackTableCell]` directives on different elements provide independent contexts. + +### Automatic token injection in FlexRender + +When `FlexRender` renders a component or template, it also provides DI tokens automatically based on the render context shape. In the renderer's `#getInjector` method, if the context object contains `table`, `cell`, or `header` properties, the corresponding `TanStackTableToken`, `TanStackTableCellToken`, or `TanStackTableHeaderToken` tokens are provided in the child injector. + +This means that even **without** the context directives, components rendered via `*flexRender` can use `injectTableContext()`, `injectTableCellContext()`, and `injectTableHeaderContext()`. The context directives are only needed for components that live **outside** the `*flexRender` rendering tree (e.g. sibling components in the same ``). diff --git a/docs/framework/angular/guide/table-composition.md b/docs/framework/angular/guide/table-composition.md new file mode 100644 index 0000000000..f56e9a8520 --- /dev/null +++ b/docs/framework/angular/guide/table-composition.md @@ -0,0 +1,295 @@ +--- +title: Table Composition (createTableHook) +--- + +`createTableHook` is a convenience API for creating reusable, type-safe table configurations with pre-bound components. It is inspired by [TanStack Form's `createFormHook`](https://tanstack.com/form/latest/docs/framework/react/guides/form-composition) — a pattern where you define shared infrastructure once and consume it across your application with minimal boilerplate. + +> **When to use it:** Use `createTableHook` when you have multiple tables that share the same configuration (features, row models, and reusable components). For a single table, `injectTable` is sufficient. + +## Examples + +- [Composable Tables](../examples/composable-tables) — Two tables (Users and Products) sharing the same `createTableHook` configuration, with table/cell/header components, sorting, filtering, and pagination. +- [Basic App Table](../examples/basic-app-table) — Minimal example using `createTableHook` with no pre-bound components. + +### createTableHook + +`createTableHook` centralizes your table configuration into a single factory call. It returns a set of typed functions — `injectAppTable`, `createAppColumnHelper`, and pre-typed injection helpers — that you use instead of the base APIs. + +## Setup + +Call `createTableHook` with your shared configuration and destructure the returned utilities: + +```ts +// table.ts — shared table infrastructure + +import { + createTableHook, + tableFeatures, + columnFilteringFeature, + createFilteredRowModel, + createPaginatedRowModel, + createSortedRowModel, + filterFns, + rowPaginationFeature, + rowSortingFeature, + sortFns, +} from '@tanstack/angular-table' + +import { PaginationControls, RowCount, TableToolbar } from './components/table-components' +import { TextCell, NumberCell, StatusCell, ProgressCell } from './components/cell-components' +import { SortIndicator, ColumnFilter } from './components/header-components' + +export const { + createAppColumnHelper, + injectAppTable, + injectTableContext, + injectTableCellContext, + injectTableHeaderContext, +} = createTableHook({ + // Features and row models are shared across all tables + _features: tableFeatures({ + columnFilteringFeature, + rowPaginationFeature, + rowSortingFeature, + }), + _rowModels: { + sortedRowModel: createSortedRowModel(sortFns), + filteredRowModel: createFilteredRowModel(filterFns), + paginatedRowModel: createPaginatedRowModel(), + }, + // Default table options applied to every table + getRowId: (row) => row.id, + + // Pre-bound component registries + tableComponents: { + PaginationControls, + RowCount, + TableToolbar, + }, + cellComponents: { + TextCell, + NumberCell, + StatusCell, + ProgressCell, + }, + headerComponents: { + SortIndicator, + ColumnFilter, + }, +}) +``` + +This single file becomes the source of truth for your application's table infrastructure. + +## What `createTableHook` returns + +| Export | Description | +|---|---| +| `injectAppTable` | A wrapper around `injectTable` that merges default options and attaches component registries. Returns an `AppAngularTable` with table/cell/header components available directly on the instance. | +| `createAppColumnHelper` | A typed column helper where `cell`, `header`, and `footer` definitions receive enhanced context types with the registered components. | +| `injectTableContext` | Pre-typed `injectTableContext()` bound to your feature set. | +| `injectTableCellContext` | Pre-typed `injectTableCellContext()` bound to your feature set. | +| `injectTableHeaderContext` | Pre-typed `injectTableHeaderContext()` bound to your feature set. | +| `injectFlexRenderCellContext` | Pre-typed `injectFlexRenderContext()` for cell context. | +| `injectFlexRenderHeaderContext` | Pre-typed `injectFlexRenderContext()` for header context. | + +## Component registries + +`createTableHook` accepts three component registries that map string keys to Angular components or render functions: + +### `tableComponents` + +Components that need access to the **table instance**. These are attached directly to the `AppAngularTable` object returned by `injectAppTable`, so you can reference them in templates as `table.PaginationControls`, `table.RowCount`, etc. + +Use `injectTableContext()` inside these components to access the table: + +```ts +@Component({ + selector: 'app-pagination-controls', + template: ` + + `, + changeDetection: ChangeDetectionStrategy.OnPush, +}) +export class PaginationControls { + readonly table = injectTableContext() +} +``` + +Render table components via Angular `NgComponentOutlet`: + +```html + + + +``` + +### `cellComponents` + +Components that render **cell content**. These are attached to the `Cell` prototype, so they are available in column definitions through the enhanced `AppCellContext`: + +```ts +const columnHelper = createAppColumnHelper() + +const columns = columnHelper.columns([ + columnHelper.accessor('firstName', { + header: 'First Name', + cell: ({ cell }) => cell.TextCell, + }), + columnHelper.accessor('age', { + header: 'Age', + cell: ({ cell }) => cell.NumberCell, + }), + columnHelper.accessor('status', { + header: 'Status', + cell: ({ cell }) => cell.StatusCell, + }), +]) +``` + +Use `injectTableCellContext()` or `injectFlexRenderContext()` inside cell components: + +```ts +@Component({ + selector: 'span', + template: `{{ cell().getValue() }}`, +}) +export class TextCell { + readonly cell = injectTableCellContext() +} +``` + +### `headerComponents` + +Components or render functions that render **header/footer content**. These are attached to the `Header` prototype and available through the enhanced `AppHeaderContext`: + +```ts +// Render functions work too — they run in injection context +export function SortIndicator(): string | null { + const header = injectTableHeaderContext() + const sorted = header().column.getIsSorted() + if (!sorted) return null + return sorted === 'asc' ? '🔼' : '🔽' +} +``` + +Access header components in the template via `table.appHeader(header)`: + +```html +@for (_header of headerGroup.headers; track _header.id) { + @let header = table.appHeader(_header); + + {{ value }} + +
+
+ +} +``` + +## Using `injectAppTable` + +`injectAppTable` is a wrapper around `injectTable`. It merges the default options from `createTableHook` with the per-table options, and returns an `AppAngularTable` — the standard table instance augmented with: + +- **Table components** directly on the table object (`table.PaginationControls`, `table.TableToolbar`, etc.) +- **`table.appCell(cell)`** — utility type functions for templates that wraps a `Cell` with the registered `cellComponents` +- **`table.appHeader(header)`** — utility type functions for templates that wraps a `Header` with the registered `headerComponents` +- **`table.appFooter(footer)`** — utility type functions for templates that wraps a `Header` (footer) with the registered `headerComponents` + +You do not need to pass `_features` or `_rowModels` — they are inherited from the hook configuration: + +```ts +@Component({ + selector: 'users-table', + templateUrl: './users-table.html', + imports: [FlexRender, TanStackTable, TanStackTableHeader, TanStackTableCell, NgComponentOutlet], + changeDetection: ChangeDetectionStrategy.OnPush, +}) +export class UsersTable { + readonly data = signal(makeData(100)) + + readonly columns = columnHelper.columns([ + columnHelper.accessor('firstName', { + header: 'First Name', + cell: ({ cell }) => cell.TextCell, + }), + // ... + ]) + + // No need to specify _features, _rowModels, ... — they come from createTableHook + table = injectAppTable(() => ({ + columns: this.columns, + data: this.data(), + })) +} +``` + +## Using `createAppColumnHelper` + +`createAppColumnHelper()` returns a column helper identical to `createColumnHelper` at runtime, but with enhanced types: the `cell`, `header`, and `footer` definition callbacks receive `AppCellContext` / `AppHeaderContext` instead of the base context types. + +This means TypeScript knows about your registered components and provides autocompletion: + +```ts +const columnHelper = createAppColumnHelper() + +columnHelper.accessor('firstName', { + cell: ({ cell }) => { + // ✅ TypeScript knows about TextCell, NumberCell, StatusCell, etc. + return cell.TextCell + }, + header: ({ header }) => { + // ✅ TypeScript knows about SortIndicator, ColumnFilter, etc. + return flexRenderComponent(header.SortIndicator) + }, +}) +``` + +You can also use `flexRenderComponent(...)` to wrap the component with custom inputs/outputs: + +```ts +columnHelper.accessor('firstName', { + cell: ({ cell }) => flexRenderComponent(cell.TextCell), + footer: ({ header }) => flexRenderComponent(header.FooterColumnId), +}) +``` + +## Multiple table configurations + +You can call `createTableHook` multiple times to create different table configurations for different parts of your application. Each call returns an independent set of utilities with its own feature set and component registries: + +```ts +// admin-table.ts — tables with editing capabilities +export const { + injectAppTable: injectAdminTable, + createAppColumnHelper: createAdminColumnHelper, +} = createTableHook({ + _features: tableFeatures({ rowSortingFeature, columnFilteringFeature }), + _rowModels: { /* ... */ }, + cellComponents: { EditableCell, DeleteButton }, +}) + +// readonly-table.ts — simpler read-only tables +export const { + injectAppTable: injectReadonlyTable, + createAppColumnHelper: createReadonlyColumnHelper, +} = createTableHook({ + _features: tableFeatures({ rowSortingFeature }), + _rowModels: { /* ... */ }, + cellComponents: { TextCell, NumberCell }, +}) +``` + +## Examples + +- [Composable Tables](../examples/composable-tables) — Full example with two tables sharing the same `createTableHook` configuration. +- [Basic App Table](../examples/basic-app-table) — Minimal example with no pre-bound components. diff --git a/docs/framework/angular/guide/table-state.md b/docs/framework/angular/guide/table-state.md new file mode 100644 index 0000000000..100e5fd601 --- /dev/null +++ b/docs/framework/angular/guide/table-state.md @@ -0,0 +1,217 @@ +--- +title: Table State (Angular) Guide +--- + +## Table State (Angular) Guide + +TanStack Table has a simple underlying internal state management system to store and manage the state of the table. It also lets you selectively pull out any state that you need to manage in your own state management. This guide will walk you through the different ways in which you can interact with and manage the state of the table. + +### Accessing Table State + +You do not need to set up anything special in order for the table state to work. If you pass nothing into either `state`, `initialState`, or any of the `on[State]Change` table options, the table will manage its own state internally. You can access any part of this internal state by using the `table.store.state` table instance API. + +```ts +table = injectTable(() => ({ + columns: this.columns, + data: this.data(), + //... +})) + +someHandler() { + console.log(this.table.store.state) //access the entire internal state + console.log(this.table.store.state.rowSelection) //access just the row selection state +} +``` + +### Custom Initial State + +If all you need to do for certain states is customize their initial default values, you still do not need to manage any of the state yourself. You can simply set values in the `initialState` option of the table instance. + +```jsx +table = injectTable(() => ({ + columns: this.columns, + data: this.data(), + initialState: { + columnOrder: ['age', 'firstName', 'lastName'], //customize the initial column order + columnVisibility: { + id: false //hide the id column by default + }, + expanded: true, //expand all rows by default + sorting: [ + { + id: 'age', + desc: true //sort by age in descending order by default + } + ] + }, + //... +})) +``` + +> **Note**: Only specify each particular state in either `initialState` or `state`, but not both. If you pass in a particular state value to both `initialState` and `state`, the initialized state in `state` will take overwrite any corresponding value in `initialState`. + +### Controlled State + +If you need easy access to the table state in other areas of your application, TanStack Table makes it easy to control and manage any or all of the table state in your own state management system. You can do this by passing in your own state and state management functions to the `state` and `on[State]Change` table options. + +#### Individual Controlled State + +You can control just the state that you need easy access to. You do NOT have to control all of the table state if you do not need to. It is recommended to only control the state that you need on a case-by-case basis. + +In order to control a particular state, you need to both pass in the corresponding `state` value and the `on[State]Change` function to the table instance. + +Let's take filtering, sorting, and pagination as an example in a "manual" server-side data fetching scenario. You can store the filtering, sorting, and pagination state in your own state management, but leave out any other state like column order, column visibility, etc. if your API does not care about those values. + +```ts +import {signal} from '@angular/core'; +import {SortingState, ColumnFiltersState, PaginationState} from '@tanstack/angular-table' +import {toObservable} from "@angular/core/rxjs-interop"; +import {combineLatest, switchMap} from 'rxjs'; + +class TableComponent { + readonly columnFilters = signal([]) //no default filters + readonly sorting = signal([ + { + id: 'age', + desc: true, //sort by age in descending order by default + } + ]) + readonly pagination = signal({ + pageIndex: 0, + pageSize: 15 + }) + + //Use our controlled state values to fetch data + readonly data$ = combineLatest({ + filters: toObservable(this.columnFilters), + sorting: toObservable(this.sorting), + pagination: toObservable(this.pagination) + }).pipe( + switchMap(({filters, sorting, pagination}) => fetchData(filters, sorting, pagination)) + ) + readonly data = toSignal(this.data$); + + readonly table = injectTable(() => ({ + columns: this.columns, + data: this.data(), + //... + state: { + columnFilters: this.columnFilters(), //pass controlled state back to the table (overrides internal state) + sorting: this.sorting(), + pagination: this.pagination(), + }, + onColumnFiltersChange: updater => { //hoist columnFilters state into our own state management + updater instanceof Function + ? this.columnFilters.update(updater) + : this.columnFilters.set(updater) + }, + onSortingChange: updater => { + updater instanceof Function + ? this.sorting.update(updater) + : this.sorting.set(updater) + }, + onPaginationChange: updater => { + updater instanceof Function + ? this.pagination.update(updater) + : this.pagination.set(updater) + }, + })) +} + +//... +``` + +#### Fully Controlled State + +Alternatively, you can control the entire table state with the `onStateChange` table option. It will hoist out the entire table state into your own state management system. Be careful with this approach, as you might find that raising some frequently changing state values up a component tree, like `columnSizingInfo` state`, might cause bad performance issues. + +A couple of more tricks may be needed to make this work. If you use the `onStateChange` table option, the initial values of the `state` must be populated with all of the relevant state values for all of the features that you want to use. You can either manually type out all of the initial state values, or use a constructor in a special way as shown below. + +```ts + + +class TableComponent { + // create an empty table state, we'll override it later + readonly state = signal({} as TableState); + + // create a table instance with default state values + readonly table = injectTable(() => ({ + columns: this.columns, + data: this.data(), + // our fully controlled state overrides the internal state + state: this.state(), + onStateChange: updater => { + // any state changes will be pushed up to our own state management + this.state.set( + updater instanceof Function ? updater(this.state()) : updater + ) + } + })) + + constructor() { + // set the initial table state + this.state.set({ + // populate the initial state with all of the default state values + // from the table instance + ...this.table.initialState, + pagination: { + pageIndex: 0, + pageSize: 15, // optionally customize the initial pagination state. + }, + }) + } +} +``` + +### On State Change Callbacks + +So far, we have seen the `on[State]Change` and `onStateChange` table options work to "hoist" the table state changes into our own state management. However, there are a few things about these using these options that you should be aware of. + +#### 1. **State Change Callbacks MUST have their corresponding state value in the `state` option**. + +Specifying an `on[State]Change` callback tells the table instance that this will be a controlled state. If you do not specify the corresponding `state` value, that state will be "frozen" with its initial value. + +```ts +class TableComponent { + sorting = signal([]) + + table = injectTable(() => ({ + columns: this.columns, + data: this.data(), + //... + state: { + sorting: this.sorting(), // required because we are using `onSortingChange` + }, + onSortingChange: updater => { // makes the `state.sorting` controlled + updater instanceof Function + ? this.sorting.update(updater) + : this.sorting.set(updater) + } + })) +} +``` + +#### 2. **Updaters can either be raw values or callback functions**. + +The `on[State]Change` and `onStateChange` callbacks work exactly like the `setState` functions in React. The updater values can either be a new state value or a callback function that takes the previous state value and returns the new state value. + +What implications does this have? It means that if you want to add in some extra logic in any of the `on[State]Change` callbacks, you can do so, but you need to check whether or not the new incoming updater value is a function or value. + +This is why you will see the `updater instanceof Function ? this.state.update(updater) : this.state.set(updater)` pattern in the examples above. This pattern checks if the updater is a function, and if it is, it calls the function with the previous state value to get the new state value, or the signal will require `signal.update` to be called with the updater instead of `signal.set`. + +### State Types + +All complex states in TanStack Table have their own TypeScript types that you can import and use. This can be handy for ensuring that you are using the correct data structures and properties for the state values that you are controlling. + +```ts +import {injectTable, type SortingState} from '@tanstack/angular-table' + +class TableComponent { + readonly sorting = signal([ + { + id: 'age', // you should get autocomplete for the `id` and `desc` properties + desc: true, + } + ]) +} +``` diff --git a/docs/framework/angular/reference/classes/FlexRenderCell.md b/docs/framework/angular/reference/classes/FlexRenderCell.md new file mode 100644 index 0000000000..b54ae8577e --- /dev/null +++ b/docs/framework/angular/reference/classes/FlexRenderCell.md @@ -0,0 +1,101 @@ +--- +id: FlexRenderCell +title: FlexRenderCell +--- + +# Class: FlexRenderCell\ + +Defined in: [helpers/flexRenderCell.ts:62](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/flexRenderCell.ts#L62) + +Simplified directive wrapper of `*flexRender`. + +Use this utility component to render headers, cells, or footers with custom markup. + +Only one prop (`cell`, `header`, or `footer`) may be passed based on the used selector. + +## Examples + +```html +{{cell}} +{{header}} +{{footer}} +``` + +This replaces calling `*flexRender` directly like this: +```html +{{cell}} +{{header}} +{{footer}} +``` + +Can be imported through FlexRenderCell or [FlexRender](../variables/FlexRender.md) import, +which the latter is preferred. + +```ts +import {FlexRender} from '@tanstack/angular-table + +@Component({ + // ... + imports: [ + FlexRender + ] +}) +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` + +## Constructors + +### Constructor + +```ts +new FlexRenderCell(): FlexRenderCell; +``` + +Defined in: [helpers/flexRenderCell.ts:118](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/flexRenderCell.ts#L118) + +#### Returns + +`FlexRenderCell`\<`TFeatures`, `TData`, `TValue`\> + +## Properties + +### cell + +```ts +readonly cell: InputSignal | undefined>; +``` + +Defined in: [helpers/flexRenderCell.ts:67](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/flexRenderCell.ts#L67) + +*** + +### footer + +```ts +readonly footer: InputSignal | undefined>; +``` + +Defined in: [helpers/flexRenderCell.ts:75](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/flexRenderCell.ts#L75) + +*** + +### header + +```ts +readonly header: InputSignal | undefined>; +``` + +Defined in: [helpers/flexRenderCell.ts:71](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/flexRenderCell.ts#L71) diff --git a/docs/framework/angular/reference/classes/FlexRenderComponentInstance.md b/docs/framework/angular/reference/classes/FlexRenderComponentInstance.md new file mode 100644 index 0000000000..7e79c0a0a4 --- /dev/null +++ b/docs/framework/angular/reference/classes/FlexRenderComponentInstance.md @@ -0,0 +1,230 @@ +--- +id: FlexRenderComponentInstance +title: FlexRenderComponentInstance +--- + +# Class: FlexRenderComponentInstance\ + +Defined in: [flex-render/flexRenderComponent.ts:259](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L259) + +Wrapper class for a component that will be used as content for [FlexRenderDirective](FlexRenderDirective.md) + +Prefer [flexRenderComponent](../functions/flexRenderComponent.md) helper for better type-safety + +## Type Parameters + +### TComponent + +`TComponent` = `any` + +## Implements + +- [`FlexRenderComponent`](../interfaces/FlexRenderComponent.md)\<`TComponent`\> + +## Constructors + +### Constructor + +```ts +new FlexRenderComponentInstance( + component, + inputs?, + injector?, + outputs?, + directives?, +bindings?): FlexRenderComponentInstance; +``` + +Defined in: [flex-render/flexRenderComponent.ts:266](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L266) + +#### Parameters + +##### component + +`Type`\<`TComponent`\> + +##### inputs? + +`Inputs`\<`TComponent`\> + +##### injector? + +`Injector` + +##### outputs? + +`Outputs`\<`TComponent`\> + +##### directives? + +(`Type`\<`unknown`\> \| `DirectiveWithBindings`\<`unknown`\>)[] + +##### bindings? + +`Binding`[] + +#### Returns + +`FlexRenderComponentInstance`\<`TComponent`\> + +## Properties + +### allowedInputNames + +```ts +readonly allowedInputNames: string[] = []; +``` + +Defined in: [flex-render/flexRenderComponent.ts:263](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L263) + +List of allowed input names. + +#### Implementation of + +[`FlexRenderComponent`](../interfaces/FlexRenderComponent.md).[`allowedInputNames`](../interfaces/FlexRenderComponent.md#allowedinputnames) + +*** + +### allowedOutputNames + +```ts +readonly allowedOutputNames: string[] = []; +``` + +Defined in: [flex-render/flexRenderComponent.ts:264](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L264) + +List of allowed output names. + +#### Implementation of + +[`FlexRenderComponent`](../interfaces/FlexRenderComponent.md).[`allowedOutputNames`](../interfaces/FlexRenderComponent.md#allowedoutputnames) + +*** + +### bindings? + +```ts +readonly optional bindings: Binding[]; +``` + +Defined in: [flex-render/flexRenderComponent.ts:272](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L272) + +Bindings to apply to the root component + +#### See + +FlexRenderOptions#bindings + +#### Implementation of + +[`FlexRenderComponent`](../interfaces/FlexRenderComponent.md).[`bindings`](../interfaces/FlexRenderComponent.md#bindings) + +*** + +### component + +```ts +readonly component: Type; +``` + +Defined in: [flex-render/flexRenderComponent.ts:267](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L267) + +The component type + +#### Implementation of + +[`FlexRenderComponent`](../interfaces/FlexRenderComponent.md).[`component`](../interfaces/FlexRenderComponent.md#component) + +*** + +### directives? + +```ts +readonly optional directives: (Type | DirectiveWithBindings)[]; +``` + +Defined in: [flex-render/flexRenderComponent.ts:271](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L271) + +Directives that should be applied to the component. + +#### See + +#### Implementation of + +[`FlexRenderComponent`](../interfaces/FlexRenderComponent.md).[`directives`](../interfaces/FlexRenderComponent.md#directives) + +*** + +### injector? + +```ts +readonly optional injector: Injector; +``` + +Defined in: [flex-render/flexRenderComponent.ts:269](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L269) + +Optional Injector that will be used when rendering the component. + +#### See + +FlexRenderOptions#injector + +#### Implementation of + +[`FlexRenderComponent`](../interfaces/FlexRenderComponent.md).[`injector`](../interfaces/FlexRenderComponent.md#injector) + +*** + +### inputs? + +```ts +readonly optional inputs: Inputs; +``` + +Defined in: [flex-render/flexRenderComponent.ts:268](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L268) + +Component instance inputs. Set via [componentRef.setInput API](https://angular.dev/api/core/ComponentRef#setInput)) + +#### See + +FlexRenderOptions#inputs + +#### Implementation of + +[`FlexRenderComponent`](../interfaces/FlexRenderComponent.md).[`inputs`](../interfaces/FlexRenderComponent.md#inputs) + +*** + +### mirror + +```ts +readonly mirror: ComponentMirror; +``` + +Defined in: [flex-render/flexRenderComponent.ts:262](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L262) + +Reflected metadata about the component. + +#### Implementation of + +[`FlexRenderComponent`](../interfaces/FlexRenderComponent.md).[`mirror`](../interfaces/FlexRenderComponent.md#mirror) + +*** + +### outputs? + +```ts +readonly optional outputs: Outputs; +``` + +Defined in: [flex-render/flexRenderComponent.ts:270](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L270) + +Component instance outputs. Subscribed via OutputEmitterRef#subscribe + +#### See + +FlexRenderOptions#outputs + +#### Implementation of + +[`FlexRenderComponent`](../interfaces/FlexRenderComponent.md).[`outputs`](../interfaces/FlexRenderComponent.md#outputs) diff --git a/docs/framework/angular/reference/classes/FlexRenderDirective.md b/docs/framework/angular/reference/classes/FlexRenderDirective.md new file mode 100644 index 0000000000..386aba706f --- /dev/null +++ b/docs/framework/angular/reference/classes/FlexRenderDirective.md @@ -0,0 +1,121 @@ +--- +id: FlexRenderDirective +title: FlexRenderDirective +--- + +# Class: FlexRenderDirective\ + +Defined in: [flexRender.ts:84](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flexRender.ts#L84) + +Use this utility directive to render headers, cells, or footers with custom markup. + +Note: If you are rendering cell, header, or footer without custom context or other props, +you can use the [FlexRenderCell](FlexRenderCell.md) directive as shorthand instead . + +## Example + +```ts +import {FlexRender} from '@tanstack/angular-table'; + +@Component({ + imports: [FlexRender], + template: ` + + {{cell}} + + + + {{header}} + + + + {{footer}} + + `, +}) +class App { +} +``` + +Can be imported through FlexRenderDirective or [FlexRender](../variables/FlexRender.md) import, +which the latter is preferred. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TRowData + +`TRowData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` + +### TProps + +`TProps` *extends* + \| `NonNullable`\<`unknown`\> + \| `CellContext`\<`TFeatures`, `TRowData`, `TValue`\> + \| `HeaderContext`\<`TFeatures`, `TRowData`, `TValue`\> + +## Constructors + +### Constructor + +```ts +new FlexRenderDirective(): FlexRenderDirective; +``` + +Defined in: [flexRender.ts:109](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flexRender.ts#L109) + +#### Returns + +`FlexRenderDirective`\<`TFeatures`, `TRowData`, `TValue`, `TProps`\> + +## Properties + +### content + +```ts +readonly content: InputSignal>; +``` + +Defined in: [flexRender.ts:93](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flexRender.ts#L93) + +*** + +### injector + +```ts +readonly injector: InputSignal; +``` + +Defined in: [flexRender.ts:102](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flexRender.ts#L102) + +*** + +### props + +```ts +readonly props: InputSignal; +``` + +Defined in: [flexRender.ts:98](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flexRender.ts#L98) diff --git a/docs/framework/angular/reference/classes/TanStackTable.md b/docs/framework/angular/reference/classes/TanStackTable.md new file mode 100644 index 0000000000..5758e49247 --- /dev/null +++ b/docs/framework/angular/reference/classes/TanStackTable.md @@ -0,0 +1,82 @@ +--- +id: TanStackTable +title: TanStackTable +--- + +# Class: TanStackTable\ + +Defined in: [helpers/table.ts:59](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/table.ts#L59) + +Provides a TanStack Table instance (`AngularTable`) in Angular DI. + +The table can be injected by: +- any descendant of an element using `[tanStackTable]="..."` +- any component instantiated by `*flexRender` when the render props contains `table` + +## Example + +```html +
+ +
+``` + +```ts +@Component({ + selector: 'app-pagination', + template: ` + + + `, +}) +export class PaginationComponent { + readonly table = injectTableContext() + + prev() { + this.table().previousPage() + } + next() { + this.table().nextPage() + } +} +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TSelected + +`TSelected` *extends* `object` = `TableState`\<`TFeatures`\> + +## Constructors + +### Constructor + +```ts +new TanStackTable(): TanStackTable; +``` + +#### Returns + +`TanStackTable`\<`TFeatures`, `TData`, `TSelected`\> + +## Properties + +### table + +```ts +readonly table: InputSignal>; +``` + +Defined in: [helpers/table.ts:69](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/table.ts#L69) + +The current TanStack Table instance. + +Provided as a required signal input so DI consumers always read the latest value. diff --git a/docs/framework/angular/reference/classes/TanStackTableCell.md b/docs/framework/angular/reference/classes/TanStackTableCell.md new file mode 100644 index 0000000000..985d1475de --- /dev/null +++ b/docs/framework/angular/reference/classes/TanStackTableCell.md @@ -0,0 +1,92 @@ +--- +id: TanStackTableCell +title: TanStackTableCell +--- + +# Class: TanStackTableCell\ + +Defined in: [helpers/cell.ts:76](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/cell.ts#L76) + +Provides a TanStack Table `Cell` instance in Angular DI. + +The cell can be injected by: +- any descendant of an element using `[tanStackTableCell]="..."` +- any component instantiated by `*flexRender` when the render props contains `cell` + +## Examples + +Inject from the nearest `[tanStackTableCell]`: +```html + + + +``` + +```ts +@Component({ + selector: 'app-cell-actions', + template: `{{ cell().id }}`, +}) +export class CellActionsComponent { + readonly cell = injectTableCellContext() +} +``` + +Inject inside a component rendered via `flexRender`: +```ts +@Component({ + selector: 'app-price-cell', + template: `{{ cell().getValue() }}`, +}) +export class PriceCellComponent { + readonly cell = injectTableCellContext() +} +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` + +## Implements + +- [`TanStackTableCellContext`](../interfaces/TanStackTableCellContext.md)\<`TFeatures`, `TData`, `TValue`\> + +## Constructors + +### Constructor + +```ts +new TanStackTableCell(): TanStackTableCell; +``` + +#### Returns + +`TanStackTableCell`\<`TFeatures`, `TData`, `TValue`\> + +## Properties + +### cell + +```ts +readonly cell: InputSignal>; +``` + +Defined in: [helpers/cell.ts:86](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/cell.ts#L86) + +The current TanStack Table cell. + +Provided as a required signal input so DI consumers always read the latest value. + +#### Implementation of + +[`TanStackTableCellContext`](../interfaces/TanStackTableCellContext.md).[`cell`](../interfaces/TanStackTableCellContext.md#cell) diff --git a/docs/framework/angular/reference/classes/TanStackTableHeader.md b/docs/framework/angular/reference/classes/TanStackTableHeader.md new file mode 100644 index 0000000000..1f1e81e94e --- /dev/null +++ b/docs/framework/angular/reference/classes/TanStackTableHeader.md @@ -0,0 +1,88 @@ +--- +id: TanStackTableHeader +title: TanStackTableHeader +--- + +# Class: TanStackTableHeader\ + +Defined in: [helpers/header.ts:71](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/header.ts#L71) + +Provides a TanStack Table `Header` instance in Angular DI. + +The header can be injected by: +- any descendant of an element using `[tanStackTableHeader]="..."` +- any component instantiated by `*flexRender` when the render props contains `header` + +## Example + +```html + + + +``` + +```ts +@Component({ + selector: 'app-sort-indicator', + template: ` + + `, +}) +export class SortIndicatorComponent { + readonly header = injectTableHeaderContext() + + toggle() { + this.header().column.toggleSorting() + } +} +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` + +## Implements + +- [`TanStackTableHeaderContext`](../interfaces/TanStackTableHeaderContext.md)\<`TFeatures`, `TData`, `TValue`\> + +## Constructors + +### Constructor + +```ts +new TanStackTableHeader(): TanStackTableHeader; +``` + +#### Returns + +`TanStackTableHeader`\<`TFeatures`, `TData`, `TValue`\> + +## Properties + +### header + +```ts +readonly header: InputSignal>; +``` + +Defined in: [helpers/header.ts:81](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/header.ts#L81) + +The current TanStack Table header. + +Provided as a required signal input so DI consumers always read the latest value. + +#### Implementation of + +[`TanStackTableHeaderContext`](../interfaces/TanStackTableHeaderContext.md).[`header`](../interfaces/TanStackTableHeaderContext.md#header) diff --git a/docs/framework/angular/reference/functions/createTableHook.md b/docs/framework/angular/reference/functions/createTableHook.md new file mode 100644 index 0000000000..077a4edbfe --- /dev/null +++ b/docs/framework/angular/reference/functions/createTableHook.md @@ -0,0 +1,40 @@ +--- +id: createTableHook +title: createTableHook +--- + +# Function: createTableHook() + +```ts +function createTableHook(__namedParameters): CreateTableHookResult; +``` + +Defined in: [helpers/createTableHook.ts:352](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L352) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TTableComponents + +`TTableComponents` *extends* `Record`\<`string`, `RenderableComponent`\> + +### TCellComponents + +`TCellComponents` *extends* `Record`\<`string`, `RenderableComponent`\> + +### THeaderComponents + +`THeaderComponents` *extends* `Record`\<`string`, `RenderableComponent`\> + +## Parameters + +### \_\_namedParameters + +[`CreateTableContextOptions`](../type-aliases/CreateTableContextOptions.md)\<`TFeatures`, `TTableComponents`, `TCellComponents`, `THeaderComponents`\> + +## Returns + +[`CreateTableHookResult`](../type-aliases/CreateTableHookResult.md)\<`TFeatures`, `TTableComponents`, `TCellComponents`, `THeaderComponents`\> diff --git a/docs/framework/angular/reference/functions/flexRenderComponent.md b/docs/framework/angular/reference/functions/flexRenderComponent.md new file mode 100644 index 0000000000..b1ba5e998a --- /dev/null +++ b/docs/framework/angular/reference/functions/flexRenderComponent.md @@ -0,0 +1,59 @@ +--- +id: flexRenderComponent +title: flexRenderComponent +--- + +# Function: flexRenderComponent() + +```ts +function flexRenderComponent(component, options?): FlexRenderComponent; +``` + +Defined in: [flex-render/flexRenderComponent.ts:150](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L150) + +Helper function to create a [FlexRenderComponent](../interfaces/FlexRenderComponent.md) instance, with better type-safety. + +## Type Parameters + +### TComponent + +`TComponent` = `any` + +## Parameters + +### component + +`Type`\<`TComponent`\> + +### options? + +`FlexRenderOptions`\<`Inputs`\<`TComponent`\>, `Outputs`\<`TComponent`\>\> + +## Returns + +[`FlexRenderComponent`](../interfaces/FlexRenderComponent.md)\<`TComponent`\> + +## Example + +```ts +import {flexRenderComponent} from '@tanstack/angular-table' +import {inputBinding, outputBinding} from '@angular/core'; + +const columns = [ + { + cell: ({ row }) => { + return flexRenderComponent(MyComponent, { + inputs: { value: mySignalValue() }, + outputs: { valueChange: (val) => {} } + // or using angular native createComponent#binding api + bindings: [ + inputBinding('value', mySignalValue), + outputBinding('valueChange', value => { + console.log("my value changed to", value) + }) + ] + }) + }, + }, +] +``` diff --git a/docs/framework/angular/reference/functions/injectFlexRenderContext.md b/docs/framework/angular/reference/functions/injectFlexRenderContext.md new file mode 100644 index 0000000000..18aabf7488 --- /dev/null +++ b/docs/framework/angular/reference/functions/injectFlexRenderContext.md @@ -0,0 +1,26 @@ +--- +id: injectFlexRenderContext +title: injectFlexRenderContext +--- + +# Function: injectFlexRenderContext() + +```ts +function injectFlexRenderContext(): T; +``` + +Defined in: [flex-render/context.ts:12](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/context.ts#L12) + +Inject the flex render context props. + +Can be used in components rendered via FlexRender directives. + +## Type Parameters + +### T + +`T` *extends* `object` + +## Returns + +`T` diff --git a/docs/framework/angular/reference/functions/injectTable.md b/docs/framework/angular/reference/functions/injectTable.md new file mode 100644 index 0000000000..052fe88913 --- /dev/null +++ b/docs/framework/angular/reference/functions/injectTable.md @@ -0,0 +1,96 @@ +--- +id: injectTable +title: injectTable +--- + +# Function: injectTable() + +```ts +function injectTable(options, selector): AngularTable; +``` + +Defined in: [injectTable.ts:95](https://github.com/TanStack/table/blob/main/packages/angular-table/src/injectTable.ts#L95) + +Creates and returns an Angular-reactive table instance. + +The initializer is intentionally re-evaluated whenever any signal read inside it changes. +This is how the adapter keeps the table in sync with Angular's reactivity model. + +Because of that behavior, keep expensive/static values (for example `columns`, feature setup, row models) +as stable references outside the initializer, and only read reactive state (`data()`, pagination/filter/sorting signals, etc.) +inside it. + +The returned table is also signal-reactive: table state and table APIs are wired for Angular signals, so you can safely consume table methods inside `computed(...)` and `effect(...)`. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TSelected + +`TSelected` = `TableState`\<`TFeatures`\> + +## Parameters + +### options + +() => `TableOptions`\<`TFeatures`, `TData`\> + +### selector + +(`state`) => `TSelected` + +## Returns + +[`AngularTable`](../type-aliases/AngularTable.md)\<`TFeatures`, `TData`, `TSelected`\> + +An Angular-reactive TanStack Table instance. + +## Example + +1. Register the table features you need +```ts +// Register only the features you need +import {tableFeatures, rowPaginationFeature} from '@tanstack/angular-table'; +const _features = tableFeatures({ + rowPaginationFeature, + // ...all other features you need +}) + +// Use all table core features +import {stockFeatures} from '@tanstack/angular-table'; +const _features = tableFeatures(stockFeatures); +``` +2. Prepare the table columns +```ts +import {ColumnDef} from '@tanstack/angular-table'; + +type MyData = {} + +const columns: ColumnDef[] = [ + // ...column definitions +] + +// or using createColumnHelper +import {createColumnHelper} from '@tanstack/angular-table'; +const columnHelper = createColumnHelper(); +const columns = columnHelper.columns([ + columnHelper.accessor(...), + // ...other columns +]) +``` +3. Create the table instance with `injectTable` +```ts +const table = injectTable(() => { + // ...table options, + _features, + columns: columns, + data: myDataSignal(), +}) +``` diff --git a/docs/framework/angular/reference/functions/injectTableCellContext.md b/docs/framework/angular/reference/functions/injectTableCellContext.md new file mode 100644 index 0000000000..99202b535d --- /dev/null +++ b/docs/framework/angular/reference/functions/injectTableCellContext.md @@ -0,0 +1,36 @@ +--- +id: injectTableCellContext +title: injectTableCellContext +--- + +# Function: injectTableCellContext() + +```ts +function injectTableCellContext(): Signal>; +``` + +Defined in: [helpers/cell.ts:98](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/cell.ts#L98) + +Injects the current TanStack Table cell signal. + +Available when: +- there is a nearest `[tanStackTableCell]` directive in the DI tree, or +- the caller is rendered via `*flexRender` with render props containing `cell` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `unknown` + +## Returns + +`Signal`\<`Cell`\<`TFeatures`, `TData`, `TValue`\>\> diff --git a/docs/framework/angular/reference/functions/injectTableContext.md b/docs/framework/angular/reference/functions/injectTableContext.md new file mode 100644 index 0000000000..26356df147 --- /dev/null +++ b/docs/framework/angular/reference/functions/injectTableContext.md @@ -0,0 +1,36 @@ +--- +id: injectTableContext +title: injectTableContext +--- + +# Function: injectTableContext() + +```ts +function injectTableContext(): Signal>; +``` + +Defined in: [helpers/table.ts:81](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/table.ts#L81) + +Injects the current TanStack Table instance signal. + +Available when: +- there is a nearest `[tanStackTable]` directive in the DI tree, or +- the caller is rendered via `*flexRender` with render props containing `table` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TSelected + +`TSelected` *extends* `object` = `TableState`\<`TFeatures`\> + +## Returns + +`Signal`\<[`AngularTable`](../type-aliases/AngularTable.md)\<`TFeatures`, `TData`, `TSelected`\>\> diff --git a/docs/framework/angular/reference/functions/injectTableHeaderContext.md b/docs/framework/angular/reference/functions/injectTableHeaderContext.md new file mode 100644 index 0000000000..0b3981453a --- /dev/null +++ b/docs/framework/angular/reference/functions/injectTableHeaderContext.md @@ -0,0 +1,36 @@ +--- +id: injectTableHeaderContext +title: injectTableHeaderContext +--- + +# Function: injectTableHeaderContext() + +```ts +function injectTableHeaderContext(): Signal>; +``` + +Defined in: [helpers/header.ts:93](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/header.ts#L93) + +Injects the current TanStack Table header signal. + +Available when: +- there is a nearest `[tanStackTableHeader]` directive in the DI tree, or +- the caller is rendered via `*flexRender` with render props containing `header` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `unknown` + +## Returns + +`Signal`\<`Header`\<`TFeatures`, `TData`, `TValue`\>\> diff --git a/docs/framework/angular/reference/index.md b/docs/framework/angular/reference/index.md new file mode 100644 index 0000000000..738b405004 --- /dev/null +++ b/docs/framework/angular/reference/index.md @@ -0,0 +1,52 @@ +--- +id: "@tanstack/angular-table" +title: "@tanstack/angular-table" +--- + +# @tanstack/angular-table + +## Classes + +- [FlexRenderCell](classes/FlexRenderCell.md) +- [FlexRenderComponentInstance](classes/FlexRenderComponentInstance.md) +- [FlexRenderDirective](classes/FlexRenderDirective.md) +- [TanStackTable](classes/TanStackTable.md) +- [TanStackTableCell](classes/TanStackTableCell.md) +- [TanStackTableHeader](classes/TanStackTableHeader.md) + +## Interfaces + +- [AngularReactivityFlags](interfaces/AngularReactivityFlags.md) +- [FlexRenderComponent](interfaces/FlexRenderComponent.md) +- [TanStackTableCellContext](interfaces/TanStackTableCellContext.md) +- [TanStackTableHeaderContext](interfaces/TanStackTableHeaderContext.md) + +## Type Aliases + +- [AngularTable](type-aliases/AngularTable.md) +- [AppAngularTable](type-aliases/AppAngularTable.md) +- [AppCellContext](type-aliases/AppCellContext.md) +- [AppColumnHelper](type-aliases/AppColumnHelper.md) +- [AppHeaderContext](type-aliases/AppHeaderContext.md) +- [CreateTableContextOptions](type-aliases/CreateTableContextOptions.md) +- [CreateTableHookResult](type-aliases/CreateTableHookResult.md) +- [FlexRenderComponentProps](type-aliases/FlexRenderComponentProps.md) +- [FlexRenderContent](type-aliases/FlexRenderContent.md) +- [FlexRenderInputContent](type-aliases/FlexRenderInputContent.md) + +## Variables + +- [FlexRender](variables/FlexRender.md) +- [TanStackTableCellToken](variables/TanStackTableCellToken.md) +- [TanStackTableHeaderToken](variables/TanStackTableHeaderToken.md) +- [TanStackTableToken](variables/TanStackTableToken.md) + +## Functions + +- [createTableHook](functions/createTableHook.md) +- [flexRenderComponent](functions/flexRenderComponent.md) +- [injectFlexRenderContext](functions/injectFlexRenderContext.md) +- [injectTable](functions/injectTable.md) +- [injectTableCellContext](functions/injectTableCellContext.md) +- [injectTableContext](functions/injectTableContext.md) +- [injectTableHeaderContext](functions/injectTableHeaderContext.md) diff --git a/docs/framework/angular/reference/interfaces/AngularReactivityFlags.md b/docs/framework/angular/reference/interfaces/AngularReactivityFlags.md new file mode 100644 index 0000000000..f1f7c474f9 --- /dev/null +++ b/docs/framework/angular/reference/interfaces/AngularReactivityFlags.md @@ -0,0 +1,81 @@ +--- +id: AngularReactivityFlags +title: AngularReactivityFlags +--- + +# Interface: AngularReactivityFlags + +Defined in: [angularReactivityFeature.ts:55](https://github.com/TanStack/table/blob/main/packages/angular-table/src/angularReactivityFeature.ts#L55) + +Fine-grained configuration for Angular reactivity. + +Each key controls whether prototype methods/getters on the corresponding TanStack Table +objects are wrapped with signal-aware access. + +- `true` enables wrapping using the default skip rules. +- `false` disables wrapping entirely for that object type. +- a function allows customizing the skip rules (see SkipPropertyFn). + +## Example + +```ts +const table = injectTable(() => { + // ...table options, + reactivity: { + // fine-grained control over which table objects have reactive properties, + // and which properties are wrapped + header: true, + column: true, + row: true, + cell: true, + } +}) +``` + +## Properties + +### cell + +```ts +cell: boolean | SkipPropertyFn; +``` + +Defined in: [angularReactivityFeature.ts:63](https://github.com/TanStack/table/blob/main/packages/angular-table/src/angularReactivityFeature.ts#L63) + +Controls reactive wrapping for `Cell` instances. + +*** + +### column + +```ts +column: boolean | SkipPropertyFn; +``` + +Defined in: [angularReactivityFeature.ts:59](https://github.com/TanStack/table/blob/main/packages/angular-table/src/angularReactivityFeature.ts#L59) + +Controls reactive wrapping for `Column` instances. + +*** + +### header + +```ts +header: boolean | SkipPropertyFn; +``` + +Defined in: [angularReactivityFeature.ts:57](https://github.com/TanStack/table/blob/main/packages/angular-table/src/angularReactivityFeature.ts#L57) + +Controls reactive wrapping for `Header` instances. + +*** + +### row + +```ts +row: boolean | SkipPropertyFn; +``` + +Defined in: [angularReactivityFeature.ts:61](https://github.com/TanStack/table/blob/main/packages/angular-table/src/angularReactivityFeature.ts#L61) + +Controls reactive wrapping for `Row` instances. diff --git a/docs/framework/angular/reference/interfaces/FlexRenderComponent.md b/docs/framework/angular/reference/interfaces/FlexRenderComponent.md new file mode 100644 index 0000000000..8c5516f86f --- /dev/null +++ b/docs/framework/angular/reference/interfaces/FlexRenderComponent.md @@ -0,0 +1,179 @@ +--- +id: FlexRenderComponent +title: FlexRenderComponent +--- + +# Interface: FlexRenderComponent\ + +Defined in: [flex-render/flexRenderComponent.ts:205](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L205) + +Wrapper interface for a component that will be used as content for [FlexRenderDirective](../classes/FlexRenderDirective.md). +Can be created using [flexRenderComponent](../functions/flexRenderComponent.md) helper. + +## Example + +```ts +import {flexRenderComponent} from '@tanstack/angular-table' + +// Usage in cell/header/footer definition +const columns = [ + { + cell: ({ row }) => { + return flexRenderComponent(MyComponent, { + inputs: { value: mySignalValue() }, + outputs: { valueChange: (val) => {} } + // or using angular createComponent#bindings api + bindings: [ + inputBinding('value', mySignalValue), + outputBinding('valueChange', value => { + console.log("my value changed to", value) + }) + ] + }) + }, + }, +] + +import {input, output} from '@angular/core'; + +@Component({ + selector: 'my-component', +}) +class MyComponent { + readonly value = input(0); + readonly valueChange = output(); +} + +``` + +## Type Parameters + +### TComponent + +`TComponent` = `any` + +## Properties + +### allowedInputNames + +```ts +readonly allowedInputNames: string[]; +``` + +Defined in: [flex-render/flexRenderComponent.ts:217](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L217) + +List of allowed input names. + +*** + +### allowedOutputNames + +```ts +readonly allowedOutputNames: string[]; +``` + +Defined in: [flex-render/flexRenderComponent.ts:221](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L221) + +List of allowed output names. + +*** + +### bindings? + +```ts +optional bindings: Binding[]; +``` + +Defined in: [flex-render/flexRenderComponent.ts:245](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L245) + +Bindings to apply to the root component + +#### See + +FlexRenderOptions#bindings + +*** + +### component + +```ts +readonly component: Type; +``` + +Defined in: [flex-render/flexRenderComponent.ts:209](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L209) + +The component type + +*** + +### directives? + +```ts +optional directives: (Type | DirectiveWithBindings)[]; +``` + +Defined in: [flex-render/flexRenderComponent.ts:251](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L251) + +Directives that should be applied to the component. + +#### See + +*** + +### injector? + +```ts +readonly optional injector: Injector; +``` + +Defined in: [flex-render/flexRenderComponent.ts:239](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L239) + +Optional Injector that will be used when rendering the component. + +#### See + +FlexRenderOptions#injector + +*** + +### inputs? + +```ts +readonly optional inputs: Inputs; +``` + +Defined in: [flex-render/flexRenderComponent.ts:233](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L233) + +Component instance inputs. Set via [componentRef.setInput API](https://angular.dev/api/core/ComponentRef#setInput)) + +#### See + +FlexRenderOptions#inputs + +*** + +### mirror + +```ts +readonly mirror: ComponentMirror; +``` + +Defined in: [flex-render/flexRenderComponent.ts:213](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L213) + +Reflected metadata about the component. + +*** + +### outputs? + +```ts +readonly optional outputs: Outputs; +``` + +Defined in: [flex-render/flexRenderComponent.ts:227](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/flexRenderComponent.ts#L227) + +Component instance outputs. Subscribed via OutputEmitterRef#subscribe + +#### See + +FlexRenderOptions#outputs diff --git a/docs/framework/angular/reference/interfaces/TanStackTableCellContext.md b/docs/framework/angular/reference/interfaces/TanStackTableCellContext.md new file mode 100644 index 0000000000..a81f140e97 --- /dev/null +++ b/docs/framework/angular/reference/interfaces/TanStackTableCellContext.md @@ -0,0 +1,39 @@ +--- +id: TanStackTableCellContext +title: TanStackTableCellContext +--- + +# Interface: TanStackTableCellContext\ + +Defined in: [helpers/cell.ts:11](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/cell.ts#L11) + +DI context shape for a TanStack Table cell. + +This exists to make the current `Cell` injectable by any nested component/directive +without having to pass it through inputs/props manually. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` + +## Properties + +### cell + +```ts +cell: Signal>; +``` + +Defined in: [helpers/cell.ts:17](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/cell.ts#L17) + +Signal that returns the current cell instance. diff --git a/docs/framework/angular/reference/interfaces/TanStackTableHeaderContext.md b/docs/framework/angular/reference/interfaces/TanStackTableHeaderContext.md new file mode 100644 index 0000000000..4b48ff47e8 --- /dev/null +++ b/docs/framework/angular/reference/interfaces/TanStackTableHeaderContext.md @@ -0,0 +1,39 @@ +--- +id: TanStackTableHeaderContext +title: TanStackTableHeaderContext +--- + +# Interface: TanStackTableHeaderContext\ + +Defined in: [helpers/header.ts:11](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/header.ts#L11) + +DI context shape for a TanStack Table header. + +This exists to make the current `Header` injectable by any nested component/directive +without passing it through inputs/props. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` + +## Properties + +### header + +```ts +header: Signal>; +``` + +Defined in: [helpers/header.ts:17](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/header.ts#L17) + +Signal that returns the current header instance. diff --git a/docs/framework/angular/reference/type-aliases/AngularTable.md b/docs/framework/angular/reference/type-aliases/AngularTable.md new file mode 100644 index 0000000000..cce80f9b04 --- /dev/null +++ b/docs/framework/angular/reference/type-aliases/AngularTable.md @@ -0,0 +1,67 @@ +--- +id: AngularTable +title: AngularTable +--- + +# Type Alias: AngularTable\ + +```ts +type AngularTable = Table & object; +``` + +Defined in: [injectTable.ts:21](https://github.com/TanStack/table/blob/main/packages/angular-table/src/injectTable.ts#L21) + +## Type Declaration + +### state + +```ts +readonly state: Signal>; +``` + +The selected state from the table store, based on the selector provided. + +### Subscribe() + +```ts +Subscribe: (props) => Signal>; +``` + +Subscribe to changes in the table store with a custom selector. + +#### Type Parameters + +##### TSubSelected + +`TSubSelected` = \{ +\} + +#### Parameters + +##### props + +###### equal? + +`ValueEqualityFn`\<`TSubSelected`\> + +###### selector + +(`state`) => `TSubSelected` + +#### Returns + +`Signal`\<`Readonly`\<`TSubSelected`\>\> + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TSelected + +`TSelected` = `TableState`\<`TFeatures`\> diff --git a/docs/framework/angular/reference/type-aliases/AppAngularTable.md b/docs/framework/angular/reference/type-aliases/AppAngularTable.md new file mode 100644 index 0000000000..cf2c35fc96 --- /dev/null +++ b/docs/framework/angular/reference/type-aliases/AppAngularTable.md @@ -0,0 +1,108 @@ +--- +id: AppAngularTable +title: AppAngularTable +--- + +# Type Alias: AppAngularTable\ + +```ts +type AppAngularTable = AngularTable & NoInfer & object; +``` + +Defined in: [helpers/createTableHook.ts:243](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L243) + +Extended table API returned by useAppTable with all App wrapper components + +## Type Declaration + +### appCell() + +```ts +appCell: (cell) => Cell & NoInfer; +``` + +#### Type Parameters + +##### TValue + +`TValue` + +#### Parameters + +##### cell + +`Cell`\<`TFeatures`, `TData`, `TValue`\> + +#### Returns + +`Cell`\<`TFeatures`, `TData`, `TValue`\> & `NoInfer`\<`TCellComponents`\> + +### appFooter() + +```ts +appFooter: (footer) => Header & NoInfer; +``` + +#### Type Parameters + +##### TValue + +`TValue` + +#### Parameters + +##### footer + +`Header`\<`TFeatures`, `TData`, `TValue`\> + +#### Returns + +`Header`\<`TFeatures`, `TData`, `TValue`\> & `NoInfer`\<`THeaderComponents`\> + +### appHeader() + +```ts +appHeader: (header) => Header & NoInfer; +``` + +#### Type Parameters + +##### TValue + +`TValue` + +#### Parameters + +##### header + +`Header`\<`TFeatures`, `TData`, `TValue`\> + +#### Returns + +`Header`\<`TFeatures`, `TData`, `TValue`\> & `NoInfer`\<`THeaderComponents`\> + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TSelected + +`TSelected` + +### TTableComponents + +`TTableComponents` *extends* `Record`\<`string`, `RenderableComponent`\> + +### TCellComponents + +`TCellComponents` *extends* `Record`\<`string`, `RenderableComponent`\> + +### THeaderComponents + +`THeaderComponents` *extends* `Record`\<`string`, `RenderableComponent`\> diff --git a/docs/framework/angular/reference/type-aliases/AppCellContext.md b/docs/framework/angular/reference/type-aliases/AppCellContext.md new file mode 100644 index 0000000000..0c4ff3b05c --- /dev/null +++ b/docs/framework/angular/reference/type-aliases/AppCellContext.md @@ -0,0 +1,105 @@ +--- +id: AppCellContext +title: AppCellContext +--- + +# Type Alias: AppCellContext\ + +```ts +type AppCellContext = object; +``` + +Defined in: [helpers/createTableHook.ts:47](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L47) + +Enhanced CellContext with pre-bound cell components. +The `cell` property includes the registered cellComponents. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` + +### TCellComponents + +`TCellComponents` *extends* `Record`\<`string`, `RenderableComponent`\> + +## Properties + +### cell + +```ts +cell: Cell & TCellComponents & object; +``` + +Defined in: [helpers/createTableHook.ts:53](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L53) + +#### Type Declaration + +##### FlexRender() + +```ts +FlexRender: () => unknown; +``` + +###### Returns + +`unknown` + +*** + +### column + +```ts +column: Column; +``` + +Defined in: [helpers/createTableHook.ts:55](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L55) + +*** + +### getValue + +```ts +getValue: CellContext["getValue"]; +``` + +Defined in: [helpers/createTableHook.ts:56](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L56) + +*** + +### renderValue + +```ts +renderValue: CellContext["renderValue"]; +``` + +Defined in: [helpers/createTableHook.ts:57](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L57) + +*** + +### row + +```ts +row: Row; +``` + +Defined in: [helpers/createTableHook.ts:58](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L58) + +*** + +### table + +```ts +table: Table; +``` + +Defined in: [helpers/createTableHook.ts:59](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L59) diff --git a/docs/framework/angular/reference/type-aliases/AppColumnHelper.md b/docs/framework/angular/reference/type-aliases/AppColumnHelper.md new file mode 100644 index 0000000000..df53fe07cc --- /dev/null +++ b/docs/framework/angular/reference/type-aliases/AppColumnHelper.md @@ -0,0 +1,144 @@ +--- +id: AppColumnHelper +title: AppColumnHelper +--- + +# Type Alias: AppColumnHelper\ + +```ts +type AppColumnHelper = object; +``` + +Defined in: [helpers/createTableHook.ts:168](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L168) + +Enhanced column helper with pre-bound components in cell/header/footer contexts. +This enables TypeScript to know about the registered components when defining columns. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TCellComponents + +`TCellComponents` *extends* `Record`\<`string`, `RenderableComponent`\> + +### THeaderComponents + +`THeaderComponents` *extends* `Record`\<`string`, `RenderableComponent`\> + +## Properties + +### accessor() + +```ts +accessor: (accessor, column) => TAccessor extends AccessorFn ? AccessorFnColumnDef : AccessorKeyColumnDef; +``` + +Defined in: [helpers/createTableHook.ts:178](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L178) + +Creates a data column definition with an accessor key or function. +The cell, header, and footer contexts include pre-bound components. + +#### Type Parameters + +##### TAccessor + +`TAccessor` *extends* `AccessorFn`\<`TData`\> \| `DeepKeys`\<`TData`\> + +##### TValue + +`TValue` *extends* `TAccessor` *extends* `AccessorFn`\<`TData`, infer TReturn\> ? `TReturn` : `TAccessor` *extends* `DeepKeys`\<`TData`\> ? `DeepValue`\<`TData`, `TAccessor`\> : `never` + +#### Parameters + +##### accessor + +`TAccessor` + +##### column + +`TAccessor` *extends* `AccessorFn`\<`TData`\> ? `AppColumnDefBase`\<`TFeatures`, `TData`, `TValue`, `TCellComponents`, `THeaderComponents`\> & `object` : `AppColumnDefBase`\<`TFeatures`, `TData`, `TValue`, `TCellComponents`, `THeaderComponents`\> + +#### Returns + +`TAccessor` *extends* `AccessorFn`\<`TData`\> ? `AccessorFnColumnDef`\<`TFeatures`, `TData`, `TValue`\> : `AccessorKeyColumnDef`\<`TFeatures`, `TData`, `TValue`\> + +*** + +### columns() + +```ts +columns: (columns) => ColumnDef[] & [...TColumns]; +``` + +Defined in: [helpers/createTableHook.ts:209](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L209) + +Wraps an array of column definitions to preserve each column's individual TValue type. + +#### Type Parameters + +##### TColumns + +`TColumns` *extends* `ReadonlyArray`\<`ColumnDef`\<`TFeatures`, `TData`, `any`\>\> + +#### Parameters + +##### columns + +\[`...TColumns`\] + +#### Returns + +`ColumnDef`\<`TFeatures`, `TData`, `any`\>[] & \[`...TColumns`\] + +*** + +### display() + +```ts +display: (column) => DisplayColumnDef; +``` + +Defined in: [helpers/createTableHook.ts:217](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L217) + +Creates a display column definition for non-data columns. +The cell, header, and footer contexts include pre-bound components. + +#### Parameters + +##### column + +`AppDisplayColumnDef`\<`TFeatures`, `TData`, `TCellComponents`, `THeaderComponents`\> + +#### Returns + +`DisplayColumnDef`\<`TFeatures`, `TData`, `unknown`\> + +*** + +### group() + +```ts +group: (column) => GroupColumnDef; +``` + +Defined in: [helpers/createTableHook.ts:230](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L230) + +Creates a group column definition with nested child columns. +The cell, header, and footer contexts include pre-bound components. + +#### Parameters + +##### column + +`AppGroupColumnDef`\<`TFeatures`, `TData`, `TCellComponents`, `THeaderComponents`\> + +#### Returns + +`GroupColumnDef`\<`TFeatures`, `TData`, `unknown`\> diff --git a/docs/framework/angular/reference/type-aliases/AppHeaderContext.md b/docs/framework/angular/reference/type-aliases/AppHeaderContext.md new file mode 100644 index 0000000000..0c004cd6cb --- /dev/null +++ b/docs/framework/angular/reference/type-aliases/AppHeaderContext.md @@ -0,0 +1,75 @@ +--- +id: AppHeaderContext +title: AppHeaderContext +--- + +# Type Alias: AppHeaderContext\ + +```ts +type AppHeaderContext = object; +``` + +Defined in: [helpers/createTableHook.ts:66](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L66) + +Enhanced HeaderContext with pre-bound header components. +The `header` property includes the registered headerComponents. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` + +### THeaderComponents + +`THeaderComponents` *extends* `Record`\<`string`, `RenderableComponent`\> + +## Properties + +### column + +```ts +column: Column; +``` + +Defined in: [helpers/createTableHook.ts:72](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L72) + +*** + +### header + +```ts +header: Header & THeaderComponents & object; +``` + +Defined in: [helpers/createTableHook.ts:73](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L73) + +#### Type Declaration + +##### FlexRender() + +```ts +FlexRender: () => unknown; +``` + +###### Returns + +`unknown` + +*** + +### table + +```ts +table: Table; +``` + +Defined in: [helpers/createTableHook.ts:75](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L75) diff --git a/docs/framework/angular/reference/type-aliases/CreateTableContextOptions.md b/docs/framework/angular/reference/type-aliases/CreateTableContextOptions.md new file mode 100644 index 0000000000..4b87417e67 --- /dev/null +++ b/docs/framework/angular/reference/type-aliases/CreateTableContextOptions.md @@ -0,0 +1,83 @@ +--- +id: CreateTableContextOptions +title: CreateTableContextOptions +--- + +# Type Alias: CreateTableContextOptions\ + +```ts +type CreateTableContextOptions = Omit, "columns" | "data" | "store" | "state" | "initialState"> & object; +``` + +Defined in: [helpers/createTableHook.ts:273](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L273) + +Options for creating a table hook with pre-bound components and default table options. +Extends all TableOptions except 'columns' | 'data' | 'store' | 'state' | 'initialState'. + +## Type Declaration + +### cellComponents? + +```ts +optional cellComponents: TCellComponents; +``` + +Cell-level components that need access to the cell instance. +These are available on the cell object passed to AppCell's children. +Use `useCellContext()` inside these components. + +#### Example + +```ts +{ TextCell, NumberCell, DateCell, CurrencyCell } +``` + +### headerComponents? + +```ts +optional headerComponents: THeaderComponents; +``` + +Header-level components that need access to the header instance. +These are available on the header object passed to AppHeader/AppFooter's children. +Use `useHeaderContext()` inside these components. + +#### Example + +```ts +{ SortIndicator, ColumnFilter, ResizeHandle } +``` + +### tableComponents? + +```ts +optional tableComponents: TTableComponents; +``` + +Table-level components that need access to the table instance. +These are available directly on the table object returned by useAppTable. +Use `useTableContext()` inside these components. + +#### Example + +```ts +{ PaginationControls, GlobalFilter, RowCount } +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TTableComponents + +`TTableComponents` *extends* `Record`\<`string`, `RenderableComponent`\> + +### TCellComponents + +`TCellComponents` *extends* `Record`\<`string`, `RenderableComponent`\> + +### THeaderComponents + +`THeaderComponents` *extends* `Record`\<`string`, `RenderableComponent`\> diff --git a/docs/framework/angular/reference/type-aliases/CreateTableHookResult.md b/docs/framework/angular/reference/type-aliases/CreateTableHookResult.md new file mode 100644 index 0000000000..93155a8932 --- /dev/null +++ b/docs/framework/angular/reference/type-aliases/CreateTableHookResult.md @@ -0,0 +1,200 @@ +--- +id: CreateTableHookResult +title: CreateTableHookResult +--- + +# Type Alias: CreateTableHookResult\ + +```ts +type CreateTableHookResult = object; +``` + +Defined in: [helpers/createTableHook.ts:305](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L305) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TTableComponents + +`TTableComponents` *extends* `Record`\<`string`, `RenderableComponent`\> + +### TCellComponents + +`TCellComponents` *extends* `Record`\<`string`, `RenderableComponent`\> + +### THeaderComponents + +`THeaderComponents` *extends* `Record`\<`string`, `RenderableComponent`\> + +## Properties + +### createAppColumnHelper() + +```ts +createAppColumnHelper: () => AppColumnHelper; +``` + +Defined in: [helpers/createTableHook.ts:311](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L311) + +#### Type Parameters + +##### TData + +`TData` *extends* `RowData` + +#### Returns + +[`AppColumnHelper`](AppColumnHelper.md)\<`TFeatures`, `TData`, `TCellComponents`, `THeaderComponents`\> + +*** + +### injectAppTable() + +```ts +injectAppTable: (tableOptions, selector?) => AppAngularTable; +``` + +Defined in: [helpers/createTableHook.ts:336](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L336) + +#### Type Parameters + +##### TData + +`TData` *extends* `RowData` + +##### TSelected + +`TSelected` = `TableState`\<`TFeatures`\> + +#### Parameters + +##### tableOptions + +() => `Omit`\<`TableOptions`\<`TFeatures`, `TData`\>, `"_features"` \| `"_rowModels"`\> + +##### selector? + +(`state`) => `TSelected` + +#### Returns + +[`AppAngularTable`](AppAngularTable.md)\<`TFeatures`, `TData`, `TSelected`, `TTableComponents`, `TCellComponents`, `THeaderComponents`\> + +*** + +### injectFlexRenderCellContext() + +```ts +injectFlexRenderCellContext: () => CellContext; +``` + +Defined in: [helpers/createTableHook.ts:332](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L332) + +#### Type Parameters + +##### TData + +`TData` *extends* `RowData` + +##### TValue + +`TValue` *extends* `CellData` + +#### Returns + +`CellContext`\<`TFeatures`, `TData`, `TValue`\> + +*** + +### injectFlexRenderHeaderContext() + +```ts +injectFlexRenderHeaderContext: () => HeaderContext; +``` + +Defined in: [helpers/createTableHook.ts:328](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L328) + +#### Type Parameters + +##### TData + +`TData` *extends* `RowData` + +##### TValue + +`TValue` *extends* `CellData` + +#### Returns + +`HeaderContext`\<`TFeatures`, `TData`, `TValue`\> + +*** + +### injectTableCellContext() + +```ts +injectTableCellContext: () => Signal>; +``` + +Defined in: [helpers/createTableHook.ts:324](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L324) + +#### Type Parameters + +##### TValue + +`TValue` *extends* `CellData` = `CellData` + +##### TRowData + +`TRowData` *extends* `RowData` = `RowData` + +#### Returns + +`Signal`\<`Cell`\<`TFeatures`, `TRowData`, `TValue`\>\> + +*** + +### injectTableContext() + +```ts +injectTableContext: () => Signal>; +``` + +Defined in: [helpers/createTableHook.ts:317](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L317) + +#### Type Parameters + +##### TData + +`TData` *extends* `RowData` = `RowData` + +#### Returns + +`Signal`\<[`AngularTable`](AngularTable.md)\<`TFeatures`, `TData`\>\> + +*** + +### injectTableHeaderContext() + +```ts +injectTableHeaderContext: () => Signal>; +``` + +Defined in: [helpers/createTableHook.ts:320](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/createTableHook.ts#L320) + +#### Type Parameters + +##### TValue + +`TValue` *extends* `CellData` = `CellData` + +##### TRowData + +`TRowData` *extends* `RowData` = `RowData` + +#### Returns + +`Signal`\<`Header`\<`TFeatures`, `TRowData`, `TValue`\>\> diff --git a/docs/framework/angular/reference/type-aliases/FlexRenderComponentProps.md b/docs/framework/angular/reference/type-aliases/FlexRenderComponentProps.md new file mode 100644 index 0000000000..14ba2f95e1 --- /dev/null +++ b/docs/framework/angular/reference/type-aliases/FlexRenderComponentProps.md @@ -0,0 +1,13 @@ +--- +id: FlexRenderComponentProps +title: FlexRenderComponentProps +--- + +# Type Alias: FlexRenderComponentProps + +```ts +type FlexRenderComponentProps = InjectionToken<{ +}>; +``` + +Defined in: [flex-render/context.ts:3](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/context.ts#L3) diff --git a/docs/framework/angular/reference/type-aliases/FlexRenderContent.md b/docs/framework/angular/reference/type-aliases/FlexRenderContent.md new file mode 100644 index 0000000000..f251b54a38 --- /dev/null +++ b/docs/framework/angular/reference/type-aliases/FlexRenderContent.md @@ -0,0 +1,31 @@ +--- +id: FlexRenderContent +title: FlexRenderContent +--- + +# Type Alias: FlexRenderContent\ + +```ts +type FlexRenderContent = + | string + | number + | Type + | FlexRenderComponent + | TemplateRef<{ + $implicit: TProps; +}> + | null + | Record + | undefined; +``` + +Defined in: [flex-render/renderer.ts:40](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/renderer.ts#L40) + +Content supported by the `flexRender` directive when declaring +a table column header/cell. + +## Type Parameters + +### TProps + +`TProps` *extends* `NonNullable`\<`unknown`\> diff --git a/docs/framework/angular/reference/type-aliases/FlexRenderInputContent.md b/docs/framework/angular/reference/type-aliases/FlexRenderInputContent.md new file mode 100644 index 0000000000..069a0aeb40 --- /dev/null +++ b/docs/framework/angular/reference/type-aliases/FlexRenderInputContent.md @@ -0,0 +1,25 @@ +--- +id: FlexRenderInputContent +title: FlexRenderInputContent +--- + +# Type Alias: FlexRenderInputContent\ + +```ts +type FlexRenderInputContent = + | number + | string + | (props) => FlexRenderContent + | null + | undefined; +``` + +Defined in: [flex-render/renderer.ts:53](https://github.com/TanStack/table/blob/main/packages/angular-table/src/flex-render/renderer.ts#L53) + +Input content supported by the `flexRender` directives. + +## Type Parameters + +### TProps + +`TProps` *extends* `NonNullable`\<`unknown`\> diff --git a/docs/framework/angular/reference/variables/FlexRender.md b/docs/framework/angular/reference/variables/FlexRender.md new file mode 100644 index 0000000000..61d4a34d5e --- /dev/null +++ b/docs/framework/angular/reference/variables/FlexRender.md @@ -0,0 +1,21 @@ +--- +id: FlexRender +title: FlexRender +--- + +# Variable: FlexRender + +```ts +const FlexRender: readonly [typeof FlexRenderDirective, typeof FlexRenderCell]; +``` + +Defined in: [index.ts:25](https://github.com/TanStack/table/blob/main/packages/angular-table/src/index.ts#L25) + +Constant helper to import FlexRender directives. + +You should prefer to use this constant over importing the directives separately, +as it ensures you always have the correct set of directives over library updates. + +## See + +[FlexRenderDirective](../classes/FlexRenderDirective.md) and [FlexRenderCell](../classes/FlexRenderCell.md) for more details on the directives included in this export. diff --git a/docs/framework/angular/reference/variables/TanStackTableCellToken.md b/docs/framework/angular/reference/variables/TanStackTableCellToken.md new file mode 100644 index 0000000000..0074737e5e --- /dev/null +++ b/docs/framework/angular/reference/variables/TanStackTableCellToken.md @@ -0,0 +1,16 @@ +--- +id: TanStackTableCellToken +title: TanStackTableCellToken +--- + +# Variable: TanStackTableCellToken + +```ts +const TanStackTableCellToken: InjectionToken>; +``` + +Defined in: [helpers/cell.ts:25](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/cell.ts#L25) + +Injection token that provides access to the current cell. + +This token is provided by the [TanStackTableCell](../classes/TanStackTableCell.md) directive. diff --git a/docs/framework/angular/reference/variables/TanStackTableHeaderToken.md b/docs/framework/angular/reference/variables/TanStackTableHeaderToken.md new file mode 100644 index 0000000000..985af1fcc1 --- /dev/null +++ b/docs/framework/angular/reference/variables/TanStackTableHeaderToken.md @@ -0,0 +1,16 @@ +--- +id: TanStackTableHeaderToken +title: TanStackTableHeaderToken +--- + +# Variable: TanStackTableHeaderToken + +```ts +const TanStackTableHeaderToken: InjectionToken>; +``` + +Defined in: [helpers/header.ts:25](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/header.ts#L25) + +Injection token that provides access to the current header. + +This token is provided by the [TanStackTableHeader](../classes/TanStackTableHeader.md) directive. diff --git a/docs/framework/angular/reference/variables/TanStackTableToken.md b/docs/framework/angular/reference/variables/TanStackTableToken.md new file mode 100644 index 0000000000..1c20190368 --- /dev/null +++ b/docs/framework/angular/reference/variables/TanStackTableToken.md @@ -0,0 +1,16 @@ +--- +id: TanStackTableToken +title: TanStackTableToken +--- + +# Variable: TanStackTableToken + +```ts +const TanStackTableToken: InjectionToken>; +``` + +Defined in: [helpers/table.ts:11](https://github.com/TanStack/table/blob/main/packages/angular-table/src/helpers/table.ts#L11) + +Injection token that provides access to the current [AngularTable](../type-aliases/AngularTable.md) instance. + +This token is provided by the [TanStackTable](../classes/TanStackTable.md) directive. diff --git a/docs/framework/lit/guide/table-state.md b/docs/framework/lit/guide/table-state.md new file mode 100644 index 0000000000..9bcbebaf8d --- /dev/null +++ b/docs/framework/lit/guide/table-state.md @@ -0,0 +1,193 @@ +--- +title: Table State (Lit) Guide +--- + +## Table State (Lit) Guide + +TanStack Table has a simple underlying internal state management system to store and manage the state of the table. It also lets you selectively pull out any state that you need to manage in your own state management. This guide will walk you through the different ways in which you can interact with and manage the state of the table. + +### Accessing Table State + +You do not need to set up anything special in order for the table state to work. If you pass nothing into either `state`, `initialState`, or any of the `on[State]Change` table options, the table will manage its own state internally. You can access any part of this internal state by using the `table.store.state` table instance API. + +```ts +private tableController = new TableController(this); + +render() { + const table = this.tableController.table({ + columns, + data, + ... + }) + + console.log(table.store.state) //access the entire internal state + console.log(table.store.state.rowSelection) //access just the row selection state + // ... +} +``` + +### Custom Initial State + +If all you need to do for certain states is customize their initial default values, you still do not need to manage any of the state yourself. You can simply set values in the `initialState` option of the table instance. + +```ts +render() { + const table = this.tableController.table({ + columns, + data, + initialState: { + columnOrder: ['age', 'firstName', 'lastName'], //customize the initial column order + columnVisibility: { + id: false //hide the id column by default + }, + expanded: true, //expand all rows by default + sorting: [ + { + id: 'age', + desc: true //sort by age in descending order by default + } + ] + }, + }) + + return html`...`; +} +``` + +> **Note**: Only specify each particular state in either `initialState` or `state`, but not both. If you pass in a particular state value to both `initialState` and `state`, the initialized state in `state` will take overwrite any corresponding value in `initialState`. + +### Controlled State + +If you need easy access to the table state in other areas of your application, TanStack Table makes it easy to control and manage any or all of the table state in your own state management system. You can do this by passing in your own state and state management functions to the `state` and `on[State]Change` table options. + +#### Individual Controlled State + +You can control just the state that you need easy access to. You do NOT have to control all of the table state if you do not need to. It is recommended to only control the state that you need on a case-by-case basis. + +In order to control a particular state, you need to both pass in the corresponding `state` value and the `on[State]Change` function to the table instance. + +Let's take filtering, sorting, and pagination as an example in a "manual" server-side data fetching scenario. You can store the filtering, sorting, and pagination state in your own state management, but leave out any other state like column order, column visibility, etc. if your API does not care about those values. + +```jsx +import {html} from "lit"; + +@customElement('my-component') +class MyComponent extends LitElement { + @state() + private _sorting: SortingState = [] + + render() { + const table = this.tableController.table({ + columns, + data, + state: { + sorting: this._sorting, + }, + onSortingChange: updaterOrValue => { + if (typeof updaterOrValue === 'function') { + this._sorting = updaterOrValue(this._sorting) + } else { + this._sorting = updaterOrValue + } + }, + getSortedRowModel: createSortedRowModel(sortFns), + getCoreRowModel: createCoreRowModel(), + }) + + return html`...` + } +} +//... +``` + +#### Fully Controlled State + +Alternatively, you can control the entire table state with the `onStateChange` table option. It will hoist out the entire table state into your own state management system. Be careful with this approach, as you might find that raising some frequently changing state values up a component tree, like `columnSizingInfo` state`, might cause bad performance issues. + +A couple of more tricks may be needed to make this work. If you use the `onStateChange` table option, the initial values of the `state` must be populated with all of the relevant state values for all of the features that you want to use. You can either manually type out all of the initial state values, or use the `table.setOptions` API in a special way as shown below. + +```ts + +private tableController = new TableController(this); + +@state() +private _tableState; + +render() { + const table = this.tableController.table({ + columns, + data, + getCoreRowModel: createCoreRowModel(), + getSortedRowModel: createSortedRowModel(sortFns) + }) + const state = { ...table.initialState, ...this.tableState }; + table.setOptions(prev => ({ + ...prev, + state, + onStateChange: updater => { + this.tableState = + updater instanceof Function ? updater(state) : updater //any state changes will be pushed up to our own state management + }, + })) + + return html`...`; +} +``` + +### On State Change Callbacks + +So far, we have seen the `on[State]Change` and `onStateChange` table options work to "hoist" the table state changes into our own state management. However, there are a few things about these using these options that you should be aware of. + +#### 1. **State Change Callbacks MUST have their corresponding state value in the `state` option**. + +Specifying an `on[State]Change` callback tells the table instance that this will be a controlled state. If you do not specify the corresponding `state` value, that state will be "frozen" with its initial value. + +```jsx +@state() +private _sorting = []; +//... +render() { + const table = this.tableController.table({ + columns, + data, + state: { + sorting: this._sorting, + }, + onSortingChange: updaterOrValue => { + if (typeof updaterOrValue === 'function') { + this._sorting = updaterOrValue(this._sorting) + } else { + this._sorting = updaterOrValue + } + }, + getSortedRowModel: createSortedRowModel(sortFns), + getCoreRowModel: createCoreRowModel(), + }) + + return html`...`; +} +``` + +#### 2. **Updaters can either be raw values or callback functions**. + +The `on[State]Change` and `onStateChange` callbacks work exactly like the `setState` functions in React. The updater values can either be a new state value or a callback function that takes the previous state value and returns the new state value. + +What implications does this have? It means that if you want to add in some extra logic in any of the `on[State]Change` callbacks, you can do so, but you need to check whether or not the new incoming updater value is a function or value. + +This is why you will see the `updater instanceof Function ? updater(state.value) : updater` pattern in the examples above. This pattern checks if the updater is a function, and if it is, it calls the function with the previous state value to get the new state value. + +### State Types + +All complex states in TanStack Table have their own TypeScript types that you can import and use. This can be handy for ensuring that you are using the correct data structures and properties for the state values that you are controlling. + +```tsx +import { TableController, type SortingState } from '@tanstack/lit-table' +//... +@state() +private _sorting: SortingState = [ + { + id: 'age', //you should get autocomplete for the `id` and `desc` properties + desc: true, + } +] +``` diff --git a/docs/framework/lit/lit-table.md b/docs/framework/lit/lit-table.md new file mode 100644 index 0000000000..8a5c263c9f --- /dev/null +++ b/docs/framework/lit/lit-table.md @@ -0,0 +1,63 @@ +--- +title: Lit Table +--- + +The `@tanstack/lit-table` adapter is a wrapper around the core table logic. Most of it's job is related to managing state the "lit" way, providing types and the rendering implementation of cell/header/footer templates. + +## Exports + +`@tanstack/lit-table` re-exports all of `@tanstack/table-core`'s APIs and the following: + +### `TableController` + +Is a reactive controller that provides a `table` API that takes an `options` object and returns a table instance. + +```ts +import { TableController } from '@tanstack/lit-table' + +@customElement('my-table-element') +class MyTableElement extends LitElement { + private tableController = new TableController(this) + + protected render() { + const table = this.tableController.table(options) + // ...render your table + } +} +``` + +### `flexRender` + +A utility function for rendering cell/header/footer templates with dynamic values. + +Example: + +```jsx +import { flexRender } from '@tanstack/lit-table' +//... +return html` + + ${table + .getRowModel() + .rows.slice(0, 10) + .map( + row => html` + + ${row + .getVisibleCells() + .map( + cell => html` + + ${flexRender( + cell.column.columnDef.cell, + cell.getContext() + )} + + ` + )} + + ` + )} + +` +``` diff --git a/docs/framework/preact/guide/create-table-hook.md b/docs/framework/preact/guide/create-table-hook.md new file mode 100644 index 0000000000..138e749bc0 --- /dev/null +++ b/docs/framework/preact/guide/create-table-hook.md @@ -0,0 +1,169 @@ +--- +title: createTableHook Guide +--- + +`createTableHook` is an advanced API for building reusable, composable table configurations in Preact. It mirrors the [React `createTableHook` API](../react/guide/create-table-hook) — you define features, row models, and pre-bound components once, then reuse them across multiple tables with minimal boilerplate. + +> **When to use it:** Use `createTableHook` when you have multiple tables that share the same configuration. For a single table, `useTable` is sufficient. + +## Setup + +Create a shared table configuration file and call `createTableHook` with your features, row models, and component registries: + +```tsx +// hooks/table.ts + +import { + createTableHook, + tableFeatures, + columnFilteringFeature, + rowPaginationFeature, + rowSortingFeature, + createFilteredRowModel, + createPaginatedRowModel, + createSortedRowModel, + filterFns, + sortFns, +} from '@tanstack/preact-table' + +import { PaginationControls, RowCount, TableToolbar } from '../components/table-components' +import { TextCell, NumberCell, StatusCell } from '../components/cell-components' +import { SortIndicator, ColumnFilter } from '../components/header-components' + +export const { + createAppColumnHelper, + useAppTable, + useTableContext, + useCellContext, + useHeaderContext, +} = createTableHook({ + _features: tableFeatures({ + columnFilteringFeature, + rowPaginationFeature, + rowSortingFeature, + }), + + _rowModels: { + sortedRowModel: createSortedRowModel(sortFns), + filteredRowModel: createFilteredRowModel(filterFns), + paginatedRowModel: createPaginatedRowModel(), + }, + + getRowId: (row) => row.id, + + tableComponents: { + PaginationControls, + RowCount, + TableToolbar, + }, + + cellComponents: { + TextCell, + NumberCell, + StatusCell, + }, + + headerComponents: { + SortIndicator, + ColumnFilter, + }, +}) +``` + +## What `createTableHook` Returns + +| Export | Description | +|--------|-------------| +| `useAppTable` | Hook for creating tables. Merges default options from the hook with per-table options. | +| `createAppColumnHelper` | Column helper with `TFeatures` pre-bound. Only requires `TData`. | +| `useTableContext` | Access the table instance inside `tableComponents`. | +| `useCellContext` | Access the cell instance inside `cellComponents`. | +| `useHeaderContext` | Access the header instance inside `headerComponents`. | + +## Component Registries + +The API matches React's `createTableHook`: + +- **`tableComponents`** — Components attached to the table (`table.PaginationControls`, etc.). Use `useTableContext()` inside them. +- **`cellComponents`** — Components attached to the cell (`cell.TextCell`, etc.). Use `useCellContext()` inside them. +- **`headerComponents`** — Components attached to the header (`header.SortIndicator`, etc.). Use `useHeaderContext()` inside them. + +## Using `useAppTable` + +```tsx +const personColumnHelper = createAppColumnHelper() + +function UsersTable() { + const [data, setData] = useState(() => makeData(100)) + + const columns = useMemo( + () => + personColumnHelper.columns([ + personColumnHelper.accessor('firstName', { + header: 'First Name', + cell: ({ cell }) => , + }), + personColumnHelper.accessor('age', { + header: 'Age', + cell: ({ cell }) => , + }), + ]), + [], + ) + + const table = useAppTable({ + columns, + data, + }) + + return ( + ({ pagination: state.pagination })}> + {() => ( +
+ setData(makeData(100))} /> + + + {table.getHeaderGroups().map((headerGroup) => ( + + {headerGroup.headers.map((h) => ( + + {(header) => ( + + )} + + ))} + + ))} + + + {table.getRowModel().rows.map((row) => ( + + {row.getAllCells().map((c) => ( + + {(cell) => } + + ))} + + ))} + +
+ + +
+ + +
+ )} +
+ ) +} +``` + +## AppTable, AppHeader, AppCell, AppFooter + +Same as React: `table.AppTable`, `table.AppHeader`, `table.AppCell`, and `table.AppFooter` provide context to your registered components. Use the `selector` prop on `AppTable` for optimized re-renders. + +## See Also + +- [React createTableHook Guide](../react/guide/create-table-hook) — The React guide has more detailed examples and the same API. +- [Composable Tables (React)](../react/examples/composable-tables) — Reference implementation (Preact API mirrors React). diff --git a/docs/framework/react/guide/create-table-hook.md b/docs/framework/react/guide/create-table-hook.md new file mode 100644 index 0000000000..254b26daa0 --- /dev/null +++ b/docs/framework/react/guide/create-table-hook.md @@ -0,0 +1,281 @@ +--- +title: createTableHook Guide +--- + +`createTableHook` is an advanced API for building reusable, composable table configurations. It lets you define features, row models, and pre-bound components once, then reuse them across multiple tables with minimal boilerplate. It is inspired by [TanStack Form's `createFormHook`](https://tanstack.com/form/latest/docs/framework/react/guides/form-composition). + +> **When to use it:** Use `createTableHook` when you have multiple tables that share the same configuration (features, row models, and reusable components). For a single table, `useTable` is sufficient. + +## Examples + +- [Composable Tables](../examples/composable-tables) — Two tables (Users and Products) sharing the same `createTableHook` configuration, with table/cell/header components, sorting, filtering, and pagination. +- [Basic useAppTable](../examples/basic-use-app-table) — Minimal example using `createTableHook` with no pre-bound components. + +## Setup + +Create a shared table configuration file and call `createTableHook` with your features, row models, and component registries: + +```tsx +// hooks/table.ts + +import { + createTableHook, + tableFeatures, + columnFilteringFeature, + rowPaginationFeature, + rowSortingFeature, + createFilteredRowModel, + createPaginatedRowModel, + createSortedRowModel, + filterFns, + sortFns, +} from '@tanstack/react-table' + +import { PaginationControls, RowCount, TableToolbar } from '../components/table-components' +import { TextCell, NumberCell, StatusCell, ProgressCell } from '../components/cell-components' +import { SortIndicator, ColumnFilter } from '../components/header-components' + +export const { + createAppColumnHelper, + useAppTable, + useTableContext, + useCellContext, + useHeaderContext, +} = createTableHook({ + _features: tableFeatures({ + columnFilteringFeature, + rowPaginationFeature, + rowSortingFeature, + }), + + _rowModels: { + sortedRowModel: createSortedRowModel(sortFns), + filteredRowModel: createFilteredRowModel(filterFns), + paginatedRowModel: createPaginatedRowModel(), + }, + + getRowId: (row) => row.id, + + tableComponents: { + PaginationControls, + RowCount, + TableToolbar, + }, + + cellComponents: { + TextCell, + NumberCell, + StatusCell, + ProgressCell, + }, + + headerComponents: { + SortIndicator, + ColumnFilter, + }, +}) +``` + +## What `createTableHook` Returns + +| Export | Description | +|--------|-------------| +| `useAppTable` | Hook for creating tables. Merges default options from the hook with per-table options. No need to pass `_features` or `_rowModels`—they come from the hook. | +| `createAppColumnHelper` | Column helper with `TFeatures` pre-bound. Only requires `TData`. Use `createAppColumnHelper()` instead of `createColumnHelper()`. | +| `useTableContext` | Access the table instance inside `tableComponents`. | +| `useCellContext` | Access the cell instance inside `cellComponents`. | +| `useHeaderContext` | Access the header instance inside `headerComponents`. | + +## Component Registries + +### `tableComponents` + +Components that need access to the **table instance**. They are attached to the table object, so you use them as `table.PaginationControls`, `table.RowCount`, etc. + +Use `useTableContext()` inside these components: + +```tsx +export function PaginationControls() { + const table = useTableContext() + + return ( +
+ + +
+ ) +} +``` + +### `cellComponents` + +Components that render **cell content**. They are attached to the `cell` object in column definitions, so you use them as `cell.TextCell`, `cell.NumberCell`, etc. + +Use `useCellContext()` inside these components: + +```tsx +export function TextCell() { + const cell = useCellContext() + return {cell.getValue()} +} + +export function NumberCell() { + const cell = useCellContext() + return {cell.getValue().toLocaleString()} +} +``` + +### `headerComponents` + +Components that render **header/footer content**. They are attached to the `header` object, so you use them as `header.SortIndicator`, `header.ColumnFilter`, etc. + +Use `useHeaderContext()` inside these components: + +```tsx +export function SortIndicator() { + const header = useHeaderContext() + const sorted = header.column.getIsSorted() + if (!sorted) return null + return {sorted === 'asc' ? '🔼' : '🔽'} +} +``` + +## Using `useAppTable` + +Create tables with `useAppTable`—`_features` and `_rowModels` are inherited from the hook: + +```tsx +const personColumnHelper = createAppColumnHelper() + +function UsersTable() { + const [data, setData] = useState(() => makeData(1000)) + + const columns = useMemo( + () => + personColumnHelper.columns([ + personColumnHelper.accessor('firstName', { + header: 'First Name', + cell: ({ cell }) => , + }), + personColumnHelper.accessor('age', { + header: 'Age', + cell: ({ cell }) => , + }), + personColumnHelper.accessor('status', { + header: 'Status', + cell: ({ cell }) => , + }), + ]), + [], + ) + + const table = useAppTable({ + columns, + data, + debugTable: true, + }) + + return ( + ({ pagination: state.pagination, sorting: state.sorting })}> + {({ sorting }) => ( +
+ setData(makeData(1000))} /> + + + {table.getHeaderGroups().map((headerGroup) => ( + + {headerGroup.headers.map((h) => ( + + {(header) => ( + + )} + + ))} + + ))} + + + {table.getRowModel().rows.map((row) => ( + + {row.getAllCells().map((c) => ( + + {(cell) => } + + ))} + + ))} + +
+ + + +
+ + +
+ )} +
+ ) +} +``` + +## AppTable, AppHeader, AppCell, AppFooter + +The table returned by `useAppTable` includes wrapper components that provide context to your registered components: + +- **`table.AppTable`** — Wraps the table UI and provides a `selector` prop for optimized re-renders. Renders its children with the selected state. +- **`table.AppHeader`** — Wraps a header and provides the enhanced `header` context (with `header.SortIndicator`, `header.ColumnFilter`, etc.) to its render prop. +- **`table.AppCell`** — Wraps a cell and provides the enhanced `cell` context (with `cell.TextCell`, `cell.FlexRender`, etc.) to its render prop. +- **`table.AppFooter`** — Same as AppHeader but for footer cells. + +## Optimized Rendering with `selector` + +Pass a `selector` to `table.AppTable` to subscribe only to the state slices you need. This reduces re-renders when other state (e.g., column filters) changes but your component doesn't use it: + +```tsx + ({ + pagination: state.pagination, + sorting: state.sorting, + columnFilters: state.columnFilters, + })} +> + {({ sorting, columnFilters }) => ( + // This only re-renders when pagination, sorting, or columnFilters change +
...
+ )} +
+``` + +For v8-style behavior (re-render on any state change), pass `(state) => state`. + +## Multiple Table Configurations + +You can call `createTableHook` multiple times for different parts of your app: + +```tsx +// admin-tables.ts +export const { useAppTable: useAdminTable, createAppColumnHelper: createAdminColumnHelper } = + createTableHook({ + _features: tableFeatures({ rowSortingFeature, columnFilteringFeature, rowSelectionFeature }), + _rowModels: { /* ... */ }, + cellComponents: { EditableCell, DeleteButton }, + }) + +// readonly-tables.ts +export const { useAppTable: useReadonlyTable, createAppColumnHelper: createReadonlyColumnHelper } = + createTableHook({ + _features: tableFeatures({ rowSortingFeature }), + _rowModels: { /* ... */ }, + cellComponents: { TextCell, NumberCell }, + }) +``` + +## See Also + +- [Migrating to v9](./migrating) — Includes a createTableHook section +- [Composable Tables example](../examples/composable-tables) — Full implementation with two tables diff --git a/docs/framework/react/guide/migrating.md b/docs/framework/react/guide/migrating.md new file mode 100644 index 0000000000..fea5738398 --- /dev/null +++ b/docs/framework/react/guide/migrating.md @@ -0,0 +1,930 @@ +--- +title: Migrating to TanStack Table v9 (React) +--- + +## What's New in TanStack Table v9 + +TanStack Table v9 is a major release that introduces significant architectural improvements while maintaining the core table logic you're familiar with. Here are the key changes: + +### 1. Tree-shaking + +- **Features are tree-shakeable**: Features are now treated as plugins—import only what you use. If your table only needs sorting, you won't ship filtering, pagination, or other feature code. Bundlers can eliminate unused code, so for smaller tables you can expect to bundle ~6–7kb compared to 15–20kb for the same table in v8. This also lets TanStack Table add features over time without bloating everyone's bundles. +- **Row models and their functions are refactored**: Row model factories (`createFilteredRowModel`, `createSortedRowModel`, etc.) now accept their processing functions (`filterFns`, `sortFns`, `aggregationFns`) as parameters. This enables tree-shaking of the functions themselves—if you use a custom filter, you don't pay for built-in filters you never use. + +### 2. State Management + +- **Uses TanStack Store**: The internal state system has been rebuilt on [TanStack Store](https://tanstack.com/store), providing a reactive, framework-agnostic foundation. This works similarly to TanStack Form's state model. +- **Opt-in subscriptions instead of memo hacks**: Use `table.Subscribe` or pass a selector to `useTable` to subscribe to specific slices of state. Only re-render when the state you care about changes—no more `React.memo` or manual memoization. Pass `state => state` if you want v8-style behavior where any state change triggers a re-render. + +### 3. Composability + +- **`tableOptions`**: New utilities let you compose and share table configurations. Define `_features`, `_rowModels`, and default options once, then reuse them across tables or pass them through `createTableHook`. +- **`createTableHook`** (optional, advanced): Create custom table hooks with pre-bound features, row models, and components—similar to TanStack Form's `createFormHook`. Define your table setup once and reuse it across many tables. You don't need this for most use cases; `useTable` is sufficient. + +### The Good News: Most Upgrades Are Opt-in + +While v9 is a significant upgrade, **you don't have to adopt everything at once**: + +- **Don't want to optimize renders?** Pass `state => state` as the selector to `useTable` and rendering works like v8. +- **Don't want to think about tree-shaking?** Import `stockFeatures` to include all features, just like v8. +- **Table markup is largely unchanged.** How you render ``, ``, ``, `} + + +// With selector - children receives cell and selected state + s.columnFilters}> + {(c, filters) => } + +``` + +### AppFooter + +```ts +AppFooter: AppHeaderComponent>; +``` + +Wraps a footer and provides header context with pre-bound headerComponents. +Optionally accepts a selector for Subscribe functionality. + +#### Example + +```tsx + + {(f) => } + +``` + +### AppHeader + +```ts +AppHeader: AppHeaderComponent>; +``` + +Wraps a header and provides header context with pre-bound headerComponents. +Optionally accepts a selector for Subscribe functionality. + +#### Example + +```tsx +// Without selector + + {(h) => } + + +// With selector + s.sorting}> + {(h, sorting) => } + +``` + +### AppTable + +```ts +AppTable: AppTableComponent; +``` + +Root wrapper component that provides table context with optional Subscribe. + +#### Example + +```tsx +// Without selector - children is ReactNode + +
`, etc. remains the same. + +The main change is **how you define a table** with the `useTable` hook — specifically the new `_features` and `_rowModels` options. + +--- + +## Quick Legacy Migration + +Need to migrate incrementally? Use `useLegacyTable` — it accepts the v8-style API while using v9 under the hood. **This is deprecated** and intended only as a temporary migration aid. It includes all features by default, resulting in a larger bundle size. + +Legacy APIs live in a separate export. Import core utilities from `@tanstack/react-table` and legacy-specific APIs from `@tanstack/react-table/legacy`: + +```tsx +import { flexRender } from '@tanstack/react-table' +import { + useLegacyTable, + getCoreRowModel, + getFilteredRowModel, + getSortedRowModel, + getPaginationRowModel, + legacyCreateColumnHelper, +} from '@tanstack/react-table/legacy' +``` + +See the [useLegacyTable Guide](./use-legacy-table.md) for full documentation, examples, and type helpers. + +--- + +The rest of this guide focuses on migrating to the full v9 API and taking advantage of its features. + +## Core Breaking Changes + +### Hook Rename + +The hook name has been simplified to be consistent across all TanStack libraries: + +```tsx +// v8 +import { useReactTable } from '@tanstack/react-table' +const table = useReactTable(options) + +// v9 +import { useTable } from '@tanstack/react-table' +const table = useTable(options) +``` + +### New Required Options: `_features` and `_rowModels` + +In v9, you must explicitly declare which features and row models your table uses: + +```tsx +// v8 +import { useReactTable, getCoreRowModel } from '@tanstack/react-table' + +const table = useReactTable({ + columns, + data, + getCoreRowModel: getCoreRowModel(), +}) + +// v9 +import { useTable, tableFeatures } from '@tanstack/react-table' + +const _features = tableFeatures({}) // Empty = core features only + +const table = useTable({ + _features, + _rowModels: {}, // Core row model is automatic + columns, + data, +}) +``` + +--- + +## The `_features` Option + +Features control what table functionality is available. In v8, all features were bundled. In v9, you import only what you need. + +### Importing Individual Features + +```tsx +import { + tableFeatures, + // Import only the features you need + columnFilteringFeature, + rowSortingFeature, + rowPaginationFeature, + columnVisibilityFeature, + rowSelectionFeature, +} from '@tanstack/react-table' + +// Create a features object (define this outside your component for stable reference) +const _features = tableFeatures({ + columnFilteringFeature, + rowSortingFeature, + rowPaginationFeature, + columnVisibilityFeature, + rowSelectionFeature, +}) +``` + +### Using `stockFeatures` for v8-like Behavior + +If you want all features without thinking about it (like v8), import `stockFeatures`: + +```tsx +import { useTable, stockFeatures } from '@tanstack/react-table' + +const table = useTable({ + _features: stockFeatures, // All features included + _rowModels: { /* ... */ }, + columns, + data, +}) +``` + +### Available Features + +| Feature | Import Name | +|---------|-------------| +| Column Filtering | `columnFilteringFeature` | +| Global Filtering | `globalFilteringFeature` | +| Row Sorting | `rowSortingFeature` | +| Row Pagination | `rowPaginationFeature` | +| Row Selection | `rowSelectionFeature` | +| Row Expanding | `rowExpandingFeature` | +| Row Pinning | `rowPinningFeature` | +| Column Pinning | `columnPinningFeature` | +| Column Visibility | `columnVisibilityFeature` | +| Column Ordering | `columnOrderingFeature` | +| Column Sizing | `columnSizingFeature` | +| Column Resizing | `columnResizingFeature` | +| Column Grouping | `columnGroupingFeature` | +| Column Faceting | `columnFacetingFeature` | + +--- + +## The `_rowModels` Option + +Row models are the functions that process your data (filtering, sorting, pagination, etc.). In v9, they're configured via `_rowModels` instead of `get*RowModel` options. + +### Migration Mapping + +| v8 Option | v9 `_rowModels` Key | v9 Factory Function | +|-----------|---------------------|---------------------| +| `getCoreRowModel()` | (automatic) | Not needed — always included | +| `getFilteredRowModel()` | `filteredRowModel` | `createFilteredRowModel(filterFns)` | +| `getSortedRowModel()` | `sortedRowModel` | `createSortedRowModel(sortFns)` | +| `getPaginationRowModel()` | `paginatedRowModel` | `createPaginatedRowModel()` | +| `getExpandedRowModel()` | `expandedRowModel` | `createExpandedRowModel()` | +| `getGroupedRowModel()` | `groupedRowModel` | `createGroupedRowModel(aggregationFns)` | +| `getFacetedRowModel()` | `facetedRowModel` | `createFacetedRowModel()` | +| `getFacetedMinMaxValues()` | `facetedMinMaxValues` | `createFacetedMinMaxValues()` | +| `getFacetedUniqueValues()` | `facetedUniqueValues` | `createFacetedUniqueValues()` | + +### Key Change: Row Model Functions Now Accept Parameters + +Several row model factories now accept their processing functions as parameters. This enables better tree-shaking and explicit configuration: + +```tsx +import { + createFilteredRowModel, + createSortedRowModel, + createGroupedRowModel, + filterFns, // Built-in filter functions + sortFns, // Built-in sort functions + aggregationFns, // Built-in aggregation functions +} from '@tanstack/react-table' + +const table = useTable({ + _features, + _rowModels: { + filteredRowModel: createFilteredRowModel(filterFns), + sortedRowModel: createSortedRowModel(sortFns), + groupedRowModel: createGroupedRowModel(aggregationFns), + paginatedRowModel: createPaginatedRowModel(), + }, + columns, + data, +}) +``` + +### Full Migration Example + +```tsx +// v8 +import { + useReactTable, + getCoreRowModel, + getFilteredRowModel, + getSortedRowModel, + getPaginationRowModel, + filterFns, + sortingFns, +} from '@tanstack/react-table' + +const table = useReactTable({ + columns, + data, + getCoreRowModel: getCoreRowModel(), // used to be called "get*RowModel()" + getFilteredRowModel: getFilteredRowModel(), + getSortedRowModel: getSortedRowModel(), + getPaginationRowModel: getPaginationRowModel(), + filterFns, // used to be passed in as a root option + sortingFns, +}) + +// v9 +import { + useTable, + tableFeatures, + columnFilteringFeature, + rowSortingFeature, + rowPaginationFeature, + createFilteredRowModel, + createSortedRowModel, + createPaginatedRowModel, + filterFns, + sortFns, +} from '@tanstack/react-table' + +const _features = tableFeatures({ + columnFilteringFeature, + rowSortingFeature, + rowPaginationFeature, +}) + +const table = useTable({ + _features, + _rowModels: { + filteredRowModel: createFilteredRowModel(filterFns), // now called "create*RowModel()" with a Fns parameter + sortedRowModel: createSortedRowModel(sortFns), + paginatedRowModel: createPaginatedRowModel(), + }, + columns, + data, +}) +``` + +--- + +## State Management Changes + +### Accessing State + +In v8, you accessed state via `table.getState()`. In v9, state is accessed differently: + +```tsx +// v8 +const state = table.getState() +const { sorting, pagination } = table.getState() + +// v9 - via the store (full state) +const fullState = table.store.state +const { sorting, pagination } = table.store.state + +// v9 - via table.state (selected state from your selector) +const table = useTable(options, (state) => ({ + sorting: state.sorting, + pagination: state.pagination, +})) +// Now table.state only contains sorting and pagination +const { sorting, pagination } = table.state +``` + +### Optimized Rendering with `table.Subscribe` + +The biggest state management improvement is `table.Subscribe`, which enables fine-grained reactivity: + +```tsx +function MyTable() { + const table = useTable({ + _features, + _rowModels: { /* ... */ }, + columns, + data, + }) + + return ( + ({ + sorting: state.sorting, + pagination: state.pagination, + })} + > + {({ sorting, pagination }) => ( + // This only re-renders when sorting or pagination changes +
+ {/* ... */}
+
Page {pagination.pageIndex + 1}
+
+ )} +
+ ) +} +``` + +### Opt-Out: v8-Style Full State Subscription + +If you want v8-style behavior where the component re-renders on any state change, pass `state => state` as the selector: + +```tsx +// Re-renders on ANY state change (like v8) +const table = useTable( + { + _features, + _rowModels: { /* ... */ }, + columns, + data, + }, + (state) => state, // Subscribe to entire state +) + +// table.state now contains the full state +const { sorting, pagination, columnFilters } = table.state +``` + +### Controlled State + +Controlled state patterns work similarly to v8: + +```tsx +const [sorting, setSorting] = useState([]) +const [pagination, setPagination] = useState({ + pageIndex: 0, + pageSize: 10, +}) + +const table = useTable({ + _features, + _rowModels: { /* ... */ }, + columns, + data, + state: { + sorting, + pagination, + }, + onSortingChange: setSorting, + onPaginationChange: setPagination, +}) +``` + +--- + +## Column Helper Changes + +The `createColumnHelper` function now requires a `TFeatures` type parameter in addition to `TData`: + +```tsx +// v8 +import { createColumnHelper } from '@tanstack/react-table' + +const columnHelper = createColumnHelper() + +// v9 +import { createColumnHelper, tableFeatures, rowSortingFeature } from '@tanstack/react-table' + +const _features = tableFeatures({ rowSortingFeature }) +const columnHelper = createColumnHelper() +``` + +### New `columns()` Helper Method + +v9 adds a `columns()` helper for better type inference when wrapping column arrays. In v8, `TValue` wasn't always type-safe—especially with group columns, where nested column types could be lost or widened. The `columns()` helper uses variadic tuple types to preserve each column's individual `TValue` type, so `info.getValue()` and cell renderers stay correctly typed throughout nested structures: + +```tsx +const columnHelper = createColumnHelper() + +// Wrap your columns array for better type inference +const columns = columnHelper.columns([ + columnHelper.accessor('firstName', { + header: 'First Name', + cell: (info) => info.getValue(), + }), + columnHelper.accessor('lastName', { + id: 'lastName', + header: () => Last Name, + cell: (info) => {info.getValue()}, + }), + columnHelper.display({ + id: 'actions', + header: 'Actions', + cell: (info) => , + }), +]) +``` + +### Using with `createTableHook` + +When using `createTableHook`, you get a pre-bound `createAppColumnHelper` that only requires `TData`: + +```tsx +const { useAppTable, createAppColumnHelper } = createTableHook({ + _features: tableFeatures({ rowSortingFeature }), + _rowModels: { /* ... */ }, +}) + +// TFeatures is already bound — only need TData! +const columnHelper = createAppColumnHelper() +``` + +--- + +## Rendering Changes + +### `flexRender` Function + +The `flexRender` function still exists and works the same way: + +```tsx +import { flexRender } from '@tanstack/react-table' + +// Still works in v9 +{flexRender(cell.column.columnDef.cell, cell.getContext())} +{flexRender(header.column.columnDef.header, header.getContext())} +``` + +### New `` Component + +v9 adds a cleaner component-based approach attached to the table instance: + +```tsx +const table = useTable({ /* ... */ }) + +// Instead of: +{flexRender(header.column.columnDef.header, header.getContext())} + +// You can use: + + + +``` + +This should be way more convenient and type-safe than the old `flexRender` function! + +### Standalone `` Component + +There's also a standalone component you can import: + +```tsx +import { FlexRender } from '@tanstack/react-table' + + + + +``` + +--- + +## The `tableOptions()` Utility + +The `tableOptions()` helper provides type-safe composition of table options. It's useful for creating reusable partial configurations that can be spread into your table setup. + +### Basic Usage + +```tsx +import { tableOptions, tableFeatures, rowSortingFeature } from '@tanstack/react-table' + +// Create a reusable options object with features pre-configured +const baseOptions = tableOptions({ + _features: tableFeatures({ rowSortingFeature }), + debugTable: process.env.NODE_ENV === 'development', +}) + +// Use in your table — columns, data, and other options can be added +const table = useTable({ + ...baseOptions, + columns, + data, + _rowModels: {}, +}) +``` + +### Composing Partial Options + +`tableOptions()` allows you to omit certain required fields (like `data`, `columns`, or `_features`) when creating partial configurations: + +```tsx +// Partial options without data or columns +const featureOptions = tableOptions({ + _features: tableFeatures({ + rowSortingFeature, + columnFilteringFeature, + }), + _rowModels: { + sortedRowModel: createSortedRowModel(sortFns), + filteredRowModel: createFilteredRowModel(filterFns), + }, +}) + +// Another partial without _features (inherits from spread) +const paginationDefaults = tableOptions({ + _rowModels: { + paginatedRowModel: createPaginatedRowModel(), + }, + initialState: { + pagination: { pageIndex: 0, pageSize: 25 }, + }, +}) + +// Combine them +const table = useTable({ + ...featureOptions, + ...paginationDefaults, + columns, + data, +}) +``` + +### Using with `createTableHook` + +`tableOptions()` pairs well with `createTableHook` for building composable table factories: + +```tsx +const sharedOptions = tableOptions({ + _features: tableFeatures({ rowSortingFeature, rowPaginationFeature }), + _rowModels: { + sortedRowModel: createSortedRowModel(sortFns), + paginatedRowModel: createPaginatedRowModel(), + }, +}) + +const { useAppTable } = createTableHook(sharedOptions) +``` + +--- + +## `createTableHook`: Composable Table Patterns + +**This is an advanced, optional feature.** You don't need to use `createTableHook`—`useTable` is sufficient for most use cases. If you're familiar with [TanStack Form](https://tanstack.com/form)'s `createFormHook`, `createTableHook` works almost the same way: it creates a custom hook with pre-bound configuration that you can reuse across many tables. + +For applications with multiple tables sharing the same configuration, `createTableHook` lets you define features, row models, and reusable components once: + +```tsx +// hooks/table.ts +import { + createTableHook, + tableFeatures, + columnFilteringFeature, + rowSortingFeature, + rowPaginationFeature, + createFilteredRowModel, + createSortedRowModel, + createPaginatedRowModel, + filterFns, + sortFns, +} from '@tanstack/react-table' + +// Import your reusable components +import { PaginationControls, SortIndicator, TextCell } from './components' + +export const { + useAppTable, + createAppColumnHelper, + useTableContext, + useCellContext, + useHeaderContext, +} = createTableHook({ + // Features defined once + _features: tableFeatures({ + columnFilteringFeature, + rowSortingFeature, + rowPaginationFeature, + }), + + // Row models defined once + _rowModels: { + filteredRowModel: createFilteredRowModel(filterFns), + sortedRowModel: createSortedRowModel(sortFns), + paginatedRowModel: createPaginatedRowModel(), + }, + + // Default table options + debugTable: process.env.NODE_ENV === 'development', + + // Register reusable components + tableComponents: { PaginationControls }, + cellComponents: { TextCell }, + headerComponents: { SortIndicator }, +}) +``` + +### Using `useAppTable` + +```tsx +// features/users.tsx +import { useAppTable, createAppColumnHelper } from './hooks/table' + +const columnHelper = createAppColumnHelper() + +const columns = columnHelper.columns([ + columnHelper.accessor('firstName', { + header: 'First Name', + cell: ({ cell }) => , // Pre-bound component! + }), +]) + +function UsersTable({ data }: { data: Person[] }) { + const table = useAppTable({ + columns, + data, + // _features and _rowModels already configured! + }) + + return ( + + + + {table.getHeaderGroups().map((headerGroup) => ( + + {headerGroup.headers.map((h) => ( + + {(header) => ( + + )} + + ))} + + ))} + + + {table.getRowModel().rows.map((row) => ( + + {row.getAllCells().map((c) => ( + + {(cell) => ( + + )} + + ))} + + ))} + +
+ + +
+ +
+ +
+ ) +} +``` + +### Context Hooks for Components + +Components registered via `createTableHook` can access their context: + +```tsx +// components/SortIndicator.tsx +import { useHeaderContext } from './hooks/table' + +export function SortIndicator() { + const header = useHeaderContext() + const sorted = header.column.getIsSorted() + + if (!sorted) return null + return sorted === 'asc' ? ' 🔼' : ' 🔽' +} + +// components/TextCell.tsx +import { useCellContext } from './hooks/table' + +export function TextCell() { + const cell = useCellContext() + return {cell.getValue() as string} +} + +// components/PaginationControls.tsx +import { useTableContext } from './hooks/table' + +export function PaginationControls() { + const table = useTableContext() + + return ( + s.pagination}> + {(pagination) => ( +
+ + Page {pagination.pageIndex + 1} + +
+ )} +
+ ) +} +``` + +--- + +## Other Breaking Changes + +### Column Pinning Option Split + +The `enablePinning` option has been split into separate options: + +```tsx +// v8 +enablePinning: true + +// v9 +enableColumnPinning: true +enableRowPinning: true +``` + +### Removed Internal APIs + +All internal APIs prefixed with `_` have been removed. If you were using any of these, use their public equivalents: + +- Removed: `table._getPinnedRows()` +- Removed: `table._getFacetedRowModel()` +- Removed: `table._getFacetedMinMaxValues()` +- Removed: `table._getFacetedUniqueValues()` + +### Column Sizing vs. Column Resizing Split + +In v8, column sizing and resizing were combined in a single feature. In v9, they've been split into separate features for better tree-shaking. + +| v8 | v9 | +|----|-----| +| `ColumnSizing` (combined feature) | `columnSizingFeature` + `columnResizingFeature` | +| `columnSizingInfo` state | `columnResizing` state | +| `setColumnSizingInfo()` | `setColumnResizing()` | +| `onColumnSizingInfoChange` option | `onColumnResizingChange` option | + +If you only need column sizing (fixed widths) without interactive resizing, you can import just `columnSizingFeature`. If you need drag-to-resize functionality, import both: + +```tsx +import { columnSizingFeature, columnResizingFeature } from '@tanstack/react-table' + +const _features = tableFeatures({ + columnSizingFeature, + columnResizingFeature, // Only if you need interactive resizing +}) +``` + +### Sorting API Renames + +Sorting-related APIs have been renamed for consistency: + +| v8 | v9 | +|----|-----| +| `sortingFn` (column def option) | `sortFn` | +| `column.getSortingFn()` | `column.getSortFn()` | +| `column.getAutoSortingFn()` | `column.getAutoSortFn()` | +| `SortingFn` type | `SortFn` type | +| `SortingFns` interface | `SortFns` interface | +| `sortingFns` (built-in functions) | `sortFns` | + +Update your column definitions: + +```tsx +// v8 +const columns = [ + { + accessorKey: 'name', + sortingFn: 'alphanumeric', // or custom function + }, +] + +// v9 +const columns = [ + { + accessorKey: 'name', + sortFn: 'alphanumeric', // or custom function + }, +] +``` + +### Row API Changes + +Some row APIs have changed from private to public: + +| v8 | v9 | +|----|-----| +| `row._getAllCellsByColumnId()` (private) | `row.getAllCellsByColumnId()` (public) | + +If you were accessing this internal API, you can now use it without the underscore prefix. + +--- + +## TypeScript Changes Summary + +### Type Generics + +Most types now require a `TFeatures` parameter: + +```tsx +// v8 +type Column +type ColumnDef +type Table +type Row +type Cell + +// v9 +type Column +type ColumnDef +type Table +type Row +type Cell +``` + +### Using `typeof _features` + +The easiest way to get the `TFeatures` type is with `typeof`: + +```tsx +const _features = tableFeatures({ + rowSortingFeature, + columnFilteringFeature, +}) + +// Use typeof to get the type +type MyFeatures = typeof _features + +const columns: ColumnDef[] = [...] + +function Filter({ column }: { column: Column }) { + // ... +} +``` + +### Using `StockFeatures` + +If using `stockFeatures` with `useTable`, use the `StockFeatures` type: + +```tsx +import type { StockFeatures, ColumnDef } from '@tanstack/react-table' + +const columns: ColumnDef[] = [...] +``` + +### `ColumnMeta` Generic Change + +If you're using module augmentation to extend `ColumnMeta`, note that it now requires a `TFeatures` parameter: + +```tsx +// v8 +declare module '@tanstack/react-table' { + interface ColumnMeta { + customProperty: string + } +} + +// v9 - TFeatures is now the first parameter +declare module '@tanstack/react-table' { + interface ColumnMeta { + customProperty: string + } +} +``` + +### `RowData` Type Restriction + +The `RowData` type is now more restrictive: + +```tsx +// v8 - very permissive +type RowData = unknown | object | any[] + +// v9 - must be a record or array +type RowData = Record | Array +``` + +This change improves type safety. If you were passing unusual data types, ensure your data conforms to `Record` or `Array`. + +--- + +## Migration Checklist + +- [ ] Update import: `useReactTable` → `useTable` +- [ ] Define `_features` using `tableFeatures()` (or use `stockFeatures`) +- [ ] Migrate `get*RowModel()` options to `_rowModels` +- [ ] Update row model factories to include `Fns` parameters where needed +- [ ] Update TypeScript types to include `TFeatures` generic +- [ ] Update state access: `table.getState()` → `table.store.state` or `table.state` +- [ ] Update `createColumnHelper()` → `createColumnHelper()` +- [ ] Replace `enablePinning` with `enableColumnPinning`/`enableRowPinning` if used +- [ ] Rename `sortingFn` → `sortFn` in column definitions +- [ ] Split column sizing/resizing: use both `columnSizingFeature` and `columnResizingFeature` if needed +- [ ] Rename `columnSizingInfo` state → `columnResizing` (and related options) +- [ ] Update `ColumnMeta` module augmentation to include `TFeatures` generic (if used) +- [ ] (Optional) Add `table.Subscribe` for render optimizations +- [ ] (Optional) Use `tableOptions()` for composable configurations +- [ ] (Optional) Migrate to `createTableHook` for reusable table patterns + +--- + +## Examples + +Check out these examples to see v9 patterns in action: + +- [Basic useTable](../examples/basic-use-table) - Simple table with the new `useTable` hook +- [Basic useLegacyTable](../examples/basic-use-legacy-table) - Migration example using `useLegacyTable` +- [Basic useAppTable](../examples/basic-use-app-table) - Using `createTableHook` +- [Filters](../examples/filters) - Filtering with the new API +- [Sorting](../examples/sorting) - Sorting with the new API +- [Composable Tables](../examples/composable-tables) - Advanced `createTableHook` patterns diff --git a/docs/framework/react/guide/table-state.md b/docs/framework/react/guide/table-state.md new file mode 100644 index 0000000000..fa11792898 --- /dev/null +++ b/docs/framework/react/guide/table-state.md @@ -0,0 +1,204 @@ +--- +title: Table State (React) Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [kitchen sink](../examples/kitchen-sink) +- [fully controlled](../examples/fully-controlled) + +## Table State (React) Guide + +TanStack Table has a simple underlying internal state management system to store and manage the state of the table. It also lets you selectively pull out any state that you need to manage in your own state management. This guide will walk you through the different ways in which you can interact with and manage the state of the table. + +### Accessing Table State + +You do not need to set up anything special in order for the table state to work. If you pass nothing into either `state`, `initialState`, or any of the `on[State]Change` table options, the table will manage its own state internally. You can access any part of this internal state by using the `table.store.state` table instance API. + +```jsx +const table = useTable({ + columns, + data, + //... +}) + +console.log(table.store.state) //access the entire internal state +console.log(table.store.state.rowSelection) //access just the row selection state +``` + +### Custom Initial State + +If all you need to do for certain states is customize their initial default values, you still do not need to manage any of the state yourself. You can simply set values in the `initialState` option of the table instance. + +```jsx +const table = useTable({ + columns, + data, + initialState: { + columnOrder: ['age', 'firstName', 'lastName'], //customize the initial column order + columnVisibility: { + id: false //hide the id column by default + }, + expanded: true, //expand all rows by default + sorting: [ + { + id: 'age', + desc: true //sort by age in descending order by default + } + ] + }, + //... +}) +``` + +> **Note**: Only specify each particular state in either `initialState` or `state`, but not both. If you pass in a particular state value to both `initialState` and `state`, the initialized state in `state` will take overwrite any corresponding value in `initialState`. + +### Controlled State + +If you need easy access to the table state in other areas of your application, TanStack Table makes it easy to control and manage any or all of the table state in your own state management system. You can do this by passing in your own state and state management functions to the `state` and `on[State]Change` table options. + +#### Individual Controlled State + +You can control just the state that you need easy access to. You do NOT have to control all of the table state if you do not need to. It is recommended to only control the state that you need on a case-by-case basis. + +In order to control a particular state, you need to both pass in the corresponding `state` value and the `on[State]Change` function to the table instance. + +Let's take filtering, sorting, and pagination as an example in a "manual" server-side data fetching scenario. You can store the filtering, sorting, and pagination state in your own state management, but leave out any other state like column order, column visibility, etc. if your API does not care about those values. + +```jsx +const [columnFilters, setColumnFilters] = React.useState([]) //no default filters +const [sorting, setSorting] = React.useState([{ + id: 'age', + desc: true, //sort by age in descending order by default +}]) +const [pagination, setPagination] = React.useState({ pageIndex: 0, pageSize: 15 }) + +//Use our controlled state values to fetch data +const tableQuery = useQuery({ + queryKey: ['users', columnFilters, sorting, pagination], + queryFn: () => fetchUsers(columnFilters, sorting, pagination), + //... +}) + +const table = useTable({ + columns, + data: tableQuery.data, + //... + state: { + columnFilters, //pass controlled state back to the table (overrides internal state) + sorting, + pagination + }, + onColumnFiltersChange: setColumnFilters, //hoist columnFilters state into our own state management + onSortingChange: setSorting, + onPaginationChange: setPagination, +}) +//... +``` + +#### Fully Controlled State + +Alternatively, you can control the entire table state with the `onStateChange` table option. It will hoist out the entire table state into your own state management system. Be careful with this approach, as you might find that raising some frequently changing state values up a react tree, like `columnSizingInfo` state`, might cause bad performance issues. + +A couple of more tricks may be needed to make this work. If you use the `onStateChange` table option, the initial values of the `state` must be populated with all of the relevant state values for all of the features that you want to use. You can either manually type out all of the initial state values, or use the `table.setOptions` API in a special way as shown below. + +```jsx +//create a table instance with default state values +const table = useTable({ + columns, + data, + //... Note: `state` values are NOT passed in yet +}) + + +const [state, setState] = React.useState({ + ...table.initialState, //populate the initial state with all of the default state values from the table instance + pagination: { + pageIndex: 0, + pageSize: 15 //optionally customize the initial pagination state. + } +}) + +//Use the table.setOptions API to merge our fully controlled state onto the table instance +table.setOptions(prev => ({ + ...prev, //preserve any other options that we have set up above + state, //our fully controlled state overrides the internal state + onStateChange: setState //any state changes will be pushed up to our own state management +})) +``` + +### On State Change Callbacks + +So far, we have seen the `on[State]Change` and `onStateChange` table options work to "hoist" the table state changes into our own state management. However, there are a few things about using these options that you should be aware of. + +#### 1. **State Change Callbacks MUST have their corresponding state value in the `state` option**. + +Specifying an `on[State]Change` callback tells the table instance that this will be a controlled state. If you do not specify the corresponding `state` value, that state will be "frozen" with its initial value. + +```jsx +const [sorting, setSorting] = React.useState([]) +//... +const table = useTable({ + columns, + data, + //... + state: { + sorting, //required because we are using `onSortingChange` + }, + onSortingChange: setSorting, //makes the `state.sorting` controlled +}) +``` + +#### 2. **Updaters can either be raw values or callback functions**. + +The `on[State]Change` and `onStateChange` callbacks work exactly like the `setState` functions in React. The updater values can either be a new state value or a callback function that takes the previous state value and returns the new state value. + +What implications does this have? It means that if you want to add in some extra logic in any of the `on[State]Change` callbacks, you can do so, but you need to check whether or not the new incoming updater value is a function or value. + +```jsx +const [sorting, setSorting] = React.useState([]) +const [pagination, setPagination] = React.useState({ pageIndex: 0, pageSize: 10 }) + +const table = useTable({ + columns, + data, + //... + state: { + pagination, + sorting, + } + //syntax 1 + onPaginationChange: (updater) => { + setPagination(old => { + const newPaginationValue = updater instanceof Function ? updater(old) : updater + //do something with the new pagination value + //... + return newPaginationValue + }) + }, + //syntax 2 + onSortingChange: (updater) => { + const newSortingValue = updater instanceof Function ? updater(sorting) : updater + //do something with the new sorting value + //... + setSorting(updater) //normal state update + } +}) +``` + +### State Types + +All complex states in TanStack Table have their own TypeScript types that you can import and use. This can be handy for ensuring that you are using the correct data structures and properties for the state values that you are controlling. + +```tsx +import { useTable, type SortingState } from '@tanstack/react-table' +//... +const [sorting, setSorting] = React.useState([ + { + id: 'age', //you should get autocomplete for the `id` and `desc` properties + desc: true, + } +]) +``` diff --git a/docs/framework/react/guide/use-legacy-table.md b/docs/framework/react/guide/use-legacy-table.md new file mode 100644 index 0000000000..ce5dd0ef96 --- /dev/null +++ b/docs/framework/react/guide/use-legacy-table.md @@ -0,0 +1,226 @@ +--- +title: Using useLegacyTable for Incremental Migration +--- + +The `useLegacyTable` hook provides a compatibility layer that accepts the v8-style API while using v9 under the hood. This is useful for teams that need to migrate incrementally or have large codebases where a full migration isn't immediately practical. + +> **Warning:** `useLegacyTable` is **deprecated** and intended only as a temporary migration aid. It includes all features by default, resulting in a larger bundle size compared to the tree-shakeable v9 API. Plan to migrate to `useTable` for better performance and smaller bundles. + +## When to Use `useLegacyTable` + +- You have an existing v8 codebase and need to upgrade dependencies +- You want to migrate incrementally, one table at a time +- You need v9 compatibility but don't have time for a full migration yet + +## Basic Usage + +```tsx +import { useState } from 'react' +import { flexRender } from '@tanstack/react-table' +import { + getCoreRowModel, + getFilteredRowModel, + getPaginationRowModel, + getSortedRowModel, + legacyCreateColumnHelper, + useLegacyTable, +} from '@tanstack/react-table/legacy' +import type { + ColumnFiltersState, + PaginationState, + SortingState, +} from '@tanstack/react-table' +import type { + LegacyColumn, + LegacyColumnDef, + LegacyRow, +} from '@tanstack/react-table/legacy' + +interface Person { + name: string + email: string + age: number +} + +const columnHelper = legacyCreateColumnHelper() + +const columns: LegacyColumnDef[] = [ + columnHelper.accessor('name', { header: 'Name' }), + columnHelper.accessor('email', { header: 'Email' }), + columnHelper.accessor('age', { header: 'Age' }), + columnHelper.display({ id: 'actions', header: 'Actions' }), +] + +function MyTable({ data }: { data: Person[] }) { + const [sorting, setSorting] = useState([]) + const [columnFilters, setColumnFilters] = useState([]) + const [pagination, setPagination] = useState({ + pageIndex: 0, + pageSize: 10, + }) + + // useLegacyTable accepts the v8-style API + const table = useLegacyTable({ + columns, + data, + getCoreRowModel: getCoreRowModel(), + getFilteredRowModel: getFilteredRowModel(), + getSortedRowModel: getSortedRowModel(), + getPaginationRowModel: getPaginationRowModel(), + state: { sorting, columnFilters, pagination }, + onSortingChange: setSorting, + onColumnFiltersChange: setColumnFilters, + onPaginationChange: setPagination, + }) + + return ( + + + {table.getHeaderGroups().map((headerGroup) => ( + + {headerGroup.headers.map((header) => ( + + ))} + + ))} + + + {table.getRowModel().rows.map((row) => ( + + {row.getAllCells().map((cell) => ( + + ))} + + ))} + +
+ {flexRender( + header.column.columnDef.header, + header.getContext() + )} + {header.column.getCanFilter() ? ( + + ) : null} +
+ {cell.column.id === 'actions' ? ( + + ) : ( + flexRender(cell.column.columnDef.cell, cell.getContext()) + )} +
+ ) +} + +function Filter({ column }: { column: LegacyColumn }) { + return ( + column.setFilterValue(e.target.value)} + placeholder="Filter..." + /> + ) +} + +function RowActions({ row }: { row: LegacyRow }) { + return +} +``` + +## Type Helpers + +When using `useLegacyTable`, use these type helpers for proper TypeScript support: + +| Type | Description | +|------|-------------| +| `LegacyColumnDef` | Column definition type (equivalent to v8's `ColumnDef`) | +| `LegacyColumn` | Column instance type | +| `LegacyRow` | Row instance type | +| `LegacyCell` | Cell instance type | +| `LegacyTable` | Table instance type | +| `legacyCreateColumnHelper()` | Column helper with StockFeatures pre-bound—only requires TData | + +### Using `legacyCreateColumnHelper` + +Use `legacyCreateColumnHelper` instead of `createColumnHelper`—it has StockFeatures pre-bound, so you only need to specify `TData`: + +```tsx +import { legacyCreateColumnHelper } from '@tanstack/react-table/legacy' +import type { LegacyColumnDef } from '@tanstack/react-table/legacy' + +const columnHelper = legacyCreateColumnHelper() + +const columns: LegacyColumnDef[] = [ + columnHelper.accessor('name', { header: 'Name' }), + // ... +] +``` + +## API Differences from v8 + +While `useLegacyTable` aims for v8 compatibility, there are a few differences: + +### Row Model Functions + +The `get*RowModel()` functions are imported from `@tanstack/react-table/legacy`: + +```tsx +import { + getCoreRowModel, + getFilteredRowModel, + getSortedRowModel, + getPaginationRowModel, + getExpandedRowModel, + getGroupedRowModel, + getFacetedRowModel, + getFacetedMinMaxValues, + getFacetedUniqueValues, +} from '@tanstack/react-table/legacy' +``` + +### Sorting Function Renames + +Note that in v9, sorting-related APIs have been renamed. If you're using custom sorting functions in column definitions: + +| v8 | v9 | +|----|-----| +| `sortingFn` | `sortFn` | + +The legacy table adapter handles this internally for built-in sorting, but if you're defining custom sorting functions, be aware of the rename. + +## Caveats and Limitations + +### Bundle Size + +`useLegacyTable` includes **all features** by default, similar to v8. This means: + +- No tree-shaking benefits +- Bundle size is **much larger** than v8—each feature has grown since v8, and you pay for all of them +- The tree-shakeable v9 API exists so TanStack Table can add features over time without bloating everyone's bundles; only users who opt into a feature pay for it +- If bundle size is a concern, prioritize migrating to the full v9 API + +### Deprecation + +`useLegacyTable` is deprecated and will be removed in a future major version. It exists solely to ease migration. Plan your migration timeline accordingly. + +### No `table.Subscribe` + +The fine-grained reactivity feature (`table.Subscribe`) is not available with `useLegacyTable`. The table re-renders on every state change, like v8. + +### No `createTableHook` Integration + +`useLegacyTable` cannot be used with `createTableHook`. If you want to create reusable table configurations, migrate to the full v9 API. + +## Migration Path + +Once you're ready to migrate to the full v9 API: + +1. Replace `useLegacyTable` with `useTable` +2. Define your `_features` using `tableFeatures()` +3. Convert `get*RowModel()` options to `_rowModels` +4. Update types from `Legacy*` to the standard v9 types + +See the [main migration guide](./migrating.md) for complete instructions. + +## Example + +See the [Basic useLegacyTable example](../examples/basic-use-legacy-table) for a working implementation. diff --git a/docs/framework/react/react-table.md b/docs/framework/react/react-table.md new file mode 100644 index 0000000000..7cbd507263 --- /dev/null +++ b/docs/framework/react/react-table.md @@ -0,0 +1,19 @@ +--- +title: React Table +--- + +The `@tanstack/react-table` adapter is a wrapper around the core table logic. Most of its job is related to managing state the "react" way, providing types and the rendering implementation of cell/header/footer templates. + +## `useTable` + +Takes an `options` object and returns a table. + +```tsx +import { useTable } from '@tanstack/react-table' + +function App() { + const table = useTable(options) + + // ...render your table +} +``` diff --git a/docs/framework/react/reference/index.md b/docs/framework/react/reference/index.md new file mode 100644 index 0000000000..1902741d6c --- /dev/null +++ b/docs/framework/react/reference/index.md @@ -0,0 +1,11 @@ +--- +id: "@tanstack/react-table" +title: "@tanstack/react-table" +--- + +# @tanstack/react-table + +## Modules + +- [index](index/index.md) +- [legacy](legacy/index.md) diff --git a/docs/framework/react/reference/index/functions/FlexRender-1.md b/docs/framework/react/reference/index/functions/FlexRender-1.md new file mode 100644 index 0000000000..1fc66ee6b0 --- /dev/null +++ b/docs/framework/react/reference/index/functions/FlexRender-1.md @@ -0,0 +1,71 @@ +--- +id: FlexRender +title: FlexRender +--- + +# Function: FlexRender() + +```ts +function FlexRender(props): + | string + | number + | bigint + | boolean + | Iterable + | Promise + | Element + | null + | undefined; +``` + +Defined in: [FlexRender.tsx:97](https://github.com/TanStack/table/blob/main/packages/react-table/src/FlexRender.tsx#L97) + +Simplified component wrapper of `flexRender`. Use this utility component to render headers, cells, or footers with custom markup. +Only one prop (`cell`, `header`, or `footer`) may be passed. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### props + +[`FlexRenderProps`](../type-aliases/FlexRenderProps.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + + \| `string` + \| `number` + \| `bigint` + \| `boolean` + \| `Iterable`\<`ReactNode`, `any`, `any`\> + \| `Promise`\<`AwaitedReactNode`\> + \| `Element` + \| `null` + \| `undefined` + +## Example + +```tsx + + + +``` + +This replaces calling `flexRender` directly like this: +```tsx +flexRender(cell.column.columnDef.cell, cell.getContext()) +flexRender(header.column.columnDef.header, header.getContext()) +flexRender(footer.column.columnDef.footer, footer.getContext()) +``` diff --git a/docs/framework/react/reference/index/functions/Subscribe.md b/docs/framework/react/reference/index/functions/Subscribe.md new file mode 100644 index 0000000000..115ca34b4f --- /dev/null +++ b/docs/framework/react/reference/index/functions/Subscribe.md @@ -0,0 +1,61 @@ +--- +id: Subscribe +title: Subscribe +--- + +# Function: Subscribe() + +```ts +function Subscribe(props): ReactNode | Promise; +``` + +Defined in: [Subscribe.ts:58](https://github.com/TanStack/table/blob/main/packages/react-table/src/Subscribe.ts#L58) + +A React component that allows you to subscribe to the table state. + +This is useful for opting into state re-renders for specific parts of the table state. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TSelected + +`TSelected` = \{ +\} + +## Parameters + +### props + +[`SubscribeProps`](../type-aliases/SubscribeProps.md)\<`TFeatures`, `TData`, `TSelected`\> + +## Returns + +`ReactNode` \| `Promise`\<`ReactNode`\> + +## Examples + +```tsx +// As a standalone component + ({ rowSelection: state.rowSelection })}> + {({ rowSelection }) => ( +
Selected rows: {Object.keys(rowSelection).length}
+ )} +
+``` + +```tsx +// As table.Subscribe (table instance method) + ({ rowSelection: state.rowSelection })}> + {({ rowSelection }) => ( +
Selected rows: {Object.keys(rowSelection).length}
+ )} +
+``` diff --git a/docs/framework/react/reference/index/functions/createTableHook.md b/docs/framework/react/reference/index/functions/createTableHook.md new file mode 100644 index 0000000000..51e54b22b1 --- /dev/null +++ b/docs/framework/react/reference/index/functions/createTableHook.md @@ -0,0 +1,322 @@ +--- +id: createTableHook +title: createTableHook +--- + +# Function: createTableHook() + +```ts +function createTableHook(__namedParameters): object; +``` + +Defined in: [createTableHook.tsx:590](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L590) + +Creates a custom table hook with pre-bound components for composition. + +This is the table equivalent of TanStack Form's `createFormHook`. It allows you to: +- Define features, row models, and default options once, shared across all tables +- Register reusable table, cell, and header components +- Access table/cell/header instances via context in those components +- Get a `useAppTable` hook that returns an extended table with App wrapper components +- Get a `createAppColumnHelper` function pre-bound to your features + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TTableComponents + +`TTableComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +### TCellComponents + +`TCellComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +### THeaderComponents + +`THeaderComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +## Parameters + +### \_\_namedParameters + +[`CreateTableHookOptions`](../type-aliases/CreateTableHookOptions.md)\<`TFeatures`, `TTableComponents`, `TCellComponents`, `THeaderComponents`\> + +## Returns + +### appFeatures + +```ts +appFeatures: TFeatures; +``` + +### createAppColumnHelper() + +```ts +createAppColumnHelper: () => AppColumnHelper; +``` + +Create a column helper pre-bound to the features and components configured in this table hook. +The cell, header, and footer contexts include pre-bound components (e.g., `cell.TextCell`). + +#### Type Parameters + +##### TData + +`TData` *extends* `RowData` + +#### Returns + +[`AppColumnHelper`](../type-aliases/AppColumnHelper.md)\<`TFeatures`, `TData`, `TCellComponents`, `THeaderComponents`\> + +#### Example + +```tsx +const columnHelper = createAppColumnHelper() + +const columns = [ + columnHelper.accessor('firstName', { + header: 'First Name', + cell: ({ cell }) => , // cell has pre-bound components! + }), + columnHelper.accessor('age', { + header: 'Age', + cell: ({ cell }) => , + }), +] +``` + +### useAppTable() + +```ts +useAppTable: (tableOptions, selector?) => AppReactTable; +``` + +Enhanced useTable hook that returns a table with App wrapper components +and pre-bound tableComponents attached directly to the table object. + +Default options from createTableHook are automatically merged with +the options passed here. Options passed here take precedence. + +TFeatures is already known from the createTableHook call; TData is inferred from the data prop. + +#### Type Parameters + +##### TData + +`TData` *extends* `RowData` + +##### TSelected + +`TSelected` = \{ +\} + +#### Parameters + +##### tableOptions + +`Omit`\<`TableOptions`\<`TFeatures`, `TData`\>, `"_features"` \| `"_rowModels"`\> + +##### selector? + +(`state`) => `TSelected` + +#### Returns + +[`AppReactTable`](../type-aliases/AppReactTable.md)\<`TFeatures`, `TData`, `TSelected`, `TTableComponents`, `TCellComponents`, `THeaderComponents`\> + +### useCellContext() + +```ts +useCellContext: () => Cell; +``` + +Access the cell instance from within an `AppCell` wrapper. +Use this in custom `cellComponents` passed to `createTableHook`. +TFeatures is already known from the createTableHook call. + +#### Type Parameters + +##### TValue + +`TValue` *extends* `unknown` = `unknown` + +#### Returns + +`Cell`\<`TFeatures`, `any`, `TValue`\> + +#### Example + +```tsx +function TextCell() { + const cell = useCellContext() + return {cell.getValue()} +} + +function NumberCell({ format }: { format?: Intl.NumberFormatOptions }) { + const cell = useCellContext() + return {cell.getValue().toLocaleString(undefined, format)} +} +``` + +### useHeaderContext() + +```ts +useHeaderContext: () => Header; +``` + +Access the header instance from within an `AppHeader` or `AppFooter` wrapper. +Use this in custom `headerComponents` passed to `createTableHook`. +TFeatures is already known from the createTableHook call. + +#### Type Parameters + +##### TValue + +`TValue` *extends* `unknown` = `unknown` + +#### Returns + +`Header`\<`TFeatures`, `any`, `TValue`\> + +#### Example + +```tsx +function SortIndicator() { + const header = useHeaderContext() + const sorted = header.column.getIsSorted() + return sorted === 'asc' ? '🔼' : sorted === 'desc' ? '🔽' : null +} + +function ColumnFilter() { + const header = useHeaderContext() + if (!header.column.getCanFilter()) return null + return ( + header.column.setFilterValue(e.target.value)} + placeholder="Filter..." + /> + ) +} +``` + +### useTableContext() + +```ts +useTableContext: () => ReactTable; +``` + +Access the table instance from within an `AppTable` wrapper. +Use this in custom `tableComponents` passed to `createTableHook`. +TFeatures is already known from the createTableHook call. + +#### Type Parameters + +##### TData + +`TData` *extends* `RowData` = `RowData` + +#### Returns + +[`ReactTable`](../type-aliases/ReactTable.md)\<`TFeatures`, `TData`\> + +#### Example + +```tsx +function PaginationControls() { + const table = useTableContext() + return ( + s.pagination}> + {(pagination) => ( +
+ + Page {pagination.pageIndex + 1} + +
+ )} +
+ ) +} +``` + +## Example + +```tsx +// hooks/table.ts +export const { + useAppTable, + createAppColumnHelper, + useTableContext, + useCellContext, + useHeaderContext, +} = createTableHook({ + _features: tableFeatures({ + rowPaginationFeature, + rowSortingFeature, + columnFilteringFeature, + }), + _rowModels: { + paginatedRowModel: createPaginatedRowModel(), + sortedRowModel: createSortedRowModel(sortFns), + filteredRowModel: createFilteredRowModel(filterFns), + }, + tableComponents: { PaginationControls, RowCount }, + cellComponents: { TextCell, NumberCell }, + headerComponents: { SortIndicator, ColumnFilter }, +}) + +// Create column helper with TFeatures already bound +const columnHelper = createAppColumnHelper() + +// components/table-components.tsx +function PaginationControls() { + const table = useTableContext() // TFeatures already known! + return s.pagination}>... +} + +// features/users.tsx +function UsersTable({ data }: { data: Person[] }) { + const table = useAppTable({ + columns, + data, // TData inferred from Person[] + }) + + return ( + + + + {table.getHeaderGroups().map(headerGroup => ( + + {headerGroup.headers.map(h => ( + + {(header) => ( + + )} + + ))} + + ))} + + + {table.getRowModel().rows.map(row => ( + + {row.getAllCells().map(c => ( + + {(cell) => } + + ))} + + ))} + +
+ + +
+ +
+ ) +} +``` diff --git a/docs/framework/react/reference/index/functions/flexRender.md b/docs/framework/react/reference/index/functions/flexRender.md new file mode 100644 index 0000000000..c2e3d81d19 --- /dev/null +++ b/docs/framework/react/reference/index/functions/flexRender.md @@ -0,0 +1,40 @@ +--- +id: flexRender +title: flexRender +--- + +# Function: flexRender() + +```ts +function flexRender(Comp, props): ReactNode | Element; +``` + +Defined in: [FlexRender.tsx:45](https://github.com/TanStack/table/blob/main/packages/react-table/src/FlexRender.tsx#L45) + +If rendering headers, cells, or footers with custom markup, use flexRender instead of `cell.getValue()` or `cell.renderValue()`. + +## Type Parameters + +### TProps + +`TProps` *extends* `object` + +## Parameters + +### Comp + +[`Renderable`](../type-aliases/Renderable.md)\<`TProps`\> + +### props + +`TProps` + +## Returns + +`ReactNode` \| `Element` + +## Example + +```ts +flexRender(cell.column.columnDef.cell, cell.getContext()) +``` diff --git a/docs/framework/react/reference/index/functions/useTable.md b/docs/framework/react/reference/index/functions/useTable.md new file mode 100644 index 0000000000..e18c56384b --- /dev/null +++ b/docs/framework/react/reference/index/functions/useTable.md @@ -0,0 +1,41 @@ +--- +id: useTable +title: useTable +--- + +# Function: useTable() + +```ts +function useTable(tableOptions, selector): ReactTable; +``` + +Defined in: [useTable.ts:78](https://github.com/TanStack/table/blob/main/packages/react-table/src/useTable.ts#L78) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TSelected + +`TSelected` = \{ +\} + +## Parameters + +### tableOptions + +`TableOptions`\<`TFeatures`, `TData`\> + +### selector + +(`state`) => `TSelected` + +## Returns + +[`ReactTable`](../type-aliases/ReactTable.md)\<`TFeatures`, `TData`, `TSelected`\> diff --git a/docs/framework/react/reference/index/index.md b/docs/framework/react/reference/index/index.md new file mode 100644 index 0000000000..679304d2bc --- /dev/null +++ b/docs/framework/react/reference/index/index.md @@ -0,0 +1,38 @@ +--- +id: index +title: index +--- + +# index + +## Interfaces + +- [AppCellComponent](interfaces/AppCellComponent.md) +- [AppCellPropsWithoutSelector](interfaces/AppCellPropsWithoutSelector.md) +- [AppCellPropsWithSelector](interfaces/AppCellPropsWithSelector.md) +- [AppHeaderComponent](interfaces/AppHeaderComponent.md) +- [AppHeaderPropsWithoutSelector](interfaces/AppHeaderPropsWithoutSelector.md) +- [AppHeaderPropsWithSelector](interfaces/AppHeaderPropsWithSelector.md) +- [AppTableComponent](interfaces/AppTableComponent.md) +- [AppTablePropsWithoutSelector](interfaces/AppTablePropsWithoutSelector.md) +- [AppTablePropsWithSelector](interfaces/AppTablePropsWithSelector.md) + +## Type Aliases + +- [AppCellContext](type-aliases/AppCellContext.md) +- [AppColumnHelper](type-aliases/AppColumnHelper.md) +- [AppHeaderContext](type-aliases/AppHeaderContext.md) +- [AppReactTable](type-aliases/AppReactTable.md) +- [CreateTableHookOptions](type-aliases/CreateTableHookOptions.md) +- [FlexRenderProps](type-aliases/FlexRenderProps.md) +- [ReactTable](type-aliases/ReactTable.md) +- [Renderable](type-aliases/Renderable.md) +- [SubscribeProps](type-aliases/SubscribeProps.md) + +## Functions + +- [createTableHook](functions/createTableHook.md) +- [flexRender](functions/flexRender.md) +- [FlexRender](functions/FlexRender-1.md) +- [Subscribe](functions/Subscribe.md) +- [useTable](functions/useTable.md) diff --git a/docs/framework/react/reference/index/interfaces/AppCellComponent.md b/docs/framework/react/reference/index/interfaces/AppCellComponent.md new file mode 100644 index 0000000000..dba89e3e63 --- /dev/null +++ b/docs/framework/react/reference/index/interfaces/AppCellComponent.md @@ -0,0 +1,80 @@ +--- +id: AppCellComponent +title: AppCellComponent +--- + +# Interface: AppCellComponent()\ + +Defined in: [createTableHook.tsx:368](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L368) + +Component type for AppCell - wraps a cell and provides cell context with optional Subscribe + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TCellComponents + +`TCellComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +## Call Signature + +```ts +AppCellComponent(props): ReactNode; +``` + +Defined in: [createTableHook.tsx:373](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L373) + +Component type for AppCell - wraps a cell and provides cell context with optional Subscribe + +### Type Parameters + +#### TValue + +`TValue` *extends* `unknown` = `unknown` + +### Parameters + +#### props + +[`AppCellPropsWithoutSelector`](AppCellPropsWithoutSelector.md)\<`TFeatures`, `TData`, `TValue`, `TCellComponents`\> + +### Returns + +`ReactNode` + +## Call Signature + +```ts +AppCellComponent(props): ReactNode; +``` + +Defined in: [createTableHook.tsx:381](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L381) + +Component type for AppCell - wraps a cell and provides cell context with optional Subscribe + +### Type Parameters + +#### TValue + +`TValue` *extends* `unknown` = `unknown` + +#### TSelected + +`TSelected` = `unknown` + +### Parameters + +#### props + +[`AppCellPropsWithSelector`](AppCellPropsWithSelector.md)\<`TFeatures`, `TData`, `TValue`, `TCellComponents`, `TSelected`\> + +### Returns + +`ReactNode` diff --git a/docs/framework/react/reference/index/interfaces/AppCellPropsWithSelector.md b/docs/framework/react/reference/index/interfaces/AppCellPropsWithSelector.md new file mode 100644 index 0000000000..182e8b3cc5 --- /dev/null +++ b/docs/framework/react/reference/index/interfaces/AppCellPropsWithSelector.md @@ -0,0 +1,86 @@ +--- +id: AppCellPropsWithSelector +title: AppCellPropsWithSelector +--- + +# Interface: AppCellPropsWithSelector\ + +Defined in: [createTableHook.tsx:313](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L313) + +Props for AppCell component - with selector + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` + +### TCellComponents + +`TCellComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +### TSelected + +`TSelected` + +## Properties + +### cell + +```ts +cell: Cell; +``` + +Defined in: [createTableHook.tsx:320](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L320) + +*** + +### children() + +```ts +children: (cell, state) => ReactNode; +``` + +Defined in: [createTableHook.tsx:321](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L321) + +#### Parameters + +##### cell + +`Cell_Cell`\<`TFeatures`, `TData`, `TValue`\> & `UnionToIntersection`\<`"columnGroupingFeature"` *extends* keyof `TFeatures` ? `Cell_ColumnGrouping` : `never`\> & `UnionToIntersection`\<\{ \[K in string \| number \| symbol\]: TFeatures\[K\] extends TableFeature\ ? "Cell" extends keyof FeatureConstructorOptions ? FeatureConstructorOptions\[keyof FeatureConstructorOptions & "Cell"\] : never : any \}\[keyof `TFeatures`\]\> & `Cell_Plugins`\<`TFeatures`, `TData`, `TValue`\> & `TCellComponents` & `object` + +##### state + +`TSelected` + +#### Returns + +`ReactNode` + +*** + +### selector() + +```ts +selector: (state) => TSelected; +``` + +Defined in: [createTableHook.tsx:326](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L326) + +#### Parameters + +##### state + +`TableState`\<`TFeatures`\> + +#### Returns + +`TSelected` diff --git a/docs/framework/react/reference/index/interfaces/AppCellPropsWithoutSelector.md b/docs/framework/react/reference/index/interfaces/AppCellPropsWithoutSelector.md new file mode 100644 index 0000000000..31282d47c5 --- /dev/null +++ b/docs/framework/react/reference/index/interfaces/AppCellPropsWithoutSelector.md @@ -0,0 +1,68 @@ +--- +id: AppCellPropsWithoutSelector +title: AppCellPropsWithoutSelector +--- + +# Interface: AppCellPropsWithoutSelector\ + +Defined in: [createTableHook.tsx:296](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L296) + +Props for AppCell component - without selector + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` + +### TCellComponents + +`TCellComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +## Properties + +### cell + +```ts +cell: Cell; +``` + +Defined in: [createTableHook.tsx:302](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L302) + +*** + +### children() + +```ts +children: (cell) => ReactNode; +``` + +Defined in: [createTableHook.tsx:303](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L303) + +#### Parameters + +##### cell + +`Cell_Cell`\<`TFeatures`, `TData`, `TValue`\> & `UnionToIntersection`\<`"columnGroupingFeature"` *extends* keyof `TFeatures` ? `Cell_ColumnGrouping` : `never`\> & `UnionToIntersection`\<\{ \[K in string \| number \| symbol\]: TFeatures\[K\] extends TableFeature\ ? "Cell" extends keyof FeatureConstructorOptions ? FeatureConstructorOptions\[keyof FeatureConstructorOptions & "Cell"\] : never : any \}\[keyof `TFeatures`\]\> & `Cell_Plugins`\<`TFeatures`, `TData`, `TValue`\> & `TCellComponents` & `object` + +#### Returns + +`ReactNode` + +*** + +### selector? + +```ts +optional selector: undefined; +``` + +Defined in: [createTableHook.tsx:307](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L307) diff --git a/docs/framework/react/reference/index/interfaces/AppHeaderComponent.md b/docs/framework/react/reference/index/interfaces/AppHeaderComponent.md new file mode 100644 index 0000000000..c00749f75b --- /dev/null +++ b/docs/framework/react/reference/index/interfaces/AppHeaderComponent.md @@ -0,0 +1,80 @@ +--- +id: AppHeaderComponent +title: AppHeaderComponent +--- + +# Interface: AppHeaderComponent()\ + +Defined in: [createTableHook.tsx:395](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L395) + +Component type for AppHeader/AppFooter - wraps a header and provides header context with optional Subscribe + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### THeaderComponents + +`THeaderComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +## Call Signature + +```ts +AppHeaderComponent(props): ReactNode; +``` + +Defined in: [createTableHook.tsx:400](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L400) + +Component type for AppHeader/AppFooter - wraps a header and provides header context with optional Subscribe + +### Type Parameters + +#### TValue + +`TValue` *extends* `unknown` = `unknown` + +### Parameters + +#### props + +[`AppHeaderPropsWithoutSelector`](AppHeaderPropsWithoutSelector.md)\<`TFeatures`, `TData`, `TValue`, `THeaderComponents`\> + +### Returns + +`ReactNode` + +## Call Signature + +```ts +AppHeaderComponent(props): ReactNode; +``` + +Defined in: [createTableHook.tsx:408](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L408) + +Component type for AppHeader/AppFooter - wraps a header and provides header context with optional Subscribe + +### Type Parameters + +#### TValue + +`TValue` *extends* `unknown` = `unknown` + +#### TSelected + +`TSelected` = `unknown` + +### Parameters + +#### props + +[`AppHeaderPropsWithSelector`](AppHeaderPropsWithSelector.md)\<`TFeatures`, `TData`, `TValue`, `THeaderComponents`, `TSelected`\> + +### Returns + +`ReactNode` diff --git a/docs/framework/react/reference/index/interfaces/AppHeaderPropsWithSelector.md b/docs/framework/react/reference/index/interfaces/AppHeaderPropsWithSelector.md new file mode 100644 index 0000000000..a56d2653d0 --- /dev/null +++ b/docs/framework/react/reference/index/interfaces/AppHeaderPropsWithSelector.md @@ -0,0 +1,88 @@ +--- +id: AppHeaderPropsWithSelector +title: AppHeaderPropsWithSelector +--- + +# Interface: AppHeaderPropsWithSelector\ + +Defined in: [createTableHook.tsx:349](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L349) + +Props for AppHeader/AppFooter component - with selector + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` + +### THeaderComponents + +`THeaderComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +### TSelected + +`TSelected` + +## Properties + +### children() + +```ts +children: (header, state) => ReactNode; +``` + +Defined in: [createTableHook.tsx:357](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L357) + +#### Parameters + +##### header + +`Header_Core`\<`TFeatures`, `TData`, `TValue`\> & `UnionToIntersection`\< + \| `"columnSizingFeature"` *extends* keyof `TFeatures` ? `Header_ColumnSizing` : `never` + \| `"columnResizingFeature"` *extends* keyof `TFeatures` ? `Header_ColumnResizing` : `never`\> & `UnionToIntersection`\<\{ \[K in string \| number \| symbol\]: TFeatures\[K\] extends TableFeature\ ? "Header" extends keyof FeatureConstructorOptions ? FeatureConstructorOptions\[keyof FeatureConstructorOptions & "Header"\] : never : any \}\[keyof `TFeatures`\]\> & `Header_Plugins`\<`TFeatures`, `TData`, `TValue`\> & `THeaderComponents` & `object` + +##### state + +`TSelected` + +#### Returns + +`ReactNode` + +*** + +### header + +```ts +header: Header; +``` + +Defined in: [createTableHook.tsx:356](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L356) + +*** + +### selector() + +```ts +selector: (state) => TSelected; +``` + +Defined in: [createTableHook.tsx:362](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L362) + +#### Parameters + +##### state + +`TableState`\<`TFeatures`\> + +#### Returns + +`TSelected` diff --git a/docs/framework/react/reference/index/interfaces/AppHeaderPropsWithoutSelector.md b/docs/framework/react/reference/index/interfaces/AppHeaderPropsWithoutSelector.md new file mode 100644 index 0000000000..63a9566390 --- /dev/null +++ b/docs/framework/react/reference/index/interfaces/AppHeaderPropsWithoutSelector.md @@ -0,0 +1,70 @@ +--- +id: AppHeaderPropsWithoutSelector +title: AppHeaderPropsWithoutSelector +--- + +# Interface: AppHeaderPropsWithoutSelector\ + +Defined in: [createTableHook.tsx:332](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L332) + +Props for AppHeader/AppFooter component - without selector + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` + +### THeaderComponents + +`THeaderComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +## Properties + +### children() + +```ts +children: (header) => ReactNode; +``` + +Defined in: [createTableHook.tsx:339](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L339) + +#### Parameters + +##### header + +`Header_Core`\<`TFeatures`, `TData`, `TValue`\> & `UnionToIntersection`\< + \| `"columnSizingFeature"` *extends* keyof `TFeatures` ? `Header_ColumnSizing` : `never` + \| `"columnResizingFeature"` *extends* keyof `TFeatures` ? `Header_ColumnResizing` : `never`\> & `UnionToIntersection`\<\{ \[K in string \| number \| symbol\]: TFeatures\[K\] extends TableFeature\ ? "Header" extends keyof FeatureConstructorOptions ? FeatureConstructorOptions\[keyof FeatureConstructorOptions & "Header"\] : never : any \}\[keyof `TFeatures`\]\> & `Header_Plugins`\<`TFeatures`, `TData`, `TValue`\> & `THeaderComponents` & `object` + +#### Returns + +`ReactNode` + +*** + +### header + +```ts +header: Header; +``` + +Defined in: [createTableHook.tsx:338](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L338) + +*** + +### selector? + +```ts +optional selector: undefined; +``` + +Defined in: [createTableHook.tsx:343](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L343) diff --git a/docs/framework/react/reference/index/interfaces/AppTableComponent.md b/docs/framework/react/reference/index/interfaces/AppTableComponent.md new file mode 100644 index 0000000000..f23d4432ce --- /dev/null +++ b/docs/framework/react/reference/index/interfaces/AppTableComponent.md @@ -0,0 +1,62 @@ +--- +id: AppTableComponent +title: AppTableComponent +--- + +# Interface: AppTableComponent()\ + +Defined in: [createTableHook.tsx:422](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L422) + +Component type for AppTable - root wrapper with optional Subscribe + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +## Call Signature + +```ts +AppTableComponent(props): ReactNode; +``` + +Defined in: [createTableHook.tsx:423](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L423) + +Component type for AppTable - root wrapper with optional Subscribe + +### Parameters + +#### props + +[`AppTablePropsWithoutSelector`](AppTablePropsWithoutSelector.md) + +### Returns + +`ReactNode` + +## Call Signature + +```ts +AppTableComponent(props): ReactNode; +``` + +Defined in: [createTableHook.tsx:424](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L424) + +Component type for AppTable - root wrapper with optional Subscribe + +### Type Parameters + +#### TSelected + +`TSelected` + +### Parameters + +#### props + +[`AppTablePropsWithSelector`](AppTablePropsWithSelector.md)\<`TFeatures`, `TSelected`\> + +### Returns + +`ReactNode` diff --git a/docs/framework/react/reference/index/interfaces/AppTablePropsWithSelector.md b/docs/framework/react/reference/index/interfaces/AppTablePropsWithSelector.md new file mode 100644 index 0000000000..839cfd9710 --- /dev/null +++ b/docs/framework/react/reference/index/interfaces/AppTablePropsWithSelector.md @@ -0,0 +1,60 @@ +--- +id: AppTablePropsWithSelector +title: AppTablePropsWithSelector +--- + +# Interface: AppTablePropsWithSelector\ + +Defined in: [createTableHook.tsx:285](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L285) + +Props for AppTable component - with selector + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TSelected + +`TSelected` + +## Properties + +### children() + +```ts +children: (state) => ReactNode; +``` + +Defined in: [createTableHook.tsx:289](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L289) + +#### Parameters + +##### state + +`TSelected` + +#### Returns + +`ReactNode` + +*** + +### selector() + +```ts +selector: (state) => TSelected; +``` + +Defined in: [createTableHook.tsx:290](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L290) + +#### Parameters + +##### state + +`TableState`\<`TFeatures`\> + +#### Returns + +`TSelected` diff --git a/docs/framework/react/reference/index/interfaces/AppTablePropsWithoutSelector.md b/docs/framework/react/reference/index/interfaces/AppTablePropsWithoutSelector.md new file mode 100644 index 0000000000..76b4a54f99 --- /dev/null +++ b/docs/framework/react/reference/index/interfaces/AppTablePropsWithoutSelector.md @@ -0,0 +1,30 @@ +--- +id: AppTablePropsWithoutSelector +title: AppTablePropsWithoutSelector +--- + +# Interface: AppTablePropsWithoutSelector + +Defined in: [createTableHook.tsx:277](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L277) + +Props for AppTable component - without selector + +## Properties + +### children + +```ts +children: ReactNode; +``` + +Defined in: [createTableHook.tsx:278](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L278) + +*** + +### selector? + +```ts +optional selector: undefined; +``` + +Defined in: [createTableHook.tsx:279](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L279) diff --git a/docs/framework/react/reference/index/type-aliases/AppCellContext.md b/docs/framework/react/reference/index/type-aliases/AppCellContext.md new file mode 100644 index 0000000000..41efda8227 --- /dev/null +++ b/docs/framework/react/reference/index/type-aliases/AppCellContext.md @@ -0,0 +1,105 @@ +--- +id: AppCellContext +title: AppCellContext +--- + +# Type Alias: AppCellContext\ + +```ts +type AppCellContext = object; +``` + +Defined in: [createTableHook.tsx:41](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L41) + +Enhanced CellContext with pre-bound cell components. +The `cell` property includes the registered cellComponents. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` + +### TCellComponents + +`TCellComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +## Properties + +### cell + +```ts +cell: Cell & TCellComponents & object; +``` + +Defined in: [createTableHook.tsx:47](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L47) + +#### Type Declaration + +##### FlexRender() + +```ts +FlexRender: () => ReactNode; +``` + +###### Returns + +`ReactNode` + +*** + +### column + +```ts +column: Column; +``` + +Defined in: [createTableHook.tsx:49](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L49) + +*** + +### getValue + +```ts +getValue: CellContext["getValue"]; +``` + +Defined in: [createTableHook.tsx:50](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L50) + +*** + +### renderValue + +```ts +renderValue: CellContext["renderValue"]; +``` + +Defined in: [createTableHook.tsx:51](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L51) + +*** + +### row + +```ts +row: Row; +``` + +Defined in: [createTableHook.tsx:52](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L52) + +*** + +### table + +```ts +table: Table; +``` + +Defined in: [createTableHook.tsx:53](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L53) diff --git a/docs/framework/react/reference/index/type-aliases/AppColumnHelper.md b/docs/framework/react/reference/index/type-aliases/AppColumnHelper.md new file mode 100644 index 0000000000..c2e0e17422 --- /dev/null +++ b/docs/framework/react/reference/index/type-aliases/AppColumnHelper.md @@ -0,0 +1,144 @@ +--- +id: AppColumnHelper +title: AppColumnHelper +--- + +# Type Alias: AppColumnHelper\ + +```ts +type AppColumnHelper = object; +``` + +Defined in: [createTableHook.tsx:162](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L162) + +Enhanced column helper with pre-bound components in cell/header/footer contexts. +This enables TypeScript to know about the registered components when defining columns. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TCellComponents + +`TCellComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +### THeaderComponents + +`THeaderComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +## Properties + +### accessor() + +```ts +accessor: (accessor, column) => TAccessor extends AccessorFn ? AccessorFnColumnDef : AccessorKeyColumnDef; +``` + +Defined in: [createTableHook.tsx:172](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L172) + +Creates a data column definition with an accessor key or function. +The cell, header, and footer contexts include pre-bound components. + +#### Type Parameters + +##### TAccessor + +`TAccessor` *extends* `AccessorFn`\<`TData`\> \| `DeepKeys`\<`TData`\> + +##### TValue + +`TValue` *extends* `TAccessor` *extends* `AccessorFn`\<`TData`, infer TReturn\> ? `TReturn` : `TAccessor` *extends* `DeepKeys`\<`TData`\> ? `DeepValue`\<`TData`, `TAccessor`\> : `never` + +#### Parameters + +##### accessor + +`TAccessor` + +##### column + +`TAccessor` *extends* `AccessorFn`\<`TData`\> ? `AppColumnDefBase`\<`TFeatures`, `TData`, `TValue`, `TCellComponents`, `THeaderComponents`\> & `object` : `AppColumnDefBase`\<`TFeatures`, `TData`, `TValue`, `TCellComponents`, `THeaderComponents`\> + +#### Returns + +`TAccessor` *extends* `AccessorFn`\<`TData`\> ? `AccessorFnColumnDef`\<`TFeatures`, `TData`, `TValue`\> : `AccessorKeyColumnDef`\<`TFeatures`, `TData`, `TValue`\> + +*** + +### columns() + +```ts +columns: (columns) => ColumnDef[] & [...TColumns]; +``` + +Defined in: [createTableHook.tsx:203](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L203) + +Wraps an array of column definitions to preserve each column's individual TValue type. + +#### Type Parameters + +##### TColumns + +`TColumns` *extends* `ReadonlyArray`\<`ColumnDef`\<`TFeatures`, `TData`, `any`\>\> + +#### Parameters + +##### columns + +\[`...TColumns`\] + +#### Returns + +`ColumnDef`\<`TFeatures`, `TData`, `any`\>[] & \[`...TColumns`\] + +*** + +### display() + +```ts +display: (column) => DisplayColumnDef; +``` + +Defined in: [createTableHook.tsx:211](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L211) + +Creates a display column definition for non-data columns. +The cell, header, and footer contexts include pre-bound components. + +#### Parameters + +##### column + +`AppDisplayColumnDef`\<`TFeatures`, `TData`, `TCellComponents`, `THeaderComponents`\> + +#### Returns + +`DisplayColumnDef`\<`TFeatures`, `TData`, `unknown`\> + +*** + +### group() + +```ts +group: (column) => GroupColumnDef; +``` + +Defined in: [createTableHook.tsx:224](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L224) + +Creates a group column definition with nested child columns. +The cell, header, and footer contexts include pre-bound components. + +#### Parameters + +##### column + +`AppGroupColumnDef`\<`TFeatures`, `TData`, `TCellComponents`, `THeaderComponents`\> + +#### Returns + +`GroupColumnDef`\<`TFeatures`, `TData`, `unknown`\> diff --git a/docs/framework/react/reference/index/type-aliases/AppHeaderContext.md b/docs/framework/react/reference/index/type-aliases/AppHeaderContext.md new file mode 100644 index 0000000000..976c52cbeb --- /dev/null +++ b/docs/framework/react/reference/index/type-aliases/AppHeaderContext.md @@ -0,0 +1,75 @@ +--- +id: AppHeaderContext +title: AppHeaderContext +--- + +# Type Alias: AppHeaderContext\ + +```ts +type AppHeaderContext = object; +``` + +Defined in: [createTableHook.tsx:60](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L60) + +Enhanced HeaderContext with pre-bound header components. +The `header` property includes the registered headerComponents. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` + +### THeaderComponents + +`THeaderComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +## Properties + +### column + +```ts +column: Column; +``` + +Defined in: [createTableHook.tsx:66](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L66) + +*** + +### header + +```ts +header: Header & THeaderComponents & object; +``` + +Defined in: [createTableHook.tsx:67](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L67) + +#### Type Declaration + +##### FlexRender() + +```ts +FlexRender: () => ReactNode; +``` + +###### Returns + +`ReactNode` + +*** + +### table + +```ts +table: Table; +``` + +Defined in: [createTableHook.tsx:69](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L69) diff --git a/docs/framework/react/reference/index/type-aliases/AppReactTable.md b/docs/framework/react/reference/index/type-aliases/AppReactTable.md new file mode 100644 index 0000000000..670aff204b --- /dev/null +++ b/docs/framework/react/reference/index/type-aliases/AppReactTable.md @@ -0,0 +1,127 @@ +--- +id: AppReactTable +title: AppReactTable +--- + +# Type Alias: AppReactTable\ + +```ts +type AppReactTable = ReactTable & NoInfer & object; +``` + +Defined in: [createTableHook.tsx:430](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L430) + +Extended table API returned by useAppTable with all App wrapper components + +## Type Declaration + +### AppCell + +```ts +AppCell: AppCellComponent>; +``` + +Wraps a cell and provides cell context with pre-bound cellComponents. +Optionally accepts a selector for Subscribe functionality. + +#### Example + +```tsx +// Without selector + + {(c) =>
{filters.length}{sorting.length} sorted
...
+ + +// With selector - children receives selected state + s.pagination}> + {(pagination) =>
Page {pagination.pageIndex}
} +
+``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TSelected + +`TSelected` + +### TTableComponents + +`TTableComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +### TCellComponents + +`TCellComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +### THeaderComponents + +`THeaderComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> diff --git a/docs/framework/react/reference/index/type-aliases/CreateTableHookOptions.md b/docs/framework/react/reference/index/type-aliases/CreateTableHookOptions.md new file mode 100644 index 0000000000..a1ddac5529 --- /dev/null +++ b/docs/framework/react/reference/index/type-aliases/CreateTableHookOptions.md @@ -0,0 +1,83 @@ +--- +id: CreateTableHookOptions +title: CreateTableHookOptions +--- + +# Type Alias: CreateTableHookOptions\ + +```ts +type CreateTableHookOptions = Omit, "columns" | "data" | "store" | "state" | "initialState"> & object; +``` + +Defined in: [createTableHook.tsx:242](https://github.com/TanStack/table/blob/main/packages/react-table/src/createTableHook.tsx#L242) + +Options for creating a table hook with pre-bound components and default table options. +Extends all TableOptions except 'columns' | 'data' | 'store' | 'state' | 'initialState'. + +## Type Declaration + +### cellComponents? + +```ts +optional cellComponents: TCellComponents; +``` + +Cell-level components that need access to the cell instance. +These are available on the cell object passed to AppCell's children. +Use `useCellContext()` inside these components. + +#### Example + +```ts +{ TextCell, NumberCell, DateCell, CurrencyCell } +``` + +### headerComponents? + +```ts +optional headerComponents: THeaderComponents; +``` + +Header-level components that need access to the header instance. +These are available on the header object passed to AppHeader/AppFooter's children. +Use `useHeaderContext()` inside these components. + +#### Example + +```ts +{ SortIndicator, ColumnFilter, ResizeHandle } +``` + +### tableComponents? + +```ts +optional tableComponents: TTableComponents; +``` + +Table-level components that need access to the table instance. +These are available directly on the table object returned by useAppTable. +Use `useTableContext()` inside these components. + +#### Example + +```ts +{ PaginationControls, GlobalFilter, RowCount } +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TTableComponents + +`TTableComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +### TCellComponents + +`TCellComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> + +### THeaderComponents + +`THeaderComponents` *extends* `Record`\<`string`, `ComponentType`\<`any`\>\> diff --git a/docs/framework/react/reference/index/type-aliases/FlexRenderProps.md b/docs/framework/react/reference/index/type-aliases/FlexRenderProps.md new file mode 100644 index 0000000000..f4bdb1ca51 --- /dev/null +++ b/docs/framework/react/reference/index/type-aliases/FlexRenderProps.md @@ -0,0 +1,58 @@ +--- +id: FlexRenderProps +title: FlexRenderProps +--- + +# Type Alias: FlexRenderProps\ + +```ts +type FlexRenderProps = + | { + cell: Cell; + footer?: never; + header?: never; +} + | { + cell?: never; + footer?: never; + header: Header; +} + | { + cell?: never; + footer: Header; + header?: never; +}; +``` + +Defined in: [FlexRender.tsx:63](https://github.com/TanStack/table/blob/main/packages/react-table/src/FlexRender.tsx#L63) + +Simplified component wrapper of `flexRender`. Use this utility component to render headers, cells, or footers with custom markup. +Only one prop (`cell`, `header`, or `footer`) may be passed. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` *extends* `CellData` = `CellData` + +## Examples + +```ts + +``` + +```ts + +``` + +```ts + +``` diff --git a/docs/framework/react/reference/index/type-aliases/ReactTable.md b/docs/framework/react/reference/index/type-aliases/ReactTable.md new file mode 100644 index 0000000000..cd59b530ef --- /dev/null +++ b/docs/framework/react/reference/index/type-aliases/ReactTable.md @@ -0,0 +1,129 @@ +--- +id: ReactTable +title: ReactTable +--- + +# Type Alias: ReactTable\ + +```ts +type ReactTable = Table & object; +``` + +Defined in: [useTable.ts:23](https://github.com/TanStack/table/blob/main/packages/react-table/src/useTable.ts#L23) + +## Type Declaration + +### FlexRender() + +```ts +FlexRender: (props) => ReactNode; +``` + +A React component that renders headers, cells, or footers with custom markup. +Use this utility component instead of manually calling flexRender. + +#### Type Parameters + +##### TValue + +`TValue` *extends* `CellData` = `CellData` + +#### Parameters + +##### props + +[`FlexRenderProps`](FlexRenderProps.md)\<`TFeatures`, `TData`, `TValue`\> + +#### Returns + +`ReactNode` + +#### Example + +```tsx + + + +``` + +This replaces calling `flexRender` directly like this: +```tsx +flexRender(cell.column.columnDef.cell, cell.getContext()) +flexRender(header.column.columnDef.header, header.getContext()) +flexRender(footer.column.columnDef.footer, footer.getContext()) +``` + +### state + +```ts +readonly state: Readonly; +``` + +The selected state of the table. This state may not match the structure of `table.store.state` because it is selected by the `selector` function that you pass as the 2nd argument to `useTable`. + +#### Example + +```ts +const table = useTable(options, (state) => ({ globalFilter: state.globalFilter })) // only globalFilter is part of the selected state + +console.log(table.state.globalFilter) +``` + +### Subscribe() + +```ts +Subscribe: (props) => ReturnType; +``` + +A React HOC (Higher Order Component) that allows you to subscribe to the table state. + +This is useful for opting into state re-renders for specific parts of the table state. + +#### Type Parameters + +##### TSelected + +`TSelected` + +#### Parameters + +##### props + +###### children + +(`state`) => `ReactNode` \| `ReactNode` + +###### selector + +(`state`) => `TSelected` + +#### Returns + +`ReturnType`\<`FunctionComponent`\> + +#### Example + +```ts + ({ rowSelection: state.rowSelection })}> + {({ rowSelection }) => ( // important to include `{() => {()}}` syntax + + // render the row + + ))} + +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TSelected + +`TSelected` = \{ +\} diff --git a/docs/framework/react/reference/index/type-aliases/Renderable.md b/docs/framework/react/reference/index/type-aliases/Renderable.md new file mode 100644 index 0000000000..745a7f1b66 --- /dev/null +++ b/docs/framework/react/reference/index/type-aliases/Renderable.md @@ -0,0 +1,18 @@ +--- +id: Renderable +title: Renderable +--- + +# Type Alias: Renderable\ + +```ts +type Renderable = ReactNode | ComponentType; +``` + +Defined in: [FlexRender.tsx:11](https://github.com/TanStack/table/blob/main/packages/react-table/src/FlexRender.tsx#L11) + +## Type Parameters + +### TProps + +`TProps` diff --git a/docs/framework/react/reference/index/type-aliases/SubscribeProps.md b/docs/framework/react/reference/index/type-aliases/SubscribeProps.md new file mode 100644 index 0000000000..9c476278c9 --- /dev/null +++ b/docs/framework/react/reference/index/type-aliases/SubscribeProps.md @@ -0,0 +1,75 @@ +--- +id: SubscribeProps +title: SubscribeProps +--- + +# Type Alias: SubscribeProps\ + +```ts +type SubscribeProps = object; +``` + +Defined in: [Subscribe.ts:12](https://github.com/TanStack/table/blob/main/packages/react-table/src/Subscribe.ts#L12) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* `TableFeatures` + +### TData + +`TData` *extends* `RowData` + +### TSelected + +`TSelected` = \{ +\} + +## Properties + +### children + +```ts +children: (state) => ReactNode | ReactNode; +``` + +Defined in: [Subscribe.ts:30](https://github.com/TanStack/table/blob/main/packages/react-table/src/Subscribe.ts#L30) + +The children to render. Can be a function that receives the selected state, or a React node. + +*** + +### selector() + +```ts +selector: (state) => TSelected; +``` + +Defined in: [Subscribe.ts:26](https://github.com/TanStack/table/blob/main/packages/react-table/src/Subscribe.ts#L26) + +A selector function that selects the part of the table state to subscribe to. +This allows for fine-grained reactivity by only re-rendering when the selected state changes. + +#### Parameters + +##### state + +`NoInfer`\<`TableState`\<`TFeatures`\>\> + +#### Returns + +`TSelected` + +*** + +### table + +```ts +table: Table; +``` + +Defined in: [Subscribe.ts:21](https://github.com/TanStack/table/blob/main/packages/react-table/src/Subscribe.ts#L21) + +The table instance to subscribe to. Required when using as a standalone component. +Not needed when using as `table.Subscribe`. diff --git a/docs/framework/react/reference/legacy/functions/getCoreRowModel.md b/docs/framework/react/reference/legacy/functions/getCoreRowModel.md new file mode 100644 index 0000000000..ea52ec4ad1 --- /dev/null +++ b/docs/framework/react/reference/legacy/functions/getCoreRowModel.md @@ -0,0 +1,29 @@ +--- +id: getCoreRowModel +title: getCoreRowModel +--- + +# ~~Function: getCoreRowModel()~~ + +```ts +function getCoreRowModel(): RowModelFactory; +``` + +Defined in: [useLegacyTable.ts:147](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L147) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Returns + +`RowModelFactory`\<`TData`\> + +## Deprecated + +The core row model is always created automatically in v9. + +This is a stub function for v8 API compatibility with `useLegacyTable`. +It does nothing - the core row model is always available. diff --git a/docs/framework/react/reference/legacy/functions/getExpandedRowModel.md b/docs/framework/react/reference/legacy/functions/getExpandedRowModel.md new file mode 100644 index 0000000000..1f3761b69c --- /dev/null +++ b/docs/framework/react/reference/legacy/functions/getExpandedRowModel.md @@ -0,0 +1,29 @@ +--- +id: getExpandedRowModel +title: getExpandedRowModel +--- + +# ~~Function: getExpandedRowModel()~~ + +```ts +function getExpandedRowModel(): RowModelFactory; +``` + +Defined in: [useLegacyTable.ts:87](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L87) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Returns + +`RowModelFactory`\<`TData`\> + +## Deprecated + +Use `createExpandedRowModel()` with the new `useTable` hook instead. + +This is a stub function for v8 API compatibility with `useLegacyTable`. +It acts as a marker to enable the expanded row model. diff --git a/docs/framework/react/reference/legacy/functions/getFacetedMinMaxValues.md b/docs/framework/react/reference/legacy/functions/getFacetedMinMaxValues.md new file mode 100644 index 0000000000..9e96727929 --- /dev/null +++ b/docs/framework/react/reference/legacy/functions/getFacetedMinMaxValues.md @@ -0,0 +1,29 @@ +--- +id: getFacetedMinMaxValues +title: getFacetedMinMaxValues +--- + +# ~~Function: getFacetedMinMaxValues()~~ + +```ts +function getFacetedMinMaxValues(): FacetedMinMaxValuesFactory; +``` + +Defined in: [useLegacyTable.ts:123](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L123) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Returns + +`FacetedMinMaxValuesFactory`\<`TData`\> + +## Deprecated + +Use `createFacetedMinMaxValues()` with the new `useTable` hook instead. + +This is a stub function for v8 API compatibility with `useLegacyTable`. +It acts as a marker to enable the faceted min/max values. diff --git a/docs/framework/react/reference/legacy/functions/getFacetedRowModel.md b/docs/framework/react/reference/legacy/functions/getFacetedRowModel.md new file mode 100644 index 0000000000..3c79b345fa --- /dev/null +++ b/docs/framework/react/reference/legacy/functions/getFacetedRowModel.md @@ -0,0 +1,29 @@ +--- +id: getFacetedRowModel +title: getFacetedRowModel +--- + +# ~~Function: getFacetedRowModel()~~ + +```ts +function getFacetedRowModel(): FacetedRowModelFactory; +``` + +Defined in: [useLegacyTable.ts:111](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L111) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Returns + +`FacetedRowModelFactory`\<`TData`\> + +## Deprecated + +Use `createFacetedRowModel()` with the new `useTable` hook instead. + +This is a stub function for v8 API compatibility with `useLegacyTable`. +It acts as a marker to enable the faceted row model. diff --git a/docs/framework/react/reference/legacy/functions/getFacetedUniqueValues.md b/docs/framework/react/reference/legacy/functions/getFacetedUniqueValues.md new file mode 100644 index 0000000000..1f187eed74 --- /dev/null +++ b/docs/framework/react/reference/legacy/functions/getFacetedUniqueValues.md @@ -0,0 +1,29 @@ +--- +id: getFacetedUniqueValues +title: getFacetedUniqueValues +--- + +# ~~Function: getFacetedUniqueValues()~~ + +```ts +function getFacetedUniqueValues(): FacetedUniqueValuesFactory; +``` + +Defined in: [useLegacyTable.ts:135](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L135) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Returns + +`FacetedUniqueValuesFactory`\<`TData`\> + +## Deprecated + +Use `createFacetedUniqueValues()` with the new `useTable` hook instead. + +This is a stub function for v8 API compatibility with `useLegacyTable`. +It acts as a marker to enable the faceted unique values. diff --git a/docs/framework/react/reference/legacy/functions/getFilteredRowModel.md b/docs/framework/react/reference/legacy/functions/getFilteredRowModel.md new file mode 100644 index 0000000000..5da0133d43 --- /dev/null +++ b/docs/framework/react/reference/legacy/functions/getFilteredRowModel.md @@ -0,0 +1,29 @@ +--- +id: getFilteredRowModel +title: getFilteredRowModel +--- + +# ~~Function: getFilteredRowModel()~~ + +```ts +function getFilteredRowModel(): RowModelFactory; +``` + +Defined in: [useLegacyTable.ts:51](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L51) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Returns + +`RowModelFactory`\<`TData`\> + +## Deprecated + +Use `createFilteredRowModel(filterFns)` with the new `useTable` hook instead. + +This is a stub function for v8 API compatibility with `useLegacyTable`. +It acts as a marker to enable the filtered row model. diff --git a/docs/framework/react/reference/legacy/functions/getGroupedRowModel.md b/docs/framework/react/reference/legacy/functions/getGroupedRowModel.md new file mode 100644 index 0000000000..49caf695bd --- /dev/null +++ b/docs/framework/react/reference/legacy/functions/getGroupedRowModel.md @@ -0,0 +1,29 @@ +--- +id: getGroupedRowModel +title: getGroupedRowModel +--- + +# ~~Function: getGroupedRowModel()~~ + +```ts +function getGroupedRowModel(): RowModelFactory; +``` + +Defined in: [useLegacyTable.ts:99](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L99) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Returns + +`RowModelFactory`\<`TData`\> + +## Deprecated + +Use `createGroupedRowModel(aggregationFns)` with the new `useTable` hook instead. + +This is a stub function for v8 API compatibility with `useLegacyTable`. +It acts as a marker to enable the grouped row model. diff --git a/docs/framework/react/reference/legacy/functions/getPaginationRowModel.md b/docs/framework/react/reference/legacy/functions/getPaginationRowModel.md new file mode 100644 index 0000000000..b81291156d --- /dev/null +++ b/docs/framework/react/reference/legacy/functions/getPaginationRowModel.md @@ -0,0 +1,29 @@ +--- +id: getPaginationRowModel +title: getPaginationRowModel +--- + +# ~~Function: getPaginationRowModel()~~ + +```ts +function getPaginationRowModel(): RowModelFactory; +``` + +Defined in: [useLegacyTable.ts:75](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L75) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Returns + +`RowModelFactory`\<`TData`\> + +## Deprecated + +Use `createPaginatedRowModel()` with the new `useTable` hook instead. + +This is a stub function for v8 API compatibility with `useLegacyTable`. +It acts as a marker to enable the paginated row model. diff --git a/docs/framework/react/reference/legacy/functions/getSortedRowModel.md b/docs/framework/react/reference/legacy/functions/getSortedRowModel.md new file mode 100644 index 0000000000..e57413fe53 --- /dev/null +++ b/docs/framework/react/reference/legacy/functions/getSortedRowModel.md @@ -0,0 +1,29 @@ +--- +id: getSortedRowModel +title: getSortedRowModel +--- + +# ~~Function: getSortedRowModel()~~ + +```ts +function getSortedRowModel(): RowModelFactory; +``` + +Defined in: [useLegacyTable.ts:63](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L63) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Returns + +`RowModelFactory`\<`TData`\> + +## Deprecated + +Use `createSortedRowModel(sortFns)` with the new `useTable` hook instead. + +This is a stub function for v8 API compatibility with `useLegacyTable`. +It acts as a marker to enable the sorted row model. diff --git a/docs/framework/react/reference/legacy/functions/legacyCreateColumnHelper.md b/docs/framework/react/reference/legacy/functions/legacyCreateColumnHelper.md new file mode 100644 index 0000000000..e6e59f0f74 --- /dev/null +++ b/docs/framework/react/reference/legacy/functions/legacyCreateColumnHelper.md @@ -0,0 +1,29 @@ +--- +id: legacyCreateColumnHelper +title: legacyCreateColumnHelper +--- + +# ~~Function: legacyCreateColumnHelper()~~ + +```ts +function legacyCreateColumnHelper(): ColumnHelper; +``` + +Defined in: [useLegacyTable.ts:321](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L321) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Returns + +`ColumnHelper`\<`StockFeatures`, `TData`\> + +## Deprecated + +Use `createColumnHelper()` with useTable instead. + +A column helper with StockFeatures pre-bound for use with useLegacyTable. +Only requires TData—no need to specify TFeatures. diff --git a/docs/framework/react/reference/legacy/functions/useLegacyTable.md b/docs/framework/react/reference/legacy/functions/useLegacyTable.md new file mode 100644 index 0000000000..d78c897c86 --- /dev/null +++ b/docs/framework/react/reference/legacy/functions/useLegacyTable.md @@ -0,0 +1,64 @@ +--- +id: useLegacyTable +title: useLegacyTable +--- + +# ~~Function: useLegacyTable()~~ + +```ts +function useLegacyTable(options): LegacyReactTable; +``` + +Defined in: [useLegacyTable.ts:363](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L363) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Parameters + +### options + +[`LegacyTableOptions`](../type-aliases/LegacyTableOptions.md)\<`TData`\> + +Legacy v8-style table options + +## Returns + +[`LegacyReactTable`](../type-aliases/LegacyReactTable.md)\<`TData`\> + +A table instance with the full state subscribed and a `getState()` method + +## Deprecated + +This hook is provided as a compatibility layer for migrating from TanStack Table v8. + +Use the new `useTable` hook instead with explicit `_features` and `_rowModels`: + +```tsx +// New v9 API +const _features = tableFeatures({ + columnFilteringFeature, + rowSortingFeature, + rowPaginationFeature, +}) + +const table = useTable({ + _features, + _rowModels: { + filteredRowModel: createFilteredRowModel(filterFns), + sortedRowModel: createSortedRowModel(sortFns), + paginatedRowModel: createPaginatedRowModel(), + }, + columns, + data, +}) +``` + +Key differences from v8: +- Features are tree-shakeable - only import what you use +- Row models are explicitly passed via `_rowModels` +- Use `table.Subscribe` for fine-grained re-renders +- State is accessed via `table.state` after selecting with the 2nd argument diff --git a/docs/framework/react/reference/legacy/index.md b/docs/framework/react/reference/legacy/index.md new file mode 100644 index 0000000000..c9cbb07be9 --- /dev/null +++ b/docs/framework/react/reference/legacy/index.md @@ -0,0 +1,36 @@ +--- +id: legacy +title: legacy +--- + +# legacy + +## Interfaces + +- [LegacyRowModelOptions](interfaces/LegacyRowModelOptions.md) + +## Type Aliases + +- [~~LegacyCell~~](type-aliases/LegacyCell.md) +- [~~LegacyColumn~~](type-aliases/LegacyColumn.md) +- [~~LegacyColumnDef~~](type-aliases/LegacyColumnDef.md) +- [~~LegacyHeader~~](type-aliases/LegacyHeader.md) +- [~~LegacyHeaderGroup~~](type-aliases/LegacyHeaderGroup.md) +- [~~LegacyReactTable~~](type-aliases/LegacyReactTable.md) +- [~~LegacyRow~~](type-aliases/LegacyRow.md) +- [~~LegacyTable~~](type-aliases/LegacyTable.md) +- [~~LegacyTableOptions~~](type-aliases/LegacyTableOptions.md) + +## Functions + +- [~~getCoreRowModel~~](functions/getCoreRowModel.md) +- [~~getExpandedRowModel~~](functions/getExpandedRowModel.md) +- [~~getFacetedMinMaxValues~~](functions/getFacetedMinMaxValues.md) +- [~~getFacetedRowModel~~](functions/getFacetedRowModel.md) +- [~~getFacetedUniqueValues~~](functions/getFacetedUniqueValues.md) +- [~~getFilteredRowModel~~](functions/getFilteredRowModel.md) +- [~~getGroupedRowModel~~](functions/getGroupedRowModel.md) +- [~~getPaginationRowModel~~](functions/getPaginationRowModel.md) +- [~~getSortedRowModel~~](functions/getSortedRowModel.md) +- [~~legacyCreateColumnHelper~~](functions/legacyCreateColumnHelper.md) +- [~~useLegacyTable~~](functions/useLegacyTable.md) diff --git a/docs/framework/react/reference/legacy/interfaces/LegacyRowModelOptions.md b/docs/framework/react/reference/legacy/interfaces/LegacyRowModelOptions.md new file mode 100644 index 0000000000..10be482269 --- /dev/null +++ b/docs/framework/react/reference/legacy/interfaces/LegacyRowModelOptions.md @@ -0,0 +1,160 @@ +--- +id: LegacyRowModelOptions +title: LegacyRowModelOptions +--- + +# Interface: LegacyRowModelOptions\ + +Defined in: [useLegacyTable.ts:191](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L191) + +Legacy v8-style row model options + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Properties + +### ~~getCoreRowModel?~~ + +```ts +optional getCoreRowModel: RowModelFactory; +``` + +Defined in: [useLegacyTable.ts:196](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L196) + +Returns the core row model for the table. + +#### Deprecated + +This option is no longer needed in v9. The core row model is always created automatically. + +*** + +### ~~getExpandedRowModel?~~ + +```ts +optional getExpandedRowModel: RowModelFactory; +``` + +Defined in: [useLegacyTable.ts:216](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L216) + +Returns the expanded row model for the table. + +#### Deprecated + +Use `_rowModels.expandedRowModel` with `createExpandedRowModel()` instead. + +*** + +### ~~getFacetedMinMaxValues?~~ + +```ts +optional getFacetedMinMaxValues: FacetedMinMaxValuesFactory; +``` + +Defined in: [useLegacyTable.ts:231](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L231) + +Returns the faceted min/max values for a column. + +#### Deprecated + +Use `_rowModels.facetedMinMaxValues` with `createFacetedMinMaxValues()` instead. + +*** + +### ~~getFacetedRowModel?~~ + +```ts +optional getFacetedRowModel: FacetedRowModelFactory; +``` + +Defined in: [useLegacyTable.ts:226](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L226) + +Returns the faceted row model for a column. + +#### Deprecated + +Use `_rowModels.facetedRowModel` with `createFacetedRowModel()` instead. + +*** + +### ~~getFacetedUniqueValues?~~ + +```ts +optional getFacetedUniqueValues: FacetedUniqueValuesFactory; +``` + +Defined in: [useLegacyTable.ts:236](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L236) + +Returns the faceted unique values for a column. + +#### Deprecated + +Use `_rowModels.facetedUniqueValues` with `createFacetedUniqueValues()` instead. + +*** + +### ~~getFilteredRowModel?~~ + +```ts +optional getFilteredRowModel: RowModelFactory; +``` + +Defined in: [useLegacyTable.ts:201](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L201) + +Returns the filtered row model for the table. + +#### Deprecated + +Use `_rowModels.filteredRowModel` with `createFilteredRowModel(filterFns)` instead. + +*** + +### ~~getGroupedRowModel?~~ + +```ts +optional getGroupedRowModel: RowModelFactory; +``` + +Defined in: [useLegacyTable.ts:221](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L221) + +Returns the grouped row model for the table. + +#### Deprecated + +Use `_rowModels.groupedRowModel` with `createGroupedRowModel(aggregationFns)` instead. + +*** + +### ~~getPaginationRowModel?~~ + +```ts +optional getPaginationRowModel: RowModelFactory; +``` + +Defined in: [useLegacyTable.ts:211](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L211) + +Returns the paginated row model for the table. + +#### Deprecated + +Use `_rowModels.paginatedRowModel` with `createPaginatedRowModel()` instead. + +*** + +### ~~getSortedRowModel?~~ + +```ts +optional getSortedRowModel: RowModelFactory; +``` + +Defined in: [useLegacyTable.ts:206](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L206) + +Returns the sorted row model for the table. + +#### Deprecated + +Use `_rowModels.sortedRowModel` with `createSortedRowModel(sortFns)` instead. diff --git a/docs/framework/react/reference/legacy/type-aliases/LegacyCell.md b/docs/framework/react/reference/legacy/type-aliases/LegacyCell.md new file mode 100644 index 0000000000..7c9ea96eeb --- /dev/null +++ b/docs/framework/react/reference/legacy/type-aliases/LegacyCell.md @@ -0,0 +1,26 @@ +--- +id: LegacyCell +title: LegacyCell +--- + +# ~~Type Alias: LegacyCell\~~ + +```ts +type LegacyCell = Cell; +``` + +Defined in: [useLegacyTable.ts:285](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L285) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` = `unknown` + +## Deprecated + +Use Cell with useTable instead. diff --git a/docs/framework/react/reference/legacy/type-aliases/LegacyColumn.md b/docs/framework/react/reference/legacy/type-aliases/LegacyColumn.md new file mode 100644 index 0000000000..ee2ae227d5 --- /dev/null +++ b/docs/framework/react/reference/legacy/type-aliases/LegacyColumn.md @@ -0,0 +1,26 @@ +--- +id: LegacyColumn +title: LegacyColumn +--- + +# ~~Type Alias: LegacyColumn\~~ + +```ts +type LegacyColumn = Column; +``` + +Defined in: [useLegacyTable.ts:275](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L275) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` = `unknown` + +## Deprecated + +Use Column with useTable instead. diff --git a/docs/framework/react/reference/legacy/type-aliases/LegacyColumnDef.md b/docs/framework/react/reference/legacy/type-aliases/LegacyColumnDef.md new file mode 100644 index 0000000000..8fc73806cc --- /dev/null +++ b/docs/framework/react/reference/legacy/type-aliases/LegacyColumnDef.md @@ -0,0 +1,26 @@ +--- +id: LegacyColumnDef +title: LegacyColumnDef +--- + +# ~~Type Alias: LegacyColumnDef\~~ + +```ts +type LegacyColumnDef = ColumnDef; +``` + +Defined in: [useLegacyTable.ts:305](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L305) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` = `unknown` + +## Deprecated + +Use ColumnDef with useTable instead. diff --git a/docs/framework/react/reference/legacy/type-aliases/LegacyHeader.md b/docs/framework/react/reference/legacy/type-aliases/LegacyHeader.md new file mode 100644 index 0000000000..f67e32690b --- /dev/null +++ b/docs/framework/react/reference/legacy/type-aliases/LegacyHeader.md @@ -0,0 +1,26 @@ +--- +id: LegacyHeader +title: LegacyHeader +--- + +# ~~Type Alias: LegacyHeader\~~ + +```ts +type LegacyHeader = Header; +``` + +Defined in: [useLegacyTable.ts:292](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L292) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +### TValue + +`TValue` = `unknown` + +## Deprecated + +Use Header with useTable instead. diff --git a/docs/framework/react/reference/legacy/type-aliases/LegacyHeaderGroup.md b/docs/framework/react/reference/legacy/type-aliases/LegacyHeaderGroup.md new file mode 100644 index 0000000000..85d9def0b6 --- /dev/null +++ b/docs/framework/react/reference/legacy/type-aliases/LegacyHeaderGroup.md @@ -0,0 +1,22 @@ +--- +id: LegacyHeaderGroup +title: LegacyHeaderGroup +--- + +# ~~Type Alias: LegacyHeaderGroup\~~ + +```ts +type LegacyHeaderGroup = HeaderGroup; +``` + +Defined in: [useLegacyTable.ts:299](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L299) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Deprecated + +Use HeaderGroup with useTable instead. diff --git a/docs/framework/react/reference/legacy/type-aliases/LegacyReactTable.md b/docs/framework/react/reference/legacy/type-aliases/LegacyReactTable.md new file mode 100644 index 0000000000..e17a04b06e --- /dev/null +++ b/docs/framework/react/reference/legacy/type-aliases/LegacyReactTable.md @@ -0,0 +1,42 @@ +--- +id: LegacyReactTable +title: LegacyReactTable +--- + +# ~~Type Alias: LegacyReactTable\~~ + +```ts +type LegacyReactTable = ReactTable> & object; +``` + +Defined in: [useLegacyTable.ts:258](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L258) + +Legacy table instance type that includes the v8-style `getState()` method. + +## Type Declaration + +### ~~getState()~~ + +```ts +getState: () => TableState; +``` + +Returns the current table state. + +#### Returns + +`TableState`\<`StockFeatures`\> + +#### Deprecated + +In v9, access state directly via `table.state` or use `table.store.state` for the full state. + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Deprecated + +Use `useTable` with explicit state selection instead. diff --git a/docs/framework/react/reference/legacy/type-aliases/LegacyRow.md b/docs/framework/react/reference/legacy/type-aliases/LegacyRow.md new file mode 100644 index 0000000000..c1f7ba39f2 --- /dev/null +++ b/docs/framework/react/reference/legacy/type-aliases/LegacyRow.md @@ -0,0 +1,22 @@ +--- +id: LegacyRow +title: LegacyRow +--- + +# ~~Type Alias: LegacyRow\~~ + +```ts +type LegacyRow = Row; +``` + +Defined in: [useLegacyTable.ts:282](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L282) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Deprecated + +Use Row with useTable instead. diff --git a/docs/framework/react/reference/legacy/type-aliases/LegacyTable.md b/docs/framework/react/reference/legacy/type-aliases/LegacyTable.md new file mode 100644 index 0000000000..523d8e76cf --- /dev/null +++ b/docs/framework/react/reference/legacy/type-aliases/LegacyTable.md @@ -0,0 +1,22 @@ +--- +id: LegacyTable +title: LegacyTable +--- + +# ~~Type Alias: LegacyTable\~~ + +```ts +type LegacyTable = Table; +``` + +Defined in: [useLegacyTable.ts:309](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L309) + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Deprecated + +Use Table with useTable instead. diff --git a/docs/framework/react/reference/legacy/type-aliases/LegacyTableOptions.md b/docs/framework/react/reference/legacy/type-aliases/LegacyTableOptions.md new file mode 100644 index 0000000000..c520c5f649 --- /dev/null +++ b/docs/framework/react/reference/legacy/type-aliases/LegacyTableOptions.md @@ -0,0 +1,27 @@ +--- +id: LegacyTableOptions +title: LegacyTableOptions +--- + +# ~~Type Alias: LegacyTableOptions\~~ + +```ts +type LegacyTableOptions = Omit, "_features" | "_rowModels"> & LegacyRowModelOptions; +``` + +Defined in: [useLegacyTable.ts:247](https://github.com/TanStack/table/blob/main/packages/react-table/src/useLegacyTable.ts#L247) + +Legacy v8-style table options that work with useLegacyTable. + +This type omits `_features` and `_rowModels` and instead accepts the v8-style +`get*RowModel` function options. + +## Type Parameters + +### TData + +`TData` *extends* `RowData` + +## Deprecated + +This is a compatibility layer for migrating from v8. Use `useTable` with explicit `_features` and `_rowModels` instead. diff --git a/docs/framework/solid/guide/table-state.md b/docs/framework/solid/guide/table-state.md new file mode 100644 index 0000000000..83a77d7f2f --- /dev/null +++ b/docs/framework/solid/guide/table-state.md @@ -0,0 +1,221 @@ +--- +title: Table State (Solid) Guide +--- + +## Table State (Solid) Guide + +TanStack Table has a simple underlying internal state management system to store and manage the state of the table. It also lets you selectively pull out any state that you need to manage in your own state management. This guide will walk you through the different ways in which you can interact with and manage the state of the table. + +### Accessing Table State + +You do not need to set up anything special in order for the table state to work. If you pass nothing into either `state`, `initialState`, or any of the `on[State]Change` table options, the table will manage its own state internally. You can access any part of this internal state by using the `table.store.state` table instance API. + +```jsx +const table = createTable({ + columns, + get data() { + return data() + }, + //... +}) + +console.log(table.store.state) //access the entire internal state +console.log(table.store.state.rowSelection) //access just the row selection state +``` + +### Custom Initial State + +If all you need to do for certain states is customize their initial default values, you still do not need to manage any of the state yourself. You can simply set values in the `initialState` option of the table instance. + +```jsx +const table = createTable({ + columns, + data, + initialState: { + columnOrder: ['age', 'firstName', 'lastName'], //customize the initial column order + columnVisibility: { + id: false //hide the id column by default + }, + expanded: true, //expand all rows by default + sorting: [ + { + id: 'age', + desc: true //sort by age in descending order by default + } + ] + }, + //... +}) +``` + +> **Note**: Only specify each particular state in either `initialState` or `state`, but not both. If you pass in a particular state value to both `initialState` and `state`, the initialized state in `state` will take overwrite any corresponding value in `initialState`. + +### Controlled State + +If you need easy access to the table state in other areas of your application, TanStack Table makes it easy to control and manage any or all of the table state in your own state management system. You can do this by passing in your own state and state management functions to the `state` and `on[State]Change` table options. + +#### Individual Controlled State + +You can control just the state that you need easy access to. You do NOT have to control all of the table state if you do not need to. It is recommended to only control the state that you need on a case-by-case basis. + +In order to control a particular state, you need to both pass in the corresponding `state` value and the `on[State]Change` function to the table instance. + +Let's take filtering, sorting, and pagination as an example in a "manual" server-side data fetching scenario. You can store the filtering, sorting, and pagination state in your own state management, but leave out any other state like column order, column visibility, etc. if your API does not care about those values. + +```jsx +const [columnFilters, setColumnFilters] = createSignal([]) //no default filters +const [sorting, setSorting] = createSignal([{ + id: 'age', + desc: true, //sort by age in descending order by default +}]) +const [pagination, setPagination] = createSignal({ pageIndex: 0, pageSize: 15 }) + +//Use our controlled state values to fetch data +const tableQuery = createQuery({ + queryKey: ['users', columnFilters, sorting, pagination], + queryFn: () => fetchUsers(columnFilters, sorting, pagination), + //... +}) + +const table = createTable({ + columns, + get data() { + return tableQuery.data() + }, + //... + state: { + get columnFilters() { + return columnFilters() //pass controlled state back to the table (overrides internal state) + }, + get sorting() { + return sorting() + }, + get pagination() { + return pagination() + }, + }, + onColumnFiltersChange: setColumnFilters, //hoist columnFilters state into our own state management + onSortingChange: setSorting, + onPaginationChange: setPagination, +}) +//... +``` + +#### Fully Controlled State + +Alternatively, you can control the entire table state with the `onStateChange` table option. It will hoist out the entire table state into your own state management system. Be careful with this approach, as you might find that raising some frequently changing state values up a solid tree, like `columnSizingInfo` state`, might cause bad performance issues. + +A couple of more tricks may be needed to make this work. If you use the `onStateChange` table option, the initial values of the `state` must be populated with all of the relevant state values for all of the features that you want to use. You can either manually type out all of the initial state values, or use the `table.setOptions` API in a special way as shown below. + +```jsx +//create a table instance with default state values +const table = createTable({ + columns, + get data() { + return data() + }, + //... Note: `state` values are NOT passed in yet +}) + + +const [state, setState] = createSignal({ + ...table.initialState, //populate the initial state with all of the default state values from the table instance + pagination: { + pageIndex: 0, + pageSize: 15 //optionally customize the initial pagination state. + } +}) + +//Use the table.setOptions API to merge our fully controlled state onto the table instance +table.setOptions(prev => ({ + ...prev, //preserve any other options that we have set up above + get state() { + return state() //our fully controlled state overrides the internal state + }, + onStateChange: setState //any state changes will be pushed up to our own state management +})) +``` + +### On State Change Callbacks + +So far, we have seen the `on[State]Change` and `onStateChange` table options work to "hoist" the table state changes into our own state management. However, there are a few things about these using these options that you should be aware of. + +#### 1. **State Change Callbacks MUST have their corresponding state value in the `state` option**. + +Specifying an `on[State]Change` callback tells the table instance that this will be a controlled state. If you do not specify the corresponding `state` value, that state will be "frozen" with its initial value. + +```jsx +const [sorting, setSorting] = createSignal([]) +//... +const table = createTable({ + columns, + data, + //... + state: { + get sorting() { + return sorting() //required because we are using `onSortingChange` + }, + }, + onSortingChange: setSorting, //makes the `state.sorting` controlled +}) +``` + +#### 2. **Updaters can either be raw values or callback functions**. + +The `on[State]Change` and `onStateChange` callbacks work exactly like the `setState` functions in React (Solid Setters). The updater values can either be a new state value or a callback function that takes the previous state value and returns the new state value. + +What implications does this have? It means that if you want to add in some extra logic in any of the `on[State]Change` callbacks, you can do so, but you need to check whether or not the new incoming updater value is a function or value. + +```jsx +const [sorting, setSorting] = createSignal([]) +const [pagination, setPagination] = createSignal({ pageIndex: 0, pageSize: 10 }) + +const table = createTable({ + get columns() { + return columns() + }, + get data() { + return data() + }, + //... + state: { + get pagination() { + return pagination() + }, + get sorting() { + return sorting() + }, + } + //syntax 1 + onPaginationChange: (updater) => { + setPagination(old => { + const newPaginationValue = updater instanceof Function ? updater(old) : updater + //do something with the new pagination value + //... + return newPaginationValue + }) + }, + //syntax 2 + onSortingChange: (updater) => { + const newSortingValue = updater instanceof Function ? updater(sorting) : updater + //do something with the new sorting value + //... + setSorting(updater) //normal state update + } +}) +``` + +### State Types + +All complex states in TanStack Table have their own TypeScript types that you can import and use. This can be handy for ensuring that you are using the correct data structures and properties for the state values that you are controlling. + +```tsx +import { createTable, type SortingState } from '@tanstack/solid-table' +//... +const [sorting, setSorting] = createSignal([ + { + id: 'age', //you should get autocomplete for the `id` and `desc` properties + desc: true, + } +]) +``` \ No newline at end of file diff --git a/docs/framework/solid/solid-table.md b/docs/framework/solid/solid-table.md new file mode 100644 index 0000000000..9afcd01f6a --- /dev/null +++ b/docs/framework/solid/solid-table.md @@ -0,0 +1,19 @@ +--- +title: Solid Table +--- + +The `@tanstack/solid-table` adapter is a wrapper around the core table logic. Most of it's job is related to managing state the "solid" way, providing types and the rendering implementation of cell/header/footer templates. + +## `createTable` + +Takes an `options` object and returns a table. + +```tsx +import { createTable } from '@tanstack/solid-table' + +function App() { + const table = createTable(options) + + // ...render your table +} +``` diff --git a/docs/framework/svelte/guide/table-state.md b/docs/framework/svelte/guide/table-state.md new file mode 100644 index 0000000000..a45cc3f675 --- /dev/null +++ b/docs/framework/svelte/guide/table-state.md @@ -0,0 +1,217 @@ +--- +title: Table State (Svelte) Guide +--- + +## Table State (Svelte) Guide + +TanStack Table has a simple underlying internal state management system to store and manage the state of the table. It also lets you selectively pull out any state that you need to manage in your own state management. This guide will walk you through the different ways in which you can interact with and manage the state of the table. + +### Accessing Table State + +You do not need to set up anything special in order for the table state to work. If you pass nothing into either `state`, `initialState`, or any of the `on[State]Change` table options, the table will manage its own state internally. You can access any part of this internal state by using the `table.store.state` table instance API. + +```ts +const table = createTable({ + columns, + get data() { + return data + }, + //... +}) + +console.log(table.store.state) //access the entire internal state +console.log(table.store.state.rowSelection) //access just the row selection state +``` + +### Custom Initial State + +If all you need to do for certain states is customize their initial default values, you still do not need to manage any of the state yourself. You can simply set values in the `initialState` option of the table instance. + +```ts +const table = createTable({ + columns, + data, + initialState: { + columnOrder: ['age', 'firstName', 'lastName'], //customize the initial column order + columnVisibility: { + id: false //hide the id column by default + }, + expanded: true, //expand all rows by default + sorting: [ + { + id: 'age', + desc: true //sort by age in descending order by default + } + ] + }, + //... +}) +``` + +> **Note**: Only specify each particular state in either `initialState` or `state`, but not both. If you pass in a particular state value to both `initialState` and `state`, the initialized state in `state` will overwrite any corresponding value in `initialState`. + +### Controlled State + +If you need easy access to the table state in other areas of your application, TanStack Table makes it easy to control and manage any or all of the table state in your own state management system. You can do this by passing in your own state and state management functions to the `state` and `on[State]Change` table options. + +#### Individual Controlled State + +You can control just the state that you need easy access to. You do NOT have to control all of the table state if you do not need to. It is recommended to only control the state that you need on a case-by-case basis. + +In order to control a particular state, you need to both pass in the corresponding `state` value and the `on[State]Change` function to the table instance. + +Let's take filtering, sorting, and pagination as an example in a "manual" server-side data fetching scenario. You can store the filtering, sorting, and pagination state in your own state management, but leave out any other state like column order, column visibility, etc. if your API does not care about those values. + +```ts +let sorting: SortingState = $state([ + { + id: 'age', + desc: true, //sort by age in descending order by default + }, +]) +function setSorting(updater: Updater) { + if (updater instanceof Function) { + sorting = updater(sorting) + } else sorting = updater +} + +let columnFilters: ColumnFiltersState = $state([]) //no default filters +function setColumnFilters(updater: Updater) { + if (updater instanceof Function) { + columnFilters = updater(columnFilters) + } else columnFilters = updater +} + +let pagination: PaginationState = $state( + { pageIndex: 0, pageSize: 15 } //default pagination +) +function setPagination(updater: Updater) { + if (updater instanceof Function) { + pagination = updater(pagination) + } else pagination = updater +} + +let data = $state(makeData(100_000)) + +const options = { + columns, + get data() { + return data + } + //... + state: { + get sorting() { + return sorting + }, + get columnFilters() { + return columnFilters + }, + get pagination() { + return pagination + } + }, + onColumnFiltersChange: setColumnFilters, //hoist columnFilters state into our own state management + onSortingChange: setSorting, + onPaginationChange: setPagination, +} + +const table = createTable(options) +//... +``` + +#### Fully Controlled State + +Alternatively, you can control the entire table state with the `onStateChange` table option. It will hoist out the entire table state into your own state management system. Be careful with this approach, as you might find that raising some frequently changing state values up a Svelte tree, like `columnSizingInfo` state, might cause bad performance issues. + +A couple of more tricks may be needed to make this work. If you use the `onStateChange` table option, the initial values of the `state` must be populated with all of the relevant state values for all of the features that you want to use. You can either manually type out all of the initial state values, or use the `table.setOptions` API in a special way as shown below. + +```ts +//create a table instance with default state values +const table = createTable({ + columns, + get data() { + return data + }, + //... Note: `state` values are NOT passed in yet +}) + +const state = $state({ + ...table.initialState, //populate the initial state with all of the default state values from the table instance + pagination: { + pageIndex: 0, + pageSize: 15 //optionally customize the initial pagination state. + } +}) + +const setState = updater => { + if (updater instanceof Function) { + state = updater(state) + } state = updater +} + +//Use the table.setOptions API to merge our fully controlled state onto the table instance +table.setOptions(prev => ({ + ...prev, //preserve any other options that we have set up above + get state() { + return state //our fully controlled state overrides the internal state + }, + onStateChange: setState //any state changes will be pushed up to our own state management +})) +``` + +### On State Change Callbacks + +So far, we have seen the `on[State]Change` and `onStateChange` table options work to "hoist" the table state changes into our own state management. However, there are a few things about using these options that you should be aware of. + +#### 1. **State Change Callbacks MUST have their corresponding state value in the `state` option**. + +Specifying an `on[State]Change` callback tells the table instance that this will be a controlled state. If you do not specify the corresponding `state` value, that state will be "frozen" with its initial value. + +```ts +let sorting = $state([]) +const setSorting = updater => { + if (updater instanceof Function) { + sorting = updater(sorting) + } else sorting = updater +} +// ... +const table = createTable({ + columns, + data, + //... + state: { + get sorting() { + return sorting //required because we are using `onSortingChange` + }, + }, + onSortingChange: setSorting, //makes the `state.sorting` controlled +}) +``` + +#### 2. **Updaters can either be raw values or callback functions**. + +The `on[State]Change` and `onStateChange` callbacks work exactly like the `setState` functions in React. The updater values can either be a new state value or a callback function that takes the previous state value and returns the new state value. + +What implications does this have? It means that if you want to add in some extra logic in any of the `on[State]Change` callbacks, you can do so, but you need to check whether or not the new incoming updater value is a function or value. + +This is why you see the `if (updater instanceof Function)` check in the `setState` functions in the examples above. + +### State Types + +All complex states in TanStack Table have their own TypeScript types that you can import and use. This can be handy for ensuring that you are using the correct data structures and properties for the state values that you are controlling. + +```ts +import { createTable, type SortingState, type Updater } from '@tanstack/svelte-table' +//... +let sorting: SortingState[] = [ + { + id: 'age', //you should get autocomplete for the `id` and `desc` properties + desc: true, + } +] +const setSorting = (updater: Updater) => { + if (updater instanceof Function) { + sorting = updater(sorting) + } else sorting = updater +} +``` diff --git a/docs/framework/svelte/svelte-table.md b/docs/framework/svelte/svelte-table.md new file mode 100644 index 0000000000..32345d2668 --- /dev/null +++ b/docs/framework/svelte/svelte-table.md @@ -0,0 +1,103 @@ +--- +title: Svelte Table +--- + +> **IMPORTANT:** This version of `@tanstack/svelte-table` only supports **Svelte 5 or newer**. For Svelte 3/4 support, use version 8 of `@tanstack/svelte-table`. +> Alternatively, you can still use `@tanstack/table-core` v9 with Svelte 3/4 by copying the source code from the [v8 `@tanstack/svelte-table`](https://github.com/TanStack/table/tree/v8/packages/svelte-table/src) as a custom adapter. + +The `@tanstack/svelte-table` adapter is a wrapper around the core table logic. Most of its job is related to managing state the "Svelte" way, providing types and the rendering implementation of cell/header/footer templates. + +## Exports + +`@tanstack/svelte-table` re-exports all of `@tanstack/table-core`'s APIs and the following: + +### `createTable` + +Takes an `options` object and returns a table. + +```svelte + + + +``` + +### FlexRender + +A Svelte component for rendering cell/header/footer templates with dynamic values. + +FlexRender supports any type of renderable content supported by Svelte: + +- Scalar data types such as numbers, strings, etc. +- Svelte components (when wrapped with `renderComponent`) +- Svelte snippets (when wrapped with `renderSnippet`) + +Example: + +```svelte + + +{#snippet mailtoLink(email: string)} + + {email} + +{/snippet} + + + + {#each table.getRowModel().rows as row} + + {#each row.getVisibleCells() as cell} + + {/each} + + {/each} + +
+ +
+``` diff --git a/docs/framework/vanilla/guide/table-state.md b/docs/framework/vanilla/guide/table-state.md new file mode 100644 index 0000000000..d43bd1d74d --- /dev/null +++ b/docs/framework/vanilla/guide/table-state.md @@ -0,0 +1,5 @@ +--- +title: Table State (Vanilla JS) Guide +--- + +## Table State (Vanilla JS) Guide diff --git a/docs/framework/vanilla/table-core.md b/docs/framework/vanilla/table-core.md new file mode 100644 index 0000000000..e69de29bb2 diff --git a/docs/framework/vue/guide/table-state.md b/docs/framework/vue/guide/table-state.md new file mode 100644 index 0000000000..e58218e70e --- /dev/null +++ b/docs/framework/vue/guide/table-state.md @@ -0,0 +1,248 @@ +--- +title: Table State (Vue) Guide +--- + +## Table State (Vue) Guide + +TanStack Table has a simple underlying internal state management system to store and manage the state of the table. It also lets you selectively pull out any state that you need to manage in your own state management. This guide will walk you through the different ways in which you can interact with and manage the state of the table. + +### Accessing Table State + +You do not need to set up anything special in order for the table state to work. If you pass nothing into either `state`, `initialState`, or any of the `on[State]Change` table options, the table will manage its own state internally. You can access any part of this internal state by using the `table.store.state` table instance API. + +```ts +const table = useTable({ + columns, + data: dataRef, // Reactive data support + //... +}) + +console.log(table.store.state) //access the entire internal state +console.log(table.store.state.rowSelection) //access just the row selection state +``` + +### Using Reactive Data + +> **New in v8.20.0** + +The `useVueTable` hook now supports reactive data. This means you can pass a Vue `ref` or `computed` containing your data to the `data`-option. The table will automatically react to changes in the data. + +```ts +const columns = [ + { accessor: 'id', Header: 'ID' }, + { accessor: 'name', Header: 'Name' } +] + +const dataRef = ref([ + { id: 1, name: 'John' }, + { id: 2, name: 'Jane' } +]) + +const table = useVueTable({ + columns, + data: dataRef, // Pass the reactive data ref +}) + +// Later, updating dataRef will automatically update the table +dataRef.value = [ + { id: 1, name: 'John' }, + { id: 2, name: 'Jane' }, + { id: 3, name: 'Doe' } +] +``` + +> ⚠️ `shallowRef` is used under the hood for performance reasons, meaning that the data is not deeply reactive, only the `.value` is. To update the data you have to mutate the data directly. + +```ts +const dataRef = ref([ + { id: 1, name: 'John' }, + { id: 2, name: 'Jane' } +]) + +// This will NOT update the table ❌ +dataRef.value.push({ id: 4, name: 'John' }) + +// This will update the table ✅ +dataRef.value = [ + ...dataRef.value, + { id: 4, name: 'John' } +] +``` + +### Custom Initial State + +If all you need to do for certain states is customize their initial default values, you still do not need to manage any of the state yourself. You can simply set values in the `initialState` option of the table instance. + +```jsx +const table = useTable({ + columns, + data, + initialState: { + columnOrder: ['age', 'firstName', 'lastName'], //customize the initial column order + columnVisibility: { + id: false //hide the id column by default + }, + expanded: true, //expand all rows by default + sorting: [ + { + id: 'age', + desc: true //sort by age in descending order by default + } + ] + }, + //... +}) +``` + +> **Note**: Only specify each particular state in either `initialState` or `state`, but not both. If you pass in a particular state value to both `initialState` and `state`, the initialized state in `state` will take overwrite any corresponding value in `initialState`. + +### Controlled State + +If you need easy access to the table state in other areas of your application, TanStack Table makes it easy to control and manage any or all of the table state in your own state management system. You can do this by passing in your own state and state management functions to the `state` and `on[State]Change` table options. + +#### Individual Controlled State + +You can control just the state that you need easy access to. You do NOT have to control all of the table state if you do not need to. It is recommended to only control the state that you need on a case-by-case basis. + +In order to control a particular state, you need to both pass in the corresponding `state` value and the `on[State]Change` function to the table instance. + +Let's take filtering, sorting, and pagination as an example in a "manual" server-side data fetching scenario. You can store the filtering, sorting, and pagination state in your own state management, but leave out any other state like column order, column visibility, etc. if your API does not care about those values. + +```ts +const columnFilters = ref([]) //no default filters +const sorting = ref([{ + id: 'age', + desc: true, //sort by age in descending order by default +}]) +const pagination = ref({ pageIndex: 0, pageSize: 15 } + +//Use our controlled state values to fetch data +const tableQuery = useQuery({ + queryKey: ['users', columnFilters, sorting, pagination], + queryFn: () => fetchUsers(columnFilters, sorting, pagination), + //... +}) + +const table = useTable({ + columns, + data: tableQuery.data, + //... + state: { + get columnFilters() { + return columnFilters.value + }, + get sorting() { + return sorting.value + }, + get pagination() { + return pagination.value + } + }, + onColumnFiltersChange: updater => { + columnFilters.value = + updater instanceof Function + ? updater(columnFilters.value) + : updater + }, + onSortingChange: updater => { + sorting.value = + updater instanceof Function + ? updater(sorting.value) + : updater + }, + onPaginationChange: updater => { + pagination.value = + updater instanceof Function + ? updater(pagination.value) + : updater + }, +}) +//... +``` + +#### Fully Controlled State + +Alternatively, you can control the entire table state with the `onStateChange` table option. It will hoist out the entire table state into your own state management system. Be careful with this approach, as you might find that raising some frequently changing state values up a react tree, like `columnSizingInfo` state`, might cause bad performance issues. + +A couple of more tricks may be needed to make this work. If you use the `onStateChange` table option, the initial values of the `state` must be populated with all of the relevant state values for all of the features that you want to use. You can either manually type out all of the initial state values, or use the `table.setOptions` API in a special way as shown below. + +```jsx +//create a table instance with default state values +const table = useTable({ + get columns() { + return columns.value + }, + data, + //... Note: `state` values are NOT passed in yet +}) + +const state = ref({ + ...table.initialState, + pagination: { + pageIndex: 0, + pageSize: 15 + } +}) +const setState = updater => { + state.value = updater instanceof Function ? updater(state.value) : updater +} + +//Use the table.setOptions API to merge our fully controlled state onto the table instance +table.setOptions(prev => ({ + ...prev, //preserve any other options that we have set up above + get state() { + return state.value + }, + onStateChange: setState //any state changes will be pushed up to our own state management +})) +``` + +### On State Change Callbacks + +So far, we have seen the `on[State]Change` and `onStateChange` table options work to "hoist" the table state changes into our own state management. However, there are a few things about these using these options that you should be aware of. + +#### 1. **State Change Callbacks MUST have their corresponding state value in the `state` option**. + +Specifying an `on[State]Change` callback tells the table instance that this will be a controlled state. If you do not specify the corresponding `state` value, that state will be "frozen" with its initial value. + +```jsx +const sorting = ref([]) +const setSorting = updater => { + sorting.value = updater instanceof Function ? updater(sorting.value) : updater +} +//... +const table = useTable({ + columns, + data, + //... + state: { + get sorting() { + return sorting //required because we are using `onSortingChange` + }, + }, + onSortingChange: setSorting, //makes the `state.sorting` controlled +}) +``` + +#### 2. **Updaters can either be raw values or callback functions**. + +The `on[State]Change` and `onStateChange` callbacks work exactly like the `setState` functions in React. The updater values can either be a new state value or a callback function that takes the previous state value and returns the new state value. + +What implications does this have? It means that if you want to add in some extra logic in any of the `on[State]Change` callbacks, you can do so, but you need to check whether or not the new incoming updater value is a function or value. + +This is why we have the `updater instanceof Function` check in the `setState` functions above. This check allows us to handle both raw values and callback functions in the same function. + +### State Types + +All complex states in TanStack Table have their own TypeScript types that you can import and use. This can be handy for ensuring that you are using the correct data structures and properties for the state values that you are controlling. + +```tsx +import { useTable, type SortingState } from '@tanstack/vue-table' +//... +const sorting = ref([ + { + id: 'age', //you should get autocomplete for the `id` and `desc` properties + desc: true, + } +]) +``` diff --git a/docs/framework/vue/vue-table.md b/docs/framework/vue/vue-table.md new file mode 100644 index 0000000000..4e9ed8ffa1 --- /dev/null +++ b/docs/framework/vue/vue-table.md @@ -0,0 +1,44 @@ +--- +title: Vue Table +--- + +The `@tanstack/vue-table` adapter is a wrapper around the core table logic. Most of it's job is related to managing state the "vue" way, providing types and the rendering implementation of cell/header/footer templates. + +## Exports + +`@tanstack/vue-table` re-exports all of `@tanstack/table-core`'s APIs and the following: + +### `useTable` + +Takes an `options` object and returns a table. + +```ts +import { useTable } from '@tanstack/vue-table' + +const table = useTable(options) +// ...render your table + +``` + +### `FlexRender` + +A Vue component for rendering cell/header/footer templates with dynamic values. + +Example: + +```vue +import { FlexRender } from '@tanstack/vue-table' + + +``` diff --git a/docs/guide/cells.md b/docs/guide/cells.md new file mode 100644 index 0000000000..a6e9e443c4 --- /dev/null +++ b/docs/guide/cells.md @@ -0,0 +1,85 @@ +--- +title: Cells Guide +--- + +## API + +[Cell API](../api/core/cell) + +## Cells Guide + +This quick guide will discuss the different ways you can retrieve and interact with `cell` objects in TanStack Table. + +### Where to Get Cells From + +Cells come from [Rows](./rows). Enough said, right? + +There are multiple `row` instance APIs you can use to retrieve the appropriate cells from a row depending on which features you are using. Most commonly, you will use the `row.getAllCells` or `row.getVisibleCells` APIs (if you are using column visibility features), but there are a handful of other similar APIs that you can use. + +### Cell Objects + +Every cell object can be associated with a `` or similar cell element in your UI. There are a few properties and methods on `cell` objects that you can use to interact with the table state and extract cell values from the table based on the state of the table. + +#### Cell IDs + +Every cell object has an `id` property that makes it unique within the table instance. Each `cell.id` is constructed simply as a union of its parent row and column IDs separated by an underscore. + +```js +{ id: `${row.id}_${column.id}` } +``` + +During grouping or aggregation features, the `cell.id` will have additional string appended to it. + +#### Cell Parent Objects + +Every cell stores a reference to its parent [row](./rows) and [column](./columns) objects. + +#### Access Cell Values + +The recommended way to access data values from a cell is to use either the `cell.getValue` or `cell.renderValue` APIs. Using either of these APIs will cache the results of the accessor functions and keep rendering efficient. The only difference between the two is that `cell.renderValue` will return either the value or the `renderFallbackValue` if the value is undefined, whereas `cell.getValue` will return the value or `undefined` if the value is undefined. + +> Note: The `cell.getValue` and `cell.renderValue` APIs are shortcuts `row.getValue` and `row.renderValue` APIs, respectively. + +```js +// Access data from any of the columns +const firstName = cell.getValue('firstName') // read the cell value from the firstName column +const renderedLastName = cell.renderValue('lastName') // render the value from the lastName column +``` + +#### Access Other Row Data from Any Cell + +Since every cell object is associated with its parent row, you can access any data from the original row that you are using in your table using `cell.row.original`. + +```js +// Even if we are in the scope of a different cell, we can still access the original row data +const firstName = cell.row.original.firstName // { firstName: 'John', lastName: 'Doe' } +``` + +### More Cell APIs + +Depending on the features that you are using for your table, there are dozens more useful APIs for interacting with cells. See each features' respective API docs or guide for more information. + +### Cell Rendering + +You can just use the `cell.renderValue` or `cell.getValue` APIs to render the cells of your table. However, these APIs will only spit out the raw cell values (from accessor functions). If you are using the `cell: () => JSX` column definition options, you will want to use the `flexRender` API utility from your adapter. + +Using the `flexRender` API will allow the cell to be rendered correctly with any extra markup or JSX and it will call the callback function with the correct parameters. + +```jsx +import { flexRender } from '@tanstack/react-table' + +const columns = [ + { + accessorKey: 'fullName', + cell: ({ cell, row }) => { + return
{row.original.firstName} {row.original.lastName}
+ } + //... + } +] +//... + + {row.getVisibleCells().map(cell => { + return {flexRender(cell.column.columnDef.cell, cell.getContext())} + })} + \ No newline at end of file diff --git a/docs/guide/column-defs.md b/docs/guide/column-defs.md new file mode 100644 index 0000000000..da89bd818e --- /dev/null +++ b/docs/guide/column-defs.md @@ -0,0 +1,286 @@ +--- +title: Columns Definitions Guide +--- + +## API + +[Column Def](../api/core/column-def) + +## Column Definitions Guide + +> Note: This guide is about setting up column definitions for your table and NOT about the actual [`column`](./columns) objects that are generated within the table instance. + +Column defs are the single most important part of building a table. They are responsible for: + +- Building the underlying data model that will be used for everything including sorting, filtering, grouping, etc. +- Formatting the data model into what will be displayed in the table +- Creating [header groups](../api/core/header-group), [headers](../api/core/header) and [footers](../api/core/column-def#footer) +- Creating columns for display-only purposes, eg. action buttons, checkboxes, expanders, sparklines, etc. + +## Column Def Types + +The following "types" of column defs aren't actually TypeScript types, but more so a way to talk about and describe overall categories of column defs: + +- `Accessor Columns` + - Accessor columns have an underlying data model which means they can be sorted, filtered, grouped, etc. +- `Display Columns` + - Display columns do **not** have a data model which means they cannot be sorted, filtered, etc, but they can be used to display arbitrary content in the table, eg. a row actions button, checkbox, expander, etc. +- `Grouping Columns` + - Group columns do **not** have a data model so they too cannot be sorted, filtered, etc, and are used to group other columns together. It's common to define a header or footer for a column group. + +## Column Helpers + +While column defs are just plain objects at the end of the day, a `createColumnHelper` function is exposed from the table core which, when called with your features type and row type, returns a utility for creating different column definition types with the highest type-safety possible. + +In v9, `createColumnHelper` requires two type parameters: `TFeatures` (from your `_features` object) and `TData` (your row type). Use `typeof _features` to get the features type. + +Here's an example of creating and using a column helper: + +```tsx +// Define your row shape +type Person = { + firstName: string + lastName: string + age: number + visits: number + status: string + progress: number +} + +const _features = tableFeatures({}) // or tableFeatures({ rowSortingFeature, ... }) +const columnHelper = createColumnHelper() + +// Make some columns! Use columnHelper.columns([...]) for better type inference with nested groups +const defaultColumns = columnHelper.columns([ + // Display Column + columnHelper.display({ + id: 'actions', + cell: props => , + }), + // Grouping Column + columnHelper.group({ + header: 'Name', + footer: props => props.column.id, + columns: [ + // Accessor Column + columnHelper.accessor('firstName', { + cell: info => info.getValue(), + footer: props => props.column.id, + }), + // Accessor Column + columnHelper.accessor(row => row.lastName, { + id: 'lastName', + cell: info => info.getValue(), + header: () => Last Name, + footer: props => props.column.id, + }), + ], + }), + // Grouping Column + columnHelper.group({ + header: 'Info', + footer: props => props.column.id, + columns: [ + // Accessor Column + columnHelper.accessor('age', { + header: () => 'Age', + footer: props => props.column.id, + }), + // Grouping Column + columnHelper.group({ + header: 'More Info', + columns: [ + // Accessor Column + columnHelper.accessor('visits', { + header: () => Visits, + footer: props => props.column.id, + }), + // Accessor Column + columnHelper.accessor('status', { + header: 'Status', + footer: props => props.column.id, + }), + // Accessor Column + columnHelper.accessor('progress', { + header: 'Profile Progress', + footer: props => props.column.id, + }), + ], + }), + ], + }), +]) +``` + +## Creating Accessor Columns + +Data columns are unique in that they must be configured to extract primitive values for each item in your `data` array. + +There are 3 ways to do this: + +- If your items are `objects`, use an object-key that corresponds to the value you want to extract. +- If your items are nested `arrays`, use an array index that corresponds to the value you want to extract. +- Use an accessor function that returns the value you want to extract. + +## Object Keys + +If each of your items is an object with the following shape: + +```tsx +type Person = { + firstName: string + lastName: string + age: number + visits: number + status: string + progress: number +} +``` + +You could extract the `firstName` value like so: + +```tsx + +columnHelper.accessor('firstName') + +// OR + +{ + accessorKey: 'firstName', +} +``` + +## Deep Keys + +If each of your items is an object with the following shape: + +```tsx +type Person = { + name: { + first: string + last: string + } + info: { + age: number + visits: number + } +} +``` + +You could extract the `first` value like so: + +```tsx +columnHelper.accessor('name.first', { + id: 'firstName', +}) + +// OR + +{ + accessorKey: 'name.first', + id: 'firstName', +} +``` + +## Array Indices + +If each of your items is an array with the following shape: + +```tsx +type Sales = [Date, number] +``` + +You could extract the `number` value like so: + +```tsx +columnHelper.accessor(1) + +// OR + +{ + accessorKey: 1, +} +``` + +## Accessor Functions + +If each of your items is an object with the following shape: + +```tsx +type Person = { + firstName: string + lastName: string + age: number + visits: number + status: string + progress: number +} +``` + +You could extract a computed full-name value like so: + +```tsx +columnHelper.accessor(row => `${row.firstName} ${row.lastName}`, { + id: 'fullName', +}) + +// OR + +{ + id: 'fullName', + accessorFn: row => `${row.firstName} ${row.lastName}`, +} +``` + +> 🧠 Remember, the accessed value is what is used to sort, filter, etc. so you'll want to make sure your accessor function returns a primitive value that can be manipulated in a meaningful way. If you return a non-primitive value like an object or array, you will need the appropriate filter/sort/grouping functions to manipulate them, or even supply your own! 😬 + +## Unique Column IDs + +Columns are uniquely identified with 3 strategies: + +- If defining an accessor column with an object key or array index, the same will be used to uniquely identify the column. + - Any periods (`.`) in an object key will be replaced by underscores (`_`). +- If defining an accessor column with an accessor function + - The columns `id` property will be used to uniquely identify the column OR + - If a primitive `string` header is supplied, that header string will be used to uniquely identify the column + +> 🧠 An easy way to remember: If you define a column with an accessor function, either provide a string header or provide a unique `id` property. + +## Column Formatting & Rendering + +By default, columns cells will display their data model value as a string. You can override this behavior by providing custom rendering implementations. Each implementation is provided relevant information about the cell, header or footer and returns something your framework adapter can render eg. JSX/Components/strings/etc. This will depend on which adapter you are using. + +There are a couple of formatters available to you: + +- `cell`: Used for formatting cells. +- `aggregatedCell`: Used for formatting cells when aggregated. +- `header`: Used for formatting headers. +- `footer`: Used for formatting footers. + +## Cell Formatting + +You can provide a custom cell formatter by passing a function to the `cell` property and using the `props.getValue()` function to access your cell's value: + +```tsx +columnHelper.accessor('firstName', { + cell: props => {props.getValue().toUpperCase()}, +}) +``` + +Cell formatters are also provided the `row` and `table` objects, allowing you to customize the cell formatting beyond just the cell value. The example below provides `firstName` as the accessor, but also displays a prefixed user ID located on the original row object: + +```tsx +columnHelper.accessor('firstName', { + cell: props => ( + {`${props.row.original.id} - ${props.getValue()}`} + ), +}) +``` + +## Aggregated Cell Formatting + +For more info on aggregated cells, see [grouping](./grouping). + +## Header & Footer Formatting + +Headers and footers do not have access to row data, but still use the same concepts for displaying custom content. diff --git a/docs/guide/column-faceting.md b/docs/guide/column-faceting.md new file mode 100644 index 0000000000..b551d9dfc8 --- /dev/null +++ b/docs/guide/column-faceting.md @@ -0,0 +1,97 @@ +--- +title: Column Faceting Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [filters-faceted](../framework/react/examples/filters-faceted) + +## API + +[Column Faceting API](../api/features/column-faceting) + +## Column Faceting Guide + +Column Faceting is a feature that allows you to generate lists of values for a given column from that column's data. For example, a list of unique values in a column can be generated from all rows in that column to be used as search suggestions in an autocomplete filter component. Or, a tuple of minimum and maximum values can be generated from a column of numbers to be used as a range for a range slider filter component. + +### Column Faceting Row Models + +In order to use any of the column faceting features, add the `columnFacetingFeature` to your features and the appropriate faceted row models to `_rowModels`. + +```ts +import { + useTable, + tableFeatures, + columnFacetingFeature, + createFacetedRowModel, + createFacetedMinMaxValues, + createFacetedUniqueValues, +} from '@tanstack/react-table' + +const _features = tableFeatures({ columnFacetingFeature }) + +const table = useTable({ + _features, + _rowModels: { + facetedRowModel: createFacetedRowModel(), // required for faceting (other faceted row models depend on this) + facetedMinMaxValues: createFacetedMinMaxValues(), // if you need min/max values + facetedUniqueValues: createFacetedUniqueValues(), // if you need a list of unique values + }, + columns, + data, +}) +``` + +First, you must include the `facetedRowModel`. This row model will generate a list of values for a given column. If you need a list of unique values, include the `facetedUniqueValues` row model. If you need a tuple of minimum and maximum values, include the `facetedMinMaxValues` row model. + +### Use Faceted Row Models + +Once you have included the appropriate row models in your table options, you will be able to use the faceting column instance APIs to access the lists of values generated by the faceted row models. + +```ts +// list of unique values for autocomplete filter +const autoCompleteSuggestions = + Array.from(column.getFacetedUniqueValues().keys()) + .sort() + .slice(0, 5000); +``` + +```ts +// tuple of min and max values for range filter +const [min, max] = column.getFacetedMinMaxValues() ?? [0, 1]; +``` + +### Custom (Server-Side) Faceting + +If instead of using the built-in client-side faceting features, you can implement your own faceting logic on the server-side and pass the faceted values to the client-side. You can use the `getFacetedUniqueValues` and `getFacetedMinMaxValues` table options to resolve the faceted values from the server-side. + +```ts +const facetingQuery = useQuery( + //... +) + +const table = useTable({ + _features, + _rowModels: { + facetedRowModel: createFacetedRowModel(), + facetedUniqueValues: createFacetedUniqueValues(), + facetedMinMaxValues: createFacetedMinMaxValues(), + }, + columns, + data, + getFacetedUniqueValues: (table, columnId) => { + const uniqueValueMap = new Map() + //... + return uniqueValueMap + }, + getFacetedMinMaxValues: (table, columnId) => { + //... + return [min, max] + }, + //... +}) +``` + +Alternatively, you don't have to put any of your faceting logic through the TanStack Table APIs at all. Just fetch your lists and pass them to your filter components directly. \ No newline at end of file diff --git a/docs/guide/column-filtering.md b/docs/guide/column-filtering.md new file mode 100644 index 0000000000..2ca3b9352c --- /dev/null +++ b/docs/guide/column-filtering.md @@ -0,0 +1,361 @@ +--- +title: Column Filtering Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [Column Filters](../framework/react/examples/filters) +- [Faceted Filters](../framework/react/examples/filters-faceted) (Autocomplete and Range filters) +- [Fuzzy Search](../framework/react/examples/filters-fuzzy) (Match Sorter) +- [Editable Data](../framework/react/examples/editable-data) +- [Expanding](../framework/react/examples/expanding) (Filtering from Sub-Rows) +- [Grouping](../framework/react/examples/grouping) +- [Pagination](../framework/react/examples/pagination) +- [Row Selection](../framework/react/examples/row-selection) + +## API + +[Column Filtering API](../api/features/column-filtering) + +## Column Filtering Guide + +Filtering comes in 2 flavors: Column Filtering and Global Filtering. + +This guide will focus on column filtering, which is a filter that is applied to a single column's accessor value. + +TanStack table supports both client-side and manual server-side filtering. This guide will go over how to implement and customize both, and help you decide which one is best for your use-case. + +### Client-Side vs Server-Side Filtering + +If you have a large dataset, you may not want to load all of that data into the client's browser in order to filter it. In this case, you will most likely want to implement server-side filtering, sorting, pagination, etc. + +However, as also discussed in the [Pagination Guide](./pagination#should-you-use-client-side-pagination), a lot of developers underestimate how many rows can be loaded client-side without a performance hit. The TanStack table examples are often tested to handle up to 100,000 rows or more with decent performance for client-side filtering, sorting, pagination, and grouping. This doesn't necessarily mean that your app will be able to handle that many rows, but if your table is only going to have a few thousand rows at most, you might be able to take advantage of the client-side filtering, sorting, pagination, and grouping that TanStack table provides. + +> TanStack Table can handle thousands of client-side rows with good performance. Don't rule out client-side filtering, pagination, sorting, etc. without some thought first. + +Every use-case is different and will depend on the complexity of the table, how many columns you have, how large every piece of data is, etc. The main bottlenecks to pay attention to are: + +1. Can your server query all of the data in a reasonable amount of time (and cost)? +2. What is the total size of the fetch? (This might not scale as badly as you think if you don't have many columns.) +3. Is the client's browser using too much memory if all of the data is loaded at once? + +If you're not sure, you can always start with client-side filtering and pagination and then switch to server-side strategies in the future as your data grows. + +### Manual Server-Side Filtering + +If you have decided that you need to implement server-side filtering instead of using the built-in client-side filtering, here's how you do that. + +No `filteredRowModel` is needed for manual server-side filtering. Instead, the `data` that you pass to the table should already be filtered. However, if you have added a `filteredRowModel` to `_rowModels`, you can tell the table to skip it by setting the `manualFiltering` option to `true`. + +```jsx +const table = useTable({ + _features: tableFeatures({ columnFilteringFeature }), + _rowModels: {}, // no filteredRowModel needed for manual server-side filtering + data, + columns, + manualFiltering: true, +}) +``` + +> **Note:** When using manual filtering, many of the options that are discussed in the rest of this guide will have no effect. When `manualFiltering` is set to `true`, the table instance will not apply any filtering logic to the rows that are passed to it. Instead, it will assume that the rows are already filtered and will use the `data` that you pass to it as-is. + +### Client-Side Filtering + +If you are using the built-in client-side filtering features, add the `columnFilteringFeature` to your features and the `filteredRowModel` to your row models. Import `createFilteredRowModel` and `filterFns` from TanStack Table: + +```jsx +import { + useTable, + tableFeatures, + columnFilteringFeature, + createFilteredRowModel, + filterFns, +} from '@tanstack/react-table' + +const _features = tableFeatures({ columnFilteringFeature }) + +const table = useTable({ + _features, + _rowModels: { + filteredRowModel: createFilteredRowModel(filterFns), + }, + data, + columns, +}) +``` + +### Column Filter State + +Whether or not you use client-side or server-side filtering, you can take advantage of the built-in column filter state management that TanStack Table provides. There are many table and column APIs to mutate and interact with the filter state and retrieving the column filter state. + +The column filtering state is defined as an array of objects with the following shape: + +```ts +interface ColumnFilter { + id: string + value: unknown +} +type ColumnFiltersState = ColumnFilter[] +``` + +Since the column filter state is an array of objects, you can have multiple column filters applied at once. + +#### Accessing Column Filter State + +You can access the column filter state from the table instance just like any other table state using the `table.store.state` API. + +```jsx +const table = useTable({ + _features, + _rowModels: { filteredRowModel: createFilteredRowModel(filterFns) }, + columns, + data, + //... +}) + +console.log(table.store.state.columnFilters) // access the column filters state from the table instance +``` + +However, if you need to access the column filter state before the table is initialized, you can "control" the column filter state like down below. + +### Controlled Column Filter State + +If you need easy access to the column filter state, you can control/manage the column filter state in your own state management with the `state.columnFilters` and `onColumnFiltersChange` table options. + +```tsx +const [columnFilters, setColumnFilters] = useState([]) // can set initial column filter state here +//... +const table = useTable({ + _features, + _rowModels: { filteredRowModel: createFilteredRowModel(filterFns) }, + columns, + data, + //... + state: { + columnFilters, + }, + onColumnFiltersChange: setColumnFilters, +}) +``` + +#### Initial Column Filter State + +If you do not need to control the column filter state in your own state management or scope, but you still want to set an initial column filter state, you can use the `initialState` table option instead of `state`. + +```jsx +const table = useTable({ + _features, + _rowModels: { filteredRowModel: createFilteredRowModel(filterFns) }, + columns, + data, + //... + initialState: { + columnFilters: [ + { + id: 'name', + value: 'John', // filter the name column by 'John' by default + }, + ], + }, +}) +``` + +> **NOTE**: Do not use both `initialState.columnFilters` and `state.columnFilters` at the same time, as the initialized state in the `state.columnFilters` will override the `initialState.columnFilters`. + +### FilterFns + +Each column can have its own unique filtering logic. Choose from any of the filter functions that are provided by TanStack Table, or create your own. + +By default there are 10 built-in filter functions to choose from: + +- `includesString` - Case-insensitive string inclusion +- `includesStringSensitive` - Case-sensitive string inclusion +- `equalsString` - Case-insensitive string equality +- `equalsStringSensitive` - Case-sensitive string equality +- `arrIncludes` - Item inclusion within an array +- `arrIncludesAll` - All items included in an array +- `arrIncludesSome` - Some items included in an array +- `equals` - Object/referential equality `Object.is`/`===` +- `weakEquals` - Weak object/referential equality `==` +- `inNumberRange` - Number range inclusion + +You can also define your own custom filter functions either as the `filterFn` column option, or as a global filter function using the `filterFns` table option. + +#### Custom Filter Functions + +> **Note:** These filter functions only run during client-side filtering. + +When defining a custom filter function in either the `filterFn` column option or the `filterFns` table option, it should have the following signature: + +```ts +const myCustomFilterFn: FilterFn = (row: Row, columnId: string, filterValue: any, addMeta: (meta: any) => void) => boolean +``` + +Every filter function receives: + +- The row to filter +- The columnId to use to retrieve the row's value +- The filter value + +and should return `true` if the row should be included in the filtered rows, and `false` if it should be removed. + +```jsx +const columns = [ + { + header: () => 'Name', + accessorKey: 'name', + filterFn: 'includesString', // use built-in filter function + }, + { + header: () => 'Age', + accessorKey: 'age', + filterFn: 'inNumberRange', + }, + { + header: () => 'Birthday', + accessorKey: 'birthday', + filterFn: 'myCustomFilterFn', // use custom global filter function + }, + { + header: () => 'Profile', + accessorKey: 'profile', + // use custom filter function directly + filterFn: (row, columnId, filterValue) => { + return // true or false based on your custom logic + }, + } +] +//... +const table = useTable({ + _features, + _rowModels: { + filteredRowModel: createFilteredRowModel({ + ...filterFns, + myCustomFilterFn: (row, columnId, filterValue) => { + return // true or false based on your custom logic + }, + startsWith: startsWithFilterFn, // defined elsewhere + }), + }, + columns, + data, +}) +``` + +##### Customize Filter Function Behavior + +You can attach a few other properties to filter functions to customize their behavior: + +- `filterFn.resolveFilterValue` - This optional "hanging" method on any given `filterFn` allows the filter function to transform/sanitize/format the filter value before it is passed to the filter function. + +- `filterFn.autoRemove` - This optional "hanging" method on any given `filterFn` is passed a filter value and expected to return `true` if the filter value should be removed from the filter state. eg. Some boolean-style filters may want to remove the filter value from the table state if the filter value is set to `false`. + +```tsx +const startsWithFilterFn = ( + row: Row, + columnId: string, + filterValue: number | string, //resolveFilterValue will transform this to a string +) => + row + .getValue(columnId) + .toString() + .toLowerCase() + .trim() + .startsWith(filterValue); // toString, toLowerCase, and trim the filter value in `resolveFilterValue` + +// remove the filter value from filter state if it is falsy (empty string in this case) +startsWithFilterFn.autoRemove = (val: any) => !val; + +// transform/sanitize/format the filter value before it is passed to the filter function +startsWithFilterFn.resolveFilterValue = (val: any) => val.toString().toLowerCase().trim(); +``` + +### Customize Column Filtering + +There are a lot of table and column options that you can use to further customize the column filtering behavior. + +#### Disable Column Filtering + +By default, column filtering is enabled for all columns. You can disable the column filtering for all columns or for specific columns by using the `enableColumnFilters` table option or the `enableColumnFilter` column option. You can also turn off both column and global filtering by setting the `enableFilters` table option to `false`. + +Disabling column filtering for a column will cause the `column.getCanFilter` API to return `false` for that column. + +```jsx +const columns = [ + { + header: () => 'Id', + accessorKey: 'id', + enableColumnFilter: false, // disable column filtering for this column + }, + //... +] +//... +const table = useTable({ + _features, + _rowModels: { filteredRowModel: createFilteredRowModel(filterFns) }, + columns, + data, + enableColumnFilters: false, // disable column filtering for all columns +}) +``` + +#### Filtering Sub-Rows (Expanding) + +There are a few additional table options to customize the behavior of column filtering when using features like expanding, grouping, and aggregation. + +##### Filter From Leaf Rows + +By default, filtering is done from parent rows down, so if a parent row is filtered out, all of its child sub-rows will be filtered out as well. Depending on your use-case, this may be the desired behavior if you only want the user to be searching through the top-level rows, and not the sub-rows. This is also the most performant option. + +However, if you want to allow sub-rows to be filtered and searched through, regardless of whether the parent row is filtered out, you can set the `filterFromLeafRows` table option to `true`. Setting this option to `true` will cause filtering to be done from leaf rows up, which means parent rows will be included so long as one of their child or grand-child rows is also included. + +```jsx +const table = useTable({ + _features: tableFeatures({ columnFilteringFeature, rowExpandingFeature }), + _rowModels: { + filteredRowModel: createFilteredRowModel(filterFns), + expandedRowModel: createExpandedRowModel(), + }, + columns, + data, + filterFromLeafRows: true, // filter and search through sub-rows +}) +``` + +##### Max Leaf Row Filter Depth + +By default, filtering is done for all rows in a tree, no matter if they are root level parent rows or the child leaf rows of a parent row. Setting the `maxLeafRowFilterDepth` table option to `0` will cause filtering to only be applied to the root level parent rows, with all sub-rows remaining unfiltered. Similarly, setting this option to `1` will cause filtering to only be applied to child leaf rows 1 level deep, and so on. + +Use `maxLeafRowFilterDepth: 0` if you want to preserve a parent row's sub-rows from being filtered out while the parent row is passing the filter. + +```jsx +const table = useTable({ + _features: tableFeatures({ columnFilteringFeature, rowExpandingFeature }), + _rowModels: { + filteredRowModel: createFilteredRowModel(filterFns), + expandedRowModel: createExpandedRowModel(), + }, + columns, + data, + maxLeafRowFilterDepth: 0, // only filter root level parent rows out +}) +``` + +### Column Filter APIs + +There are a lot of Column and Table APIs that you can use to interact with the column filter state and hook up to your UI components. Here is a list of the available APIs and their most common use-cases: + +- `table.setColumnFilters` - Overwrite the entire column filter state with a new state. +- `table.resetColumnFilters` - Useful for a "clear all/reset filters" button. + +- **`column.getFilterValue`** - Useful for getting the default initial filter value for an input, or even directly providing the filter value to a filter input. +- **`column.setFilterValue`** - Useful for connecting filter inputs to their `onChange` or `onBlur` handlers. + +- `column.getCanFilter` - Useful for disabling/enabling filter inputs. +- `column.getIsFiltered` - Useful for displaying a visual indicator that a column is currently being filtered. +- `column.getFilterIndex` - Useful for displaying in what order the current filter is being applied. + +- `column.getAutoFilterFn` - Used internally to find the default filter function for a column if none is specified. +- `column.getFilterFn` - Useful for displaying which filter mode or function is currently being used. diff --git a/docs/guide/column-ordering.md b/docs/guide/column-ordering.md new file mode 100644 index 0000000000..9bd77a6f7d --- /dev/null +++ b/docs/guide/column-ordering.md @@ -0,0 +1,115 @@ +--- +title: Column Ordering Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [column-ordering](../framework/react/examples/column-ordering) +- [column-dnd](../framework/react/examples/column-dnd) + +## API + +[Column Ordering API](../api/features/column-ordering) + +## Column Ordering Guide + +By default, columns are ordered in the order they are defined in the `columns` array. However, you can manually specify the column order using the `columnOrder` state. Other features like column pinning and grouping can also affect the column order. + +### What Affects Column Order + +There are 3 table features that can reorder columns, which happen in the following order: + +1. [Column Pinning](./column-pinning) - If pinning, columns are split into left, center (unpinned), and right pinned columns. +2. Manual **Column Ordering** - A manually specified column order is applied. +3. [Grouping](./grouping) - If grouping is enabled, a grouping state is active, and `tableOptions.groupedColumnMode` is set to `'reorder' | 'remove'`, then the grouped columns are reordered to the start of the column flow. + +> **Note:** `columnOrder` state will only affect unpinned columns if used in conjunction with column pinning. + +### Column Order State + +If you don't provide a `columnOrder` state, TanStack Table will just use the order of the columns in the `columns` array. However, you can provide an array of string column ids to the `columnOrder` state to specify the order of the columns. + +#### Default Column Order + +If all you need to do is specify the initial column order, you can just specify the `columnOrder` state in the `initialState` table option. + +```jsx +const table = useTable({ + _features: tableFeatures({ columnOrderingFeature }), + _rowModels: {}, + //... + initialState: { + columnOrder: ['columnId1', 'columnId2', 'columnId3'], + }, + //... +}) +``` + +> **Note:** If you are using the `state` table option to also specify the `columnOrder` state, the `initialState` will have no effect. Only specify particular states in either `initialState` or `state`, not both. + +#### Managing Column Order State + +If you need to dynamically change the column order, or set the column order after the table has been initialized, you can manage the `columnOrder` state just like any other table state. + +```jsx +const [columnOrder, setColumnOrder] = useState(['columnId1', 'columnId2', 'columnId3']) +//... +const table = useTable({ + _features: tableFeatures({ columnOrderingFeature }), + _rowModels: {}, + //... + state: { + columnOrder, + //... + } + onColumnOrderChange: setColumnOrder, + //... +}); +``` + +### Reordering Columns + +If the table has UI that allows the user to reorder columns, you can set up the logic something like this: + +```tsx +const [columnOrder, setColumnOrder] = useState(columns.map(c => c.id)); + +//depending on your dnd solution of choice, you may or may not need state like this +const [movingColumnId, setMovingColumnId] = useState(null); +const [targetColumnId, setTargetColumnId] = useState(null); + +//util function to splice and reorder the columnOrder array +const reorderColumn = ( + movingColumnId: Column, + targetColumnId: Column, +): string[] => { + const newColumnOrder = [...columnOrder]; + newColumnOrder.splice( + newColumnOrder.indexOf(targetColumnId), + 0, + newColumnOrder.splice(newColumnOrder.indexOf(movingColumnId), 1)[0], + ); + setColumnOrder(newColumnOrder); +}; + +const handleDragEnd = (e: DragEvent) => { + if(!movingColumnId || !targetColumnId) return; + setColumnOrder(reorderColumn(movingColumnId, targetColumnId)); +}; + +//use your dnd solution of choice +``` + +#### Drag and Drop Column Reordering Suggestions (React) + +There are undoubtedly many ways to implement drag and drop features along-side TanStack Table. Here are a few suggestions in order for you to not have a bad time: + +1. Do NOT try to use [`"react-dnd"`](https://react-dnd.github.io/react-dnd/docs/overview) _if you are using React 18 or newer_. React DnD was an important library for its time, but it now does not get updated very often, and it has incompatibilities with React 18, especially in React Strict Mode. It is still possible to get it to work, but there are newer alternatives that have better compatibility and are more actively maintained. React DnD's Provider may also interfere and conflict with any other DnD solutions you may want to try in your app. + +2. Use [`"@dnd-kit/core"`](https://dndkit.com/). DnD Kit is a modern, modular and lightweight drag and drop library that is highly compatible with the modern React ecosystem, and it works well with semantic `` markup. Both of the official TanStack DnD examples, [Column DnD](../framework/react/examples/column-dnd) and [Row DnD](../framework/react/examples/row-dnd), now use DnD Kit. + +3. Consider other DnD libraries like [`"react-beautiful-dnd"`](https://github.com/atlassian/react-beautiful-dnd), but be aware of their potentially large bundle sizes, maintenance status, and compatibility with `
` markup. + +4. Consider using native browser events and state management to implement lightweight drag and drop features. However, be aware that this approach may not be best for mobile users if you do not go the extra mile to implement proper touch events. [Material React Table V2](https://www.material-react-table.com/docs/examples/column-ordering) is an example of a library that implements TanStack Table with only browser drag and drop events such as `onDragStart`, `onDragEnd`, `onDragEnter` and no other dependencies. Browse its source code to see how it is done. \ No newline at end of file diff --git a/docs/guide/column-pinning.md b/docs/guide/column-pinning.md new file mode 100644 index 0000000000..228ed8de32 --- /dev/null +++ b/docs/guide/column-pinning.md @@ -0,0 +1,100 @@ +--- +title: Column Pinning Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [column-pinning](../framework/react/examples/column-pinning) +- [sticky-column-pinning](../framework/react/examples/column-pinning-sticky) + + ### Other Examples + +- [Svelte column-pinning](../framework/svelte/examples/column-pinning) +- [Vue column-pinning](../framework/vue/examples/column-pinning) + +## API + +[Column Pinning API](../api/features/column-pinning) + +## Column Pinning Guide + +TanStack Table offers state and APIs helpful for implementing column pinning features in your table UI. You can implement column pinning in multiple ways. You can either split pinned columns into their own separate tables, or you can keep all columns in the same table, but use the pinning state to order the columns correctly and use sticky CSS to pin the columns to the left or right. + +### How Column Pinning Affects Column Order + +There are 3 table features that can reorder columns, which happen in the following order: + +1. **Column Pinning** - If pinning, columns are split into left, center (unpinned), and right pinned columns. +2. Manual [Column Ordering](./column-ordering) - A manually specified column order is applied. +3. [Grouping](./grouping) - If grouping is enabled, a grouping state is active, and `tableOptions.groupedColumnMode` is set to `'reorder' | 'remove'`, then the grouped columns are reordered to the start of the column flow. + +The only way to change the order of the pinned columns is in the `columnPinning.left` and `columnPinning.right` state itself. `columnOrder` state will only affect the order of the unpinned ("center") columns. + +### Column Pinning State + +Managing the `columnPinning` state is optional, and usually not necessary unless you are adding persistent state features. TanStack Table will already keep track of the column pinning state for you. Manage the `columnPinning` state just like any other table state if you need to. + +```jsx +import { useTable, tableFeatures, columnPinningFeature } from '@tanstack/react-table' + +const _features = tableFeatures({ columnPinningFeature }) + +const [columnPinning, setColumnPinning] = useState({ + left: [], + right: [], +}) + +const table = useTable({ + _features, + _rowModels: {}, + //... + state: { + columnPinning, + //... + }, + onColumnPinningChange: setColumnPinning, + //... +}) +``` + +### Pin Columns by Default + +A very common use case is to pin some columns by default. You can do this by either initializing the `columnPinning` state with the pinned columnIds, or by using the `initialState` table option + +```jsx +const table = useTable({ + _features, + _rowModels: {}, + //... + initialState: { + columnPinning: { + left: ['expand-column'], + right: ['actions-column'], + }, + //... + }, + //... +}) +``` + +### Useful Column Pinning APIs + +> Note: These APIs are available when using `columnPinningFeature`. + +There are a handful of useful Column API methods to help you implement column pinning features: + +- [`column.getCanPin`](../api/features/column-pinning#getcanpin): Use to determine if a column can be pinned. +- [`column.pin`](../api/features/column-pinning#pin): Use to pin a column to the left or right. Or use to unpin a column. +- [`column.getIsPinned`](../api/features/column-pinning#getispinned): Use to determine where a column is pinned. +- [`column.getStart`](../api/features/column-pinning#getstart): Use to provide the correct `left` CSS value for a pinned column. +- [`column.getAfter`](../api/features/column-pinning#getafter): Use to provide the correct `right` CSS value for a pinned column. +- [`column.getIsLastColumn`](../api/features/column-pinning#getislastcolumn): Use to determine if a column is the last column in its pinned group. Useful for adding a box-shadow +- [`column.getIsFirstColumn`](../api/features/column-pinning#getisfirstcolumn): Use to determine if a column is the first column in its pinned group. Useful for adding a box-shadow + +### Split Table Column Pinning + +If you are just using sticky CSS to pin columns, you can for the most part, just render the table as you normally would with the `table.getHeaderGroups` and `row.getVisibleCells` methods. + +However, if you are splitting up pinned columns into their own separate tables, you can make use of the `table.getLeftHeaderGroups`, `table.getCenterHeaderGroups`, `table.getRightHeaderGroups`, `row.getLeftVisibleCells`, `row.getCenterVisibleCells`, and `row.getRightVisibleCells` methods to only render the columns that are relevant to the current table. diff --git a/docs/guide/column-sizing.md b/docs/guide/column-sizing.md new file mode 100644 index 0000000000..106d76485d --- /dev/null +++ b/docs/guide/column-sizing.md @@ -0,0 +1,179 @@ +--- +title: Column Sizing Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [column-sizing](../framework/react/examples/column-sizing) +- [column-resizing-performant](../framework/react/examples/column-resizing-performant) + +## API + +[Column Sizing API](../api/features/column-sizing) + +## Column Sizing Guide + +The column sizing feature allows you to optionally specify the width of each column including min and max widths. It also allows you and your users the ability to dynamically change the width of all columns at will, eg. by dragging the column headers. + +### Column Widths + +Columns by default are given the following measurement options: + +```tsx +export const defaultColumnSizing = { + size: 150, + minSize: 20, + maxSize: Number.MAX_SAFE_INTEGER, +} +``` + +These defaults can be overridden by both `tableOptions.defaultColumn` and individual column defs, in that order. + +```tsx +const columns = [ + { + accessorKey: 'col1', + size: 270, //set column size for this column + }, + //... +] + +const table = useTable({ + _features: tableFeatures({ columnSizingFeature, columnResizingFeature }), // columnResizingFeature for drag-to-resize + _rowModels: {}, + defaultColumn: { + size: 200, // starting column size + minSize: 50, // enforced during column resizing + maxSize: 500, // enforced during column resizing + }, + //... +}) +``` + +The column "sizes" are stored in the table state as numbers, and are usually interpreted as pixel unit values, but you can hook up these column sizing values to your css styles however you see fit. + +As a headless utility, table logic for column sizing is really only a collection of states that you can apply to your own layouts how you see fit (our example above implements 2 styles of this logic). You can apply these width measurements in a variety of ways: + +- semantic `table` elements or any elements being displayed in a table css mode +- `div/span` elements or any elements being displayed in a non-table css mode + - Block level elements with strict widths + - Absolutely positioned elements with strict widths + - Flexbox positioned elements with loose widths + - Grid positioned elements with loose widths +- Really any layout mechanism that can interpolate cell widths into a table structure. + +Each of these approaches has its own tradeoffs and limitations which are usually opinions held by a UI/component library or design system, luckily not you 😉. + +### Column Resizing + +TanStack Table provides built-in column resizing state and APIs that allow you to easily implement column resizing in your table UI with a variety of options for UX and performance. + +#### Enable Column Resizing + +By default, the `column.getCanResize()` API will return `true` by default for all columns, but you can either disable column resizing for all columns with the `enableColumnResizing` table option, or disable column resizing on a per-column basis with the `enableResizing` column option. + +```tsx +const columns = [ + { + accessorKey: 'id', + enableResizing: false, //disable resizing for just this column + size: 200, //starting column size + }, + //... +] +``` + +#### Column Resize Mode + +By default, the column resize mode is set to `"onEnd"`. This means that the `column.getSize()` API will not return the new column size until the user has finished resizing (dragging) the column. Usually a small UI indicator will be displayed while the user is resizing the column. + +In React TanStack Table adapter, where achieving 60 fps column resizing renders can be difficult, depending on the complexity of your table or web page, the `"onEnd"` column resize mode can be a good default option to avoid stuttering or lagging while the user resizes columns. That is not to say that you cannot achieve 60 fps column resizing renders while using TanStack React Table, but you may have to do some extra memoization or other performance optimizations in order to achieve this. + +> Advanced column resizing performance tips will be discussed [down below](#advanced-column-resizing-performance). + +If you want to change the column resize mode to `"onChange"` for immediate column resizing renders, you can do so with the `columnResizeMode` table option. + +```tsx +const table = useTable({ + //... + columnResizeMode: 'onChange', //change column resize mode to "onChange" +}) +``` + +#### Column Resize Direction + +By default, TanStack Table assumes that the table markup is laid out in a left-to-right direction. For right-to-left layouts, you may need to change the column resize direction to `"rtl"`. + +```tsx +const table = useTable({ + //... + columnResizeDirection: 'rtl', //change column resize direction to "rtl" for certain locales +}) +``` + +#### Connect Column Resizing APIs to UI + +There are a few really handy APIs that you can use to hook up your column resizing drag interactions to your UI. + +##### Column Size APIs + +To apply the size of a column to the column head cells, data cells, or footer cells, you can use the following APIs: + +```ts +header.getSize() +column.getSize() +cell.column.getSize() +``` + +How you apply these size styles to your markup is up to you, but it is pretty common to use either CSS variables or inline styles to apply the column sizes. + +```tsx + +) +``` + +#### Do We Have to Do It This Way? + +This is just a new way to integrate custom code along-side the built-in features in TanStack Table. In our example up above, we could have just as easily stored the `density` state in a `React.useState`, defined our own `toggleDensity` handler wherever, and just used it in our code separately from the table instance. Building table features along-side TanStack Table instead of deeply integrating them into the table instance is still a perfectly valid way to build custom features. Depending on your use case, this may or may not be the cleanest way to extend TanStack Table with custom features. diff --git a/docs/guide/data.md b/docs/guide/data.md new file mode 100644 index 0000000000..79081dbe20 --- /dev/null +++ b/docs/guide/data.md @@ -0,0 +1,255 @@ +--- +title: Data Guide +--- + +## Data Guide + +Tables start with your data. Your column definitions and rows will depend on the shape of your data. TanStack Table has some TypeScript features that will help you create the rest of your table code with a great type-safe experience. If you set up your data and types correctly, TanStack Table will be able to infer the shape of your data and enforce that your column definitions are made correctly. + +### TypeScript + +TypeScript is NOT required to use the TanStack Table packages... ***BUT*** TanStack Table is written and organized in such a way that makes the awesome TypeScript experience that you get feel like it is one of the main selling points of the library. If you are not using TypeScript, you will be missing out on a lot of great autocompletion and type-checking features that will both speed up your development time and reduce the number of bugs in your code. + +#### TypeScript Generics + +Having a basic understanding of what TypeScript Generics are and how they work will help you understand this guide better, but it should be easy enough to pick up as you go. The official [TypeScript Generics Docs](https://www.typescriptlang.org/docs/handbook/2/generics.html) may be helpful for those not yet familiar with TypeScript. + +### Defining Data Types + +`data` is an array of objects that will be turned into the rows of your table. Each object in the array represents a row of data (under normal circumstances). If you are using TypeScript, we usually define a type for the shape of our data. This type is used as a generic type for all of the other table, column, row, and cell instances. This Generic is usually referred to as `TData` throughout the rest of the TanStack Table types and APIs. + +For example, if we have a table that displays a list of users in an array like this: + +```json +[ + { + "firstName": "Tanner", + "lastName": "Linsley", + "age": 33, + "visits": 100, + "progress": 50, + "status": "Married" + }, + { + "firstName": "Kevin", + "lastName": "Vandy", + "age": 27, + "visits": 200, + "progress": 100, + "status": "Single" + } +] +``` + +Then we can define a User (TData) type like this: + +```ts +//TData +type User = { + firstName: string + lastName: string + age: number + visits: number + progress: number + status: string +} +``` + +We can then define our `data` array with this type, and then TanStack Table will be able to intelligently infer lots of types for us later on in our columns, rows, cells, etc. This is because the `data` type is literally defined as the `TData` generic type. Whatever you pass to the `data` table option will become the `TData` type for the rest of the table instance. Just make sure your column definitions use the same `TData` type as the `data` type when you define them later. + +```ts +//note: data needs a "stable" reference in order to prevent infinite re-renders +const data: User[] = [] +//or +const [data, setData] = React.useState([]) +//or +const data = ref([]) //vue +//etc... +``` + +#### Deep Keyed Data + +If your data is not a nice flat array of objects, that's okay! Once you get around to defining your columns, there are strategies for accessing deeply nested data in your accessors. + +If your `data` looks something like this: + +```json +[ + { + "name": { + "first": "Tanner", + "last": "Linsley" + }, + "info": { + "age": 33, + "visits": 100, + } + }, + { + "name": { + "first": "Kevin", + "last": "Vandy" + }, + "info": { + "age": 27, + "visits": 200, + } + } +] +``` + +You can define a type like this: + +```ts +type User = { + name: { + first: string + last: string + } + info: { + age: number + visits: number + } +} +``` + +And you will be able to access the data in your column definitions with either dot notation in an accessorKey or simply by using an accessorFn. + +```ts +const columns = [ + { + header: 'First Name', + accessorKey: 'name.first', + }, + { + header: 'Last Name', + accessorKey: 'name.last', + }, + { + header: 'Age', + accessorFn: info => info.age, + }, + //... +] +``` + +This is discussed in more detail in the [Column Def Guide](./column-defs). + +> NOTE: The "keys" in your json data can usually be anything, but any periods in the keys will be interpreted as a deep key and will cause errors. + +#### Nested Sub-Row Data + +If you are using expanding features, it can be common to have nested sub-rows in your data. This results in a recursive type that is a bit different. + +So if your data looks like this: + +```json +[ + { + "firstName": "Tanner", + "lastName": "Linsley", + "subRows": [ + { + "firstName": "Kevin", + "lastName": "Vandy", + }, + { + "firstName": "John", + "lastName": "Doe", + "subRows": [ + //... + ] + } + ] + }, + { + "firstName": "Jane", + "lastName": "Doe", + } +] +``` + +You can define a type like this: + +```ts +type User = { + firstName: string + lastName: string + subRows?: User[] //does not have to be called "subRows", can be called anything +} +``` + +Where `subRows` is an optional array of `User` objects. This is discussed in more detail in the [Expanding Guide](./expanding). + +### Give Data a "Stable" Reference + +The `data` array that you pass to the table instance ***MUST*** have a "stable" reference in order to prevent bugs that cause infinite re-renders (especially in React). + +This will depend on which framework adapter you are using, but in React, you should often use `React.useState`, `React.useMemo`, or similar to ensure that both the `data` and `columns` table options have stable references. + +```tsx +const fallbackData = [] +const _features = tableFeatures({}) // Define outside component for stable reference + +export default function MyComponent() { + //✅ GOOD: This will not cause an infinite loop of re-renders because `columns` is a stable reference + const columns = useMemo(() => [ + // ... + ], []); + + //✅ GOOD: This will not cause an infinite loop of re-renders because `data` is a stable reference + const [data, setData] = useState(() => [ + // ... + ]); + + // Columns and data are defined in a stable reference, will not cause infinite loop! + const table = useTable({ + _features, + _rowModels: {}, + columns, + data ?? fallbackData, //also good to use a fallback array that is defined outside of the component (stable reference) + }); + + return
+``` + +Though, as discussed in the [advanced column resizing performance section](#advanced-column-resizing-performance), you may want to consider using CSS variables to apply column sizes to your markup. + +##### Column Resize APIs + +TanStack Table provides a pre-built event handler to make your drag interactions easy to implement. These event handlers are just convenience functions that call other internal APIs to update the column sizing state and re-render the table. Use `header.getResizeHandler()` to connect to your column resize drag interactions, for both mouse and touch events. + +```tsx + +``` + +##### Column Resize Indicator with ColumnSizingInfoState + +TanStack Table keeps track of an state object called `columnSizingInfo` that you can use to render a column resize indicator UI. + +```jsx + +``` + +#### Advanced Column Resizing Performance + +If you are creating large or complex tables (and using React 😉), you may find that if you do not add proper memoization to your render logic, your users may experience degraded performance while resizing columns. + +We have created a [performant column resizing example](../framework/react/examples/column-resizing-performant) that demonstrates how to achieve 60 fps column resizing renders with a complex table that may otherwise have slow renders. It is recommended that you just look at that example to see how it is done, but these are the basic things to keep in mind: + +1. Don't use `column.getSize()` on every header and every data cell. Instead, calculate all column widths once upfront, **memoized**! +2. Memoize your Table Body while resizing is in progress. +3. Use CSS variables to communicate column widths to your table cells. + +If you follow these steps, you should see significant performance improvements while resizing columns. + +If you are not using React, and are using the Svelte, Vue, or Solid adapters instead, you may not need to worry about this as much, but similar principles apply. diff --git a/docs/guide/column-visibility.md b/docs/guide/column-visibility.md new file mode 100644 index 0000000000..864b76a7b5 --- /dev/null +++ b/docs/guide/column-visibility.md @@ -0,0 +1,137 @@ +--- +title: Column Visibility Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [column-visibility](../framework/react/examples/column-visibility) +- [column-ordering](../framework/react/examples/column-ordering) +- [sticky-column-pinning](../framework/react/examples/column-pinning-sticky) + +### Other Examples + +- [SolidJS column-visibility](../framework/solid/examples/column-visibility) +- [Svelte column-visibility](../framework/svelte/examples/column-visibility) + +## API + +[Column Visibility API](../api/features/column-visibility) + +## Column Visibility Guide + +The column visibility feature allows table columns to be hidden or shown dynamically. In v9, add `columnVisibilityFeature` to your `_features` to enable this. There is a dedicated `columnVisibility` state and APIs for managing column visibility dynamically. + +### Column Visibility State + +The `columnVisibility` state is a map of column IDs to boolean values. A column will be hidden if its ID is present in the map and the value is `false`. If the column ID is not present in the map, or the value is `true`, the column will be shown. + +```jsx +import { useTable, tableFeatures, columnVisibilityFeature } from '@tanstack/react-table' + +const [columnVisibility, setColumnVisibility] = useState({ + columnId1: true, + columnId2: false, // hide this column by default + columnId3: true, +}) + +const table = useTable({ + _features: tableFeatures({ columnVisibilityFeature }), + _rowModels: {}, + //... + state: { + columnVisibility, + //... + }, + onColumnVisibilityChange: setColumnVisibility, +}) +``` + +Alternatively, if you don't need to manage the column visibility state outside of the table, you can still set the initial default column visibility state using the `initialState` option. + +> **Note**: If `columnVisibility` is provided to both `initialState` and `state`, the `state` initialization will take precedence and `initialState` will be ignored. Do not provide `columnVisibility` to both `initialState` and `state`, only one or the other. + +```jsx +const table = useTable({ + _features: tableFeatures({ columnVisibilityFeature }), + _rowModels: {}, + //... + initialState: { + columnVisibility: { + columnId1: true, + columnId2: false, // hide this column by default + columnId3: true, + }, + //... + }, +}) +``` + +### Disable Hiding Columns + +By default, all columns can be hidden or shown. If you want to prevent certain columns from being hidden, you set the `enableHiding` column option to `false` for those columns. + +```jsx +const columns = [ + { + header: 'ID', + accessorKey: 'id', + enableHiding: false, // disable hiding for this column + }, + { + header: 'Name', + accessor: 'name', // can be hidden + }, +]; +``` + +### Column Visibility Toggle APIs + +There are several column API methods that are useful for rendering column visibility toggles in the UI. + +- `column.getCanHide` - Useful for disabling the visibility toggle for a column that has `enableHiding` set to `false`. +- `column.getIsVisible` - Useful for setting the initial state of the visibility toggle. +- `column.toggleVisibility` - Useful for toggling the visibility of a column. +- `column.getToggleVisibilityHandler` - Shortcut for hooking up the `column.toggleVisibility` method to a UI event handler. + +```jsx +{table.getAllColumns().map((column) => ( + +))} +``` + +### Column Visibility Aware Table APIs + +When you render your header, body, and footer cells, there are a lot of API options available. You may see APIs like `table.getAllLeafColumns` and `row.getAllCells`, but if you use these APIs, they will not take column visibility into account. Instead, you need to use the "visible" variants of these APIs, such as `table.getVisibleLeafColumns` and `row.getVisibleCells`. + +```jsx + + + + {table.getVisibleLeafColumns().map((column) => ( // takes column visibility into account + // + ))} + + + + {table.getRowModel().rows.map((row) => ( + + {row.getVisibleCells().map((cell) => ( // takes column visibility into account + // + ))} + + ))} + +
+``` + +If you are using the Header Group APIs, they will already take column visibility into account. diff --git a/docs/guide/columns.md b/docs/guide/columns.md new file mode 100644 index 0000000000..d446c3dc27 --- /dev/null +++ b/docs/guide/columns.md @@ -0,0 +1,72 @@ +--- +title: Columns Guide +--- + +## API + +[Column API](../api/core/column) + +## Columns Guide + +> Note: This guide is about the actual `column` objects that are generated within the table instance and NOT about setting up the [column definitions](./column-defs) for your table. + +This quick guide will discuss the different ways you can retrieve and interact with `column` objects in TanStack Table. + +### Where to Get Columns From + +You can find the `column` objects in many places. They are often attached + +#### Header and Cell Objects + +Before you reach for one of the `table` instance APIs, consider if you actually need to retrieve either [headers](./headers) or [cells](./cells) instead of `columns`. If you are rending out the markup for your table, you will most likely want to reach for the APIs that return headers or cells instead of columns. The column objects themselves are not really meant to render out the headers or cells, but the `header` and `cell` objects will contain references to these `column` objects from which they can derive the necessary information to render their UI. + +```js +const column = cell.column; // get column from cell +const column = header.column; // get column from header +``` + +#### Column Table Instance APIs + +There are dozens of `table` instance APIs you can use to retrieve columns from the table instance. Which APIs you will use will depend entirely on which features you are using in your table and your use-case. + +##### Get Column + +If you need to just get a single column by its ID, you can use the `table.getColumn` API. + +```js +const column = table.getColumn('firstName'); +``` + +##### Get Columns + +The simplest column API is `table.getAllColumns`, which will return a list of all columns in the table. There are dozens of other column APIs that are affected by other features and the state of the table that come alongside this API though. `table.getAllFlatColumns`, `table.getAllLeafColumns`, `getCenterLeafColumns`, `table.getLeftVisibleLeafColumns` are just some examples of other column APIs that you might use in tandem with the column visibility or column pinning features. + +### Column Objects + +Column objects are not actually meant to be used to render out the table UI directly, so they are not associated 1-to-1 with any `
` or `` elements in your table, but they contain a lot of useful properties and methods that you can use to interact with the table state. + +#### Column IDs + +Every column must have a unique `id` defined in their associated [Column Definition](./column-defs). Usually, you define this `id` yourself, or it is derived from the `accessorKey` or `header` properties in the column definition. + +#### ColumnDef + +A reference to the original `columnDef` object that was used to created the column is always available on the column object. + +#### Nested Grouped Columns Properties + +There are a few properties on `column` objects that are only useful if the column is part of a nested or grouped column structure. These properties include: + +- `columns`: An array of child columns that belong to a group column. +- `depth`: The header group "row index" that the column group belongs to. +- `parent`: The parent column of the column. If the column is a top-level column, this will be `undefined`. + +### More Column APIs + +There are dozens of Column APIs that you can use to interact with the table state and extract cell values from the table based on the state of the table. See each features column API documentation for more information. + +### Column Rendering + +Don't necessarily use `column` objects to render `headers` or `cells` directly. Instead, use the [`header`](./headers) and [`cell`](./cells) objects, as discussed above. + +But if you are just rendering a list of columns somewhere else in your UI for something like a column visibility menu or something similar, you can just map over a columns array and render out the UI as you normally would. diff --git a/docs/guide/custom-features.md b/docs/guide/custom-features.md new file mode 100644 index 0000000000..5675bf0ea7 --- /dev/null +++ b/docs/guide/custom-features.md @@ -0,0 +1,286 @@ +--- +title: Custom Features Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [custom-features](../framework/react/examples/custom-features) + +## Custom Features Guide + +In this guide, we'll cover how to extend TanStack Table with custom features, and along the way, we'll learn more about how the TanStack Table v9 codebase is structured and how it works. + +### TanStack Table Strives to be Lean + +TanStack Table has a core set of features that are built into the library such as sorting, filtering, pagination, etc. We've received a lot of requests and sometimes even some well thought out PRs to add even more features to the library. While we are always open to improving the library, we also want to make sure that TanStack Table remains a lean library that does not include too much bloat and code that is unlikely to be used in most use cases. Not every PR can, or should, be accepted into the core library, even if it does solve a real problem. This can be frustrating to developers where TanStack Table solves 90% of their use case, but they need a little bit more control. + +TanStack Table has always been built in a way that allows it to be highly extensible (at least since v7). The `table` instance that is returned from whichever framework adapter that you are using (`createTable`, `useTable`, etc) is a plain JavaScript object that can have extra properties or APIs added to it. It has always been possible to use composition to add custom logic, state, and APIs to the table instance. Libraries like [Material React Table](https://github.com/KevinVandy/material-react-table/blob/v2/packages/material-react-table/src/hooks/useMRT_TableInstance.ts) have simply created custom wrapper hooks around the `useTable` hook to extend the table instance with custom functionality. + +In v9, TanStack Table uses the `_features` option (via `tableFeatures()`) to declare which features your table uses. This enables tree-shaking—you only bundle the code for the features you need. You can add custom features to the table instance in exactly the same way as the built-in features. + +> In v9, features are opt-in. Use `tableFeatures({ ... })` to declare which features your table uses, including custom features. + +### How TanStack Table Features Work + +TanStack Table's source code is arguably somewhat simple (at least we think so). All code for each feature is split up into its own object/file with instantiation methods to create initial state, default table and column options, and API methods that can be added to the `table`, `header`, `column`, `row`, and `cell` instances. + +All of the functionality of a feature object can be described with the `TableFeature` type that is exported from TanStack Table. This type is a TypeScript interface that describes the shape of a feature object needed to create a feature. + +```ts +export interface TableFeature { + constructCell?: ( + cell: Cell, + column: Column, + row: Row, + table: Table + ) => void + constructColumn?: (column: Column, table: Table) => void + constructHeader?: (header: Header, table: Table) => void + constructRow?: (row: Row, table: Table) => void + constructTable?: (table: Table) => void + getDefaultColumnDef?: () => Partial> + getDefaultTableOptions?: ( + table: Table + ) => Partial> + getInitialState?: (initialState?: InitialTableState) => Partial +} +``` + +This might be a bit confusing, so let's break down what each of these methods do: + +#### Default Options and Initial State + +
+ +##### getDefaultTableOptions + +The `getDefaultTableOptions` method in a table feature is responsible for setting the default table options for that feature. For example, in the [Column Sizing](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/columnSizingFeature.ts) feature, the `getDefaultTableOptions` method sets the default `columnResizeMode` option with a default value of `"onEnd"`. + +
+ +##### getDefaultColumnDef + +The `getDefaultColumnDef` method in a table feature is responsible for setting the default column options for that feature. For example, in the [Sorting](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/rowSortingFeature.ts) feature, the `getDefaultColumnDef` method sets the default `sortUndefined` column option with a default value of `1`. + +
+ +##### getInitialState + +The `getInitialState` method in a table feature is responsible for setting the default state for that feature. For example, in the [Pagination](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/rowPaginationFeature.ts) feature, the `getInitialState` method sets the default `pageSize` state with a value of `10` and the default `pageIndex` state with a value of `0`. + +#### API Creators + +
+ +##### constructTable + +The `constructTable` method in a table feature is responsible for adding methods to the `table` instance. For example, in the [Row Selection](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/rowSelectionFeature.ts) feature, the `constructTable` method adds many table instance API methods such as `toggleAllRowsSelected`, `getIsAllRowsSelected`, `getIsSomeRowsSelected`, etc. So then, when you call `table.toggleAllRowsSelected()`, you are calling a method that was added to the table instance by the `rowSelectionFeature` feature. + +
+ +##### constructHeader + +The `constructHeader` method in a table feature is responsible for adding methods to the `header` instance. For example, in the [Column Sizing](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/columnSizingFeature.ts) feature, the `constructHeader` method adds many header instance API methods such as `getStart`, and many others. So then, when you call `header.getStart()`, you are calling a method that was added to the header instance by the `columnSizingFeature` feature. + +
+ +##### constructColumn + +The `constructColumn` method in a table feature is responsible for adding methods to the `column` instance. For example, in the [Sorting](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/rowSortingFeature.ts) feature, the `constructColumn` method adds many column instance API methods such as `getNextSortingOrder`, `toggleSorting`, etc. So then, when you call `column.toggleSorting()`, you are calling a method that was added to the column instance by the `rowSortingFeature` feature. + +
+ +##### constructRow + +The `constructRow` method in a table feature is responsible for adding methods to the `row` instance. For example, in the [Row Selection](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/rowSelectionFeature.ts) feature, the `constructRow` method adds many row instance API methods such as `toggleSelected`, `getIsSelected`, etc. So then, when you call `row.toggleSelected()`, you are calling a method that was added to the row instance by the `rowSelectionFeature` feature. + +
+ +##### constructCell + +The `constructCell` method in a table feature is responsible for adding methods to the `cell` instance. For example, in the [Column Grouping](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/columnGroupingFeature.ts) feature, the `constructCell` method adds many cell instance API methods such as `getIsGrouped`, `getIsAggregated`, etc. So then, when you call `cell.getIsGrouped()`, you are calling a method that was added to the cell instance by the `columnGroupingFeature` feature. + +### Adding a Custom Feature + +Let's walk through making a custom table feature for a hypothetical use case. Let's say we want to add a feature to the table instance that allows the user to change the "density" (padding of cells) of the table. + +Check out the full [custom-features](../framework/react/examples/custom-features) example to see the full implementation, but here's an in-depth look at the steps to create a custom feature. + +#### Step 1: Set up TypeScript Types + +Assuming you want the same full type-safety that the built-in features in TanStack Table have, let's set up all of the TypeScript types for our new feature. We'll create types for new table options, state, and table instance API methods. + +These types are following the naming convention used internally within TanStack Table, but you can name them whatever you want. We are not adding these types to TanStack Table yet, but we'll do that in the next step. + +```ts +// define types for our new feature's custom state +export type DensityState = 'sm' | 'md' | 'lg' +export interface DensityTableState { + density: DensityState +} + +// define types for our new feature's table options +export interface DensityOptions { + enableDensity?: boolean + onDensityChange?: OnChangeFn +} + +// Define types for our new feature's table APIs +export interface DensityInstance { + setDensity: (updater: Updater) => void + toggleDensity: (value?: DensityState) => void +} +``` + +#### Step 2: Use Declaration Merging to Add New Types to TanStack Table + +We can tell TypeScript to modify the exported types from TanStack Table to include our new feature's types. This is called "declaration merging" and it's a powerful feature of TypeScript. This way, we should not have to use any TypeScript hacks such as `as unknown as CustomTable` or `// @ts-ignore` in our new feature's code or in our application code. + +```ts +// Use declaration merging to add our new feature APIs and state types to TanStack Table's existing types. +declare module '@tanstack/react-table' { // or whatever framework adapter you are using + //merge our new feature's state with the existing table state + interface TableState extends DensityTableState {} + //merge our new feature's options with the existing table options + interface TableOptions + extends DensityOptions {} + //merge our new feature's instance APIs with the existing table instance APIs + interface Table extends DensityInstance {} + // if you need to add cell instance APIs... + // interface Cell extends DensityCell + // if you need to add row instance APIs... + // interface Row extends DensityRow + // if you need to add column instance APIs... + // interface Column extends DensityColumn + // if you need to add header instance APIs... + // interface Header extends DensityHeader + + // Note: declaration merging on `ColumnDef` is not possible because it is a complex type, not an interface. + // But you can still use declaration merging on `ColumnDef.meta` +} +``` + +Once we do this correctly, we should have no TypeScript errors when we try to both create our new feature's code and use it in our application. + +##### Caveats of Using Declaration Merging + +One caveat of using declaration merging is that it will affect the TanStack Table types for every table across your codebase. This is not a problem if you plan on loading the same feature set for every table in your application, but it could be a problem if some of your tables load extra features and some do not. Alternatively, you can just make a bunch of custom types that extend off of the TanStack Table types with your new features added. This is what [Material React Table](https://github.com/KevinVandy/material-react-table/blob/v2/packages/material-react-table/src/types.ts) does in order to avoid affecting the types of vanilla TanStack Table tables, but it's a bit more tedious, and requires a lot of type casting at certain points. + +#### Step 3: Create the Feature Object + +With all of that TypeScript setup out of the way, we can now create the feature object for our new feature. This is where we define all of the methods that will be added to the table instance. + +Use the `TableFeature` type to ensure that you are creating the feature object correctly. If the TypeScript types are set up correctly, you should have no TypeScript errors when you create the feature object with the new state, options, and instance APIs. + +```ts +export const DensityFeature: TableFeature = { //Use the TableFeature type!! + // define the new feature's initial state + getInitialState: (state): DensityTableState => { + return { + density: 'md', + ...state, + } + }, + + // define the new feature's default options + getDefaultTableOptions: ( + table: Partial> + ): DensityOptions => { + return { + enableDensity: true, + onDensityChange: makeStateUpdater('density', table), + } as DensityOptions + }, + // if you need to add a default column definition... + // getDefaultColumnDef: (): Partial> => { + // return { meta: {} } //use meta instead of directly adding to the columnDef to avoid typescript stuff that's hard to workaround + // }, + + // define the new feature's table instance methods + constructTable: (table: Table): void => { + table.setDensity = updater => { + const safeUpdater: Updater = old => { + let newState = functionalUpdate(updater, old) + return newState + } + return table.options.onDensityChange?.(safeUpdater) + } + table.toggleDensity = value => { + table.setDensity(old => { + if (value) return value + return old === 'lg' ? 'md' : old === 'md' ? 'sm' : 'lg' //cycle through the 3 options + }) + } + }, + + // if you need to add row instance APIs... + // constructRow: (row, table): void => {}, + // if you need to add cell instance APIs... + // constructCell: (cell, column, row, table): void => {}, + // if you need to add column instance APIs... + // constructColumn: (column, table): void => {}, + // if you need to add header instance APIs... + // constructHeader: (header, table): void => {}, +} +``` + +#### Step 4: Add the Feature to the Table + +Now that we have our feature object, we can add it to the table instance by including it in the `tableFeatures()` call and passing the result to the `_features` option when we create the table instance. + +```ts +const _features = tableFeatures({ DensityFeature }) + +const table = useTable({ + _features, + _rowModels: {}, + columns, + data, + //.. +}) +``` + +#### Step 5: Use the Feature in Your Application + +Now that the feature is added to the table instance, you can use the new instance APIs options, and state in your application. + +```tsx +const _features = tableFeatures({ DensityFeature }) + +const table = useTable({ + _features, + _rowModels: {}, + columns, + data, + //... + state: { + density, + }, + onDensityChange: setDensity, +}) +//... +const { density } = table.store.state +return( +
+ {flexRender(cell.column.columnDef.cell, cell.getContext())} +
...
; +} +``` + +`React.useState` and `React.useMemo` are not the only ways to give your data a stable reference. You can also define your data outside of the component or use a 3rd party state management library like Redux, Zustand, or TanStack Query. + +The main thing to avoid is defining the `data` array inside the same scope as the `useTable` call. That will cause the `data` array to be redefined on every render, which will cause an infinite loop of re-renders. + +```tsx +export default function MyComponent() { + //😵 BAD: This will cause an infinite loop of re-renders because `columns` is redefined as a new array on every render! + const columns = [ + // ... + ]; + + //😵 BAD: This will cause an infinite loop of re-renders because `data` is redefined as a new array on every render! + const data = [ + // ... + ]; + + //❌ Columns and data are defined in the same scope as `useTable` without a stable reference, will cause infinite loop! + const table = useTable({ + _features: tableFeatures({}), //❌ Also re-created on every render + _rowModels: {}, + columns, + data ?? [], //❌ Also bad because the fallback array is re-created on every render + }); + + return ...
; +} +``` + +### How TanStack Table Transforms Data + +Later, in other parts of these docs, you will see how TanStack Table processes the `data` that you pass to the table and generates the row and cell objects that are used to create the table. The `data` that you pass to the table is never mutated by TanStack Table, but the actual values in the rows and cells may be transformed by the accessors in your column definitions, or by other features performed by [row models](./row-models) like grouping or aggregation. + +### How Much Data Can TanStack Table Handle? + +Believe it or not, TanStack Table was actually built to scale up to handle potentially hundreds of thousands of rows of data in the client. This is obviously not always possible, depending on the size of each column's data and the number of columns. However, the sorting, filtering, pagination, and grouping features are all built with performance in mind for large datasets. + +The default mindset of a developer building a data grid is to implement server-side pagination, sorting, and filtering for large datasets. This is still usually a good idea, but a lot of developers underestimate how much data can actually be handled in the client with modern browsers and the right optimizations. If your table will never have more than a few thousand rows, you can probably take advantage of the client-side features in TanStack Table instead of implementing them yourself on the server. Before committing to letting TanStack Table's client-side features handle your large dataset, you should test it with your actual data to see if it performs well enough for your needs, of course. + +This is discussed in more detail in the [Pagination Guide](./pagination#should-you-use-client-side-pagination). diff --git a/docs/guide/expanding.md b/docs/guide/expanding.md new file mode 100644 index 0000000000..3d932f5be9 --- /dev/null +++ b/docs/guide/expanding.md @@ -0,0 +1,250 @@ +--- +title: Expanding Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [expanding](../framework/react/examples/expanding) +- [grouping](../framework/react/examples/grouping) +- [sub-components](../framework/react/examples/sub-components) + +## API + +[Expanding API](../api/features/expanding) + +## Expanding Feature Guide + +Expanding is a feature that allows you to show and hide additional rows of data related to a specific row. This can be useful in cases where you have hierarchical data and you want to allow users to drill down into the data from a higher level. Or it can be useful for showing additional information related to a row. + +### Different use cases for Expanding Features + +There are multiple use cases for expanding features in TanStack Table that will be discussed below. + +1. Expanding sub-rows (child rows, aggregate rows, etc.) +2. Expanding custom UI (detail panels, sub-tables, etc.) + +### Enable Client-Side Expanding + +To use the client-side expanding features, add the `rowExpandingFeature` to your features and the `expandedRowModel` to your row models: + +```ts +import { + useTable, + tableFeatures, + rowExpandingFeature, + createExpandedRowModel, +} from '@tanstack/react-table' + +const _features = tableFeatures({ rowExpandingFeature }) + +const table = useTable({ + _features, + _rowModels: { + expandedRowModel: createExpandedRowModel(), + }, + // other options... +}) +``` + +Expanded data can either contain table rows or any other data you want to display. We will discuss how to handle both cases in this guide. + +### Table rows as expanded data + +Expanded rows are essentially child rows that inherit the same column structure as their parent rows. If your data object already includes these expanded rows data, you can utilize the `getSubRows` function to specify these child rows. However, if your data object does not contain the expanded rows data, they can be treated as custom expanded data, which is discussed in next section. + +For example, if you have a data object like this: + +```ts +type Person = { + id: number + name: string + age: number + children?: Person[] | undefined +} + +const data: Person[] = [ + { id: 1, + name: 'John', + age: 30, + children: [ + { id: 2, name: 'Jane', age: 5 }, + { id: 5, name: 'Jim', age: 10 } + ] + }, + { id: 3, + name: 'Doe', + age: 40, + children: [ + { id: 4, name: 'Alice', age: 10 } + ] + }, +] +``` + +Then you can use the getSubRows function to return the children array in each row as expanded rows. The table instance will now understand where to look for the sub rows on each row. + +```ts +const table = useTable({ + _features, + _rowModels: { + expandedRowModel: createExpandedRowModel(), + }, + getSubRows: (row) => row.children, // return the children array as sub-rows + // other options... +}) +``` + +> **Note:** You can have a complicated `getSubRows` function, but keep in mind that it will run for every row and every sub-row. This can be expensive if the function is not optimized. Async functions are not supported. + +### Custom Expanding UI + +In some cases, you may wish to show extra details or information, which may or may not be part of your table data object, such as expanded data for rows. This kind of expanding row UI has gone by many names over the years including "expandable rows", "detail panels", "sub-components", etc. + +By default, the `row.getCanExpand()` row instance API will return false unless it finds `subRows` on a row. This can be overridden by implementing your own `getRowCanExpand` function in the table instance options. + +```ts +//... +const table = useTable({ + _features, + _rowModels: { + expandedRowModel: createExpandedRowModel(), + }, + getRowCanExpand: (row) => true, // Add your logic to determine if a row can be expanded. True means all rows include expanded data + // other options... +}) +//... + + {table.getRowModel().rows.map((row) => ( + + {/* Normal row UI */} + + {row.getVisibleCells().map((cell) => ( + + {flexRender(cell.column.columnDef.cell, cell.getContext())} + + ))} + + {/* If the row is expanded, render the expanded UI as a separate row with a single cell that spans the width of the table */} + {row.getIsExpanded() && ( + + // The number of columns you wish to span for the expanded data if it is not a row that shares the same columns as the parent row + // Your custom UI goes here + + + )} + + ))} + +//... +``` + +### Expanded rows state + +If you need to control the expanded state of the rows in your table, you can do so by using the expanded state and the `onExpandedChange` option. This allows you to manage the expanded state according to your requirements. + +```ts +const [expanded, setExpanded] = useState({}) + +const table = useTable({ + _features, + _rowModels: { expandedRowModel: createExpandedRowModel() }, + // other options... + state: { + expanded, + }, + onExpandedChange: setExpanded, +}) +``` + +The ExpandedState type is defined as follows: + +```ts +type ExpandedState = true | Record +``` + +If the ExpandedState is true, it means all rows are expanded. If it's a record, only the rows with IDs present as keys in the record and have their value set to true are expanded. For example, if the expanded state is { row1: true, row2: false }, it means the row with ID row1 is expanded and the row with ID row2 is not expanded. This state is used by the table to determine which rows are expanded and should display their subRows, if any. + +### UI toggling handler for expanded rows + +TanStack table will not add a toggling handler UI for expanded data to your table. You should manually add it within each row's UI to allow users to expand and collapse the row. For example, you can add a button UI within the columns definition. + +```ts +const columns = [ + { + accessorKey: 'name', + header: 'Name', + }, + { + accessorKey: 'age', + header: 'Age', + }, + { + header: 'Children', + cell: ({ row }) => { + return row.getCanExpand() ? + + : ''; + }, + }, +] +``` + +### Filtering Expanded Rows + +By default, the filtering process starts from the parent rows and moves downwards. This means if a parent row is excluded by the filter, all its child rows will also be excluded. However, you can change this behavior by using the `filterFromLeafRows` option. When this option is enabled, the filtering process starts from the leaf (child) rows and moves upwards. This ensures that a parent row will be included in the filtered results as long as at least one of its child or grandchild rows meets the filter criteria. Additionally, you can control how deep into the child hierarchy the filter process goes by using the `maxLeafRowFilterDepth` option. This option allows you to specify the maximum depth of child rows that the filter should consider. + +```ts +//... +const table = useTable({ + _features: tableFeatures({ columnFilteringFeature, rowExpandingFeature }), + _rowModels: { + filteredRowModel: createFilteredRowModel(filterFns), + expandedRowModel: createExpandedRowModel(), + }, + getSubRows: (row) => row.subRows, + filterFromLeafRows: true, // search through the expanded rows + maxLeafRowFilterDepth: 1, // limit the depth of the expanded rows that are searched + // other options... +}) +``` + +### Paginating Expanded Rows + +By default, expanded rows are paginated along with the rest of the table (which means expanded rows may span multiple pages). If you want to disable this behavior (which means expanded rows will always render on their parents page. This also means more rows will be rendered than the set page size) you can use the `paginateExpandedRows` option. + +```ts +const table = useTable({ + _features, + _rowModels: { expandedRowModel: createExpandedRowModel() }, + // other options... + paginateExpandedRows: false, +}) +``` + +### Pinning Expanded Rows + +Pinning expanded rows works the same way as pinning regular rows. You can pin expanded rows to the top or bottom of the table. Please refer to the [Pinning Guide](./pinning.md) for more information on row pinning. + +### Sorting Expanded Rows + +By default, expanded rows are sorted along with the rest of the table. + +### Manual Expanding (server-side) + +If you are doing server-side expansion, you can enable manual row expansion by setting the manualExpanding option to true. This means that the `getExpandedRowModel` will not be used to expand rows and you would be expected to perform the expansion in your own data model. + +```ts +const table = useTable({ + _features: tableFeatures({ rowExpandingFeature }), + _rowModels: {}, // no expandedRowModel needed for manual expanding + // other options... + manualExpanding: true, +}) +``` diff --git a/docs/guide/features.md b/docs/guide/features.md new file mode 100644 index 0000000000..97d850b690 --- /dev/null +++ b/docs/guide/features.md @@ -0,0 +1,23 @@ +--- +title: Features Guide +--- + +TanStack Table comes with many features, each with their own associated options and API. + +> **v9 note:** In v9, features are opt-in. You declare which features your table uses via the `_features` option (using `tableFeatures()`). This enables tree-shaking—you only bundle the code for the features you need. See the [Table Instance Guide](./tables) and [Row Models Guide](./row-models) for setup. To include all features (v8-style), use `stockFeatures`. + +- [Column Ordering](./column-ordering) +- [Column Pinning](./column-pinning) +- [Column Sizing](./column-sizing) +- [Column Visibility](./column-visibility) +- [Expanding](./expanding) +- [Column Faceting](./column-faceting) +- [Column Filtering](./column-filtering) +- [Global Faceting](./global-faceting) +- [Global Filtering](./global-filtering) +- [Grouping](./grouping) +- [Pagination](./pagination) +- [Row Pinning](./row-pinning) +- [Row Selection](./row-selection) +- [Sorting](./sorting) +- [Virtualization](./virtualization) \ No newline at end of file diff --git a/docs/guide/filters.md b/docs/guide/filters.md new file mode 100644 index 0000000000..8d10bda84e --- /dev/null +++ b/docs/guide/filters.md @@ -0,0 +1,13 @@ +--- +title: Filters Guide +--- + + + +The filter guides are now split into multiple guides: + +- [Column Filtering](./column-filtering) +- [Global Filtering](./global-filtering) +- [Fuzzy Filtering](./fuzzy-filtering) +- [Column Faceting](./column-faceting) +- [Global Faceting](./global-faceting) \ No newline at end of file diff --git a/docs/guide/fuzzy-filtering.md b/docs/guide/fuzzy-filtering.md new file mode 100644 index 0000000000..46f9277897 --- /dev/null +++ b/docs/guide/fuzzy-filtering.md @@ -0,0 +1,139 @@ +--- +title: Fuzzy Filtering Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [filters-fuzzy](../framework/react/examples/filters-fuzzy) + +## API + +[Filters API](../api/features/filters) + +## Fuzzy Filtering Guide + +Fuzzy filtering is a technique that allows you to filter data based on approximate matches. This can be useful when you want to search for data that is similar to a given value, rather than an exact match. + +You can implement a client side fuzzy filtering by defining a custom filter function. This function should take in the row, columnId, and filter value, and return a boolean indicating whether the row should be included in the filtered data. + +Fuzzy filtering is mostly used with global filtering, but you can also apply it to individual columns. We will discuss how to implement fuzzy filtering for both cases. + +> **Note:** You will need to install the `@tanstack/match-sorter-utils` library to use fuzzy filtering. +> TanStack Match Sorter Utils is a fork of [match-sorter](https://github.com/kentcdodds/match-sorter) by Kent C. Dodds. It was forked in order to work better with TanStack Table's row by row filtering approach. + +Using the match-sorter libraries is optional, but the TanStack Match Sorter Utils library provides a great way to both fuzzy filter and sort by the rank information it returns, so that rows can be sorted by their closest matches to the search query. + +### Defining a Custom Fuzzy Filter Function + +Here's an example of a custom fuzzy filter function: + +```typescript +import { rankItem } from '@tanstack/match-sorter-utils'; +import { FilterFn } from '@tanstack/table'; + +const fuzzyFilter: FilterFn = (row, columnId, value, addMeta) => { + // Rank the item + const itemRank = rankItem(row.getValue(columnId), value) + + // Store the itemRank info + addMeta({ itemRank }) + + // Return if the item should be filtered in/out + return itemRank.passed +} +``` + +In this function, we're using the rankItem function from the @tanstack/match-sorter-utils library to rank the item. We then store the ranking information in the meta data of the row, and return whether the item passed the ranking criteria. + +### Using Fuzzy Filtering with Global Filtering + +To use fuzzy filtering with global filtering, you can specify the fuzzy filter function in the globalFilterFn option of the table instance: + +```typescript +import { + useTable, + tableFeatures, + globalFilteringFeature, + rowSortingFeature, + createFilteredRowModel, + createSortedRowModel, + filterFns, + sortFns, +} from '@tanstack/react-table' + +const _features = tableFeatures({ globalFilteringFeature, rowSortingFeature }) + +const table = useTable({ + _features, + _rowModels: { + filteredRowModel: createFilteredRowModel({ + ...filterFns, + fuzzy: fuzzyFilter, + }), + sortedRowModel: createSortedRowModel(sortFns), // needed if you want sorting with fuzzy rank + }, + columns, + data, + globalFilterFn: 'fuzzy', +}) +``` + +### Using Fuzzy Filtering with Column Filtering + +To use fuzzy filtering with column filtering, pass your fuzzy filter function to `createFilteredRowModel` (merging it with the built-in `filterFns`). You can then specify the fuzzy filter by name in the `filterFn` option of the column definition: + +```typescript +const column = [ + { + accessorFn: row => `${row.firstName} ${row.lastName}`, + id: 'fullName', + header: 'Full Name', + cell: info => info.getValue(), + filterFn: 'fuzzy', //using our custom fuzzy filter function + }, + // other columns... +]; +``` + +In this example, we're applying the fuzzy filter to a column that combines the firstName and lastName fields of the data. + +#### Sorting with Fuzzy Filtering + +When using fuzzy filtering with column filtering, you might also want to sort the data based on the ranking information. You can do this by defining a custom sorting function: + +```typescript +import { compareItems } from '@tanstack/match-sorter-utils' +import { sortFns } from '@tanstack/table' + +const fuzzySort: SortFn = (rowA, rowB, columnId) => { + let dir = 0 + + // Only sort by rank if the column has ranking information + if (rowA.columnFiltersMeta[columnId]) { + dir = compareItems( + rowA.columnFiltersMeta[columnId]?.itemRank!, + rowB.columnFiltersMeta[columnId]?.itemRank! + ) + } + + // Provide an alphanumeric fallback for when the item ranks are equal + return dir === 0 ? sortFns.alphanumeric(rowA, rowB, columnId) : dir +} +``` + +In this function, we're comparing the ranking information of the two rows. If the ranks are equal, we fall back to alphanumeric sorting. + +You can then specify this sorting function in the sortFn option of the column definition: + +```typescript +{ + accessorFn: row => `${row.firstName} ${row.lastName}`, + id: 'fullName', + header: 'Full Name', + cell: info => info.getValue(), + filterFn: 'fuzzy', //using our custom fuzzy filter function + sortFn: 'fuzzySort', //using our custom fuzzy sort function +} +``` diff --git a/docs/guide/global-faceting.md b/docs/guide/global-faceting.md new file mode 100644 index 0000000000..caac1de6d4 --- /dev/null +++ b/docs/guide/global-faceting.md @@ -0,0 +1,82 @@ +--- +title: Global Faceting Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [filters-faceted](../framework/react/examples/filters) + +## API + +[Global Faceting API](../api/features/global-faceting) + +## Global Faceting Guide + +Global Faceting allows you to generate lists of values for all columns from the table's data. For example, a list of unique values in a table can be generated from all rows in all columns to be used as search suggestions in an autocomplete filter component. Or, a tuple of minimum and maximum values can be generated from a table of numbers to be used as a range for a range slider filter component. + +### Global Faceting Row Models + +In order to use any of the global faceting features, add the appropriate faceted row models to your `_rowModels`: + +```ts +import { + useTable, + tableFeatures, + createFacetedRowModel, + createFacetedMinMaxValues, + createFacetedUniqueValues, +} from '@tanstack/react-table' + +const _features = tableFeatures({}) // add globalFilteringFeature if using global filtering + +const table = useTable({ + _features, + _rowModels: { + facetedRowModel: createFacetedRowModel(), // required (other faceting methods depend on this) + facetedMinMaxValues: createFacetedMinMaxValues(), // if you need min/max values + facetedUniqueValues: createFacetedUniqueValues(), // if you need a list of unique values + }, + // other options... +}) +``` + +### Use Global Faceted Row Models + +Once you have included the appropriate row models in your table options, you will be able to use the faceting table instance APIs to access the lists of values generated by the faceted row models. + +```ts +// list of unique values for autocomplete filter +const autoCompleteSuggestions = + Array.from(table.getGlobalFacetedUniqueValues().keys()) + .sort() + .slice(0, 5000); +``` + +```ts +// tuple of min and max values for range filter +const [min, max] = table.getGlobalFacetedMinMaxValues() ?? [0, 1]; +``` + +### Custom Global (Server-Side) Faceting + +If instead of using the built-in client-side faceting features, you can implement your own faceting logic on the server-side and pass the faceted values to the client-side. You can use the getGlobalFacetedUniqueValues and getGlobalFacetedMinMaxValues table options to resolve the faceted values from the server-side. + +```ts +const facetingQuery = useQuery( + 'faceting', + async () => { + const response = await fetch('/api/faceting'); + return response.json(); + }, + { + onSuccess: (data) => { + table.getGlobalFacetedUniqueValues = () => data.uniqueValues; + table.getGlobalFacetedMinMaxValues = () => data.minMaxValues; + }, + } +); +``` + +In this example, we use the `useQuery` hook from `react-query` to fetch faceting data from the server. Once the data is fetched, we set the `getGlobalFacetedUniqueValues` and `getGlobalFacetedMinMaxValues` table options to return the faceted values from the server response. This will allow the table to use the server-side faceting data for generating autocomplete suggestions and range filters. diff --git a/docs/guide/global-filtering.md b/docs/guide/global-filtering.md new file mode 100644 index 0000000000..89cadec111 --- /dev/null +++ b/docs/guide/global-filtering.md @@ -0,0 +1,226 @@ +--- +title: Global Filtering Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [Global Filters](../framework/react/examples/filters-global) + +## API + +[Global Filtering API](../api/features/global-filtering) + +## Global Filtering Guide + +Filtering comes in 2 flavors: Column Filtering and Global Filtering. + +This guide will focus on global filtering, which is a filter that is applied across all columns. + +### Client-Side vs Server-Side Filtering + +If you have a large dataset, you may not want to load all of that data into the client's browser in order to filter it. In this case, you will most likely want to implement server-side filtering, sorting, pagination, etc. + +However, as also discussed in the [Pagination Guide](./pagination#should-you-use-client-side-pagination), a lot of developers underestimate how many rows can be loaded client-side without a performance hit. The TanStack table examples are often tested to handle up to 100,000 rows or more with decent performance for client-side filtering, sorting, pagination, and grouping. This doesn't necessarily mean that your app will be able to handle that many rows, but if your table is only going to have a few thousand rows at most, you might be able to take advantage of the client-side filtering, sorting, pagination, and grouping that TanStack table provides. + +> TanStack Table can handle thousands of client-side rows with good performance. Don't rule out client-side filtering, pagination, sorting, etc. without some thought first. + +Every use-case is different and will depend on the complexity of the table, how many columns you have, how large every piece of data is, etc. The main bottlenecks to pay attention to are: + +1. Can your server query all of the data in a reasonable amount of time (and cost)? +2. What is the total size of the fetch? (This might not scale as badly as you think if you don't have many columns.) +3. Is the client's browser using too much memory if all of the data is loaded at once? + +If you're not sure, you can always start with client-side filtering and pagination and then switch to server-side strategies in the future as your data grows. + +### Manual Server-Side Global Filtering + +If you have decided that you need to implement server-side global filtering instead of using the built-in client-side global filtering, here's how you do that. + +No `filteredRowModel` is needed for manual server-side global filtering. Instead, the `data` that you pass to the table should already be filtered. However, if you have added a `filteredRowModel` to `_rowModels`, you can tell the table to skip it by setting the `manualFiltering` option to `true`. + +```jsx +import { + useTable, + tableFeatures, + globalFilteringFeature, +} from '@tanstack/react-table' + +const _features = tableFeatures({ globalFilteringFeature }) + +const table = useTable({ + _features, + _rowModels: {}, // no filteredRowModel needed for manual server-side global filtering + data, + columns, + manualFiltering: true, +}) +``` + +Note: When using manual global filtering, many of the options that are discussed in the rest of this guide will have no effect. When manualFiltering is set to true, the table instance will not apply any global filtering logic to the rows that are passed to it. Instead, it will assume that the rows are already filtered and will use the data that you pass to it as-is. + +### Client-Side Global Filtering + +If you are using the built-in client-side global filtering, add the `globalFilteringFeature` to your features and the `filteredRowModel` to your row models: + +```jsx +import { + useTable, + tableFeatures, + globalFilteringFeature, + createFilteredRowModel, + filterFns, +} from '@tanstack/react-table' + +const _features = tableFeatures({ globalFilteringFeature }) + +const table = useTable({ + _features, + _rowModels: { + filteredRowModel: createFilteredRowModel(filterFns), + }, + // other options... +}) +``` + +### Global Filter Function + +The globalFilterFn option allows you to specify the filter function that will be used for global filtering. The filter function can be a string that references a built-in filter function, a string that references a custom filter function provided via the tableOptions.filterFns option, or a custom filter function. + +```jsx +const table = useTable({ + _features, + _rowModels: { + filteredRowModel: createFilteredRowModel(filterFns), + }, + data, + columns, + globalFilterFn: 'text', // built-in filter function +}) +``` + +By default there are 10 built-in filter functions to choose from: + +- includesString - Case-insensitive string inclusion +- includesStringSensitive - Case-sensitive string inclusion +- equalsString - Case-insensitive string equality +- equalsStringSensitive - Case-sensitive string equality +- arrIncludes - Item inclusion within an array +- arrIncludesAll - All items included in an array +- arrIncludesSome - Some items included in an array +- equals - Object/referential equality Object.is/=== +- weakEquals - Weak object/referential equality == +- inNumberRange - Number range inclusion + +You can also define your own custom filter functions either as the globalFilterFn table option. + +### Global Filter State + +The global filter state is stored in the table's internal state and can be accessed via the table.store.state.globalFilter property. If you want to persist the global filter state outside of the table, you can use the onGlobalFilterChange option to provide a callback function that will be called whenever the global filter state changes. + +```jsx +const [globalFilter, setGlobalFilter] = useState([]) + +const table = useTable({ + _features, + _rowModels: { filteredRowModel: createFilteredRowModel(filterFns) }, + // other options... + state: { + globalFilter, + }, + onGlobalFilterChange: setGlobalFilter, +}) +``` + +The global filtering state is defined as an object with the following shape: + +```jsx +interface GlobalFilter { + globalFilter: any +} +``` + +### Adding global filter input to UI + +TanStack table will not add a global filter input UI to your table. You should manually add it to your UI to allow users to filter the table. For example, you can add an input UI above the table to allow users to enter a search term. + +```jsx +return ( +
+ table.setGlobalFilter(String(e.target.value))} + placeholder="Search..." + /> +
+) +``` + +### Custom Global Filter Function + +If you want to use a custom global filter function, you can define the function and pass it to the globalFilterFn option. + +> **Note:** It is often a popular idea to use fuzzy filtering functions for global filtering. This is discussed in the [Fuzzy Filtering Guide](./fuzzy-filtering.md). + +```jsx +const customFilterFn = (rows, columnId, filterValue) => { + // custom filter logic +} + +const table = useTable({ + _features, + _rowModels: { filteredRowModel: createFilteredRowModel(filterFns) }, + // other options... + globalFilterFn: customFilterFn, +}) +``` + +### Initial Global Filter State + +If you want to set an initial global filter state when the table is initialized, you can pass the global filter state as part of the table initialState option. + +However, you can also just specify the initial global filter state in the state.globalFilter option. + +```jsx +const [globalFilter, setGlobalFilter] = useState("search term") //recommended to initialize globalFilter state here + +const table = useTable({ + _features, + _rowModels: { filteredRowModel: createFilteredRowModel(filterFns) }, + // other options... + initialState: { + globalFilter: 'search term', // if not managing globalFilter state, set initial state here + }, + state: { + globalFilter, // pass our managed globalFilter state to the table + }, +}) +``` + +> NOTE: Do not use both initialState.globalFilter and state.globalFilter at the same time, as the initialized state in the state.globalFilter will override the initialState.globalFilter. + +### Disable Global Filtering + +By default, global filtering is enabled for all columns. You can disable the global filtering for all columns by using the enableGlobalFilter table option. You can also turn off both column and global filtering by setting the enableFilters table option to false. + +Disabling global filtering will cause the column.getCanGlobalFilter API to return false for that column. + +```jsx +const columns = [ + { + header: () => 'Id', + accessorKey: 'id', + enableGlobalFilter: false, // disable global filtering for this column + }, + //... +] +//... +const table = useTable({ + _features, + _rowModels: { filteredRowModel: createFilteredRowModel(filterFns) }, + // other options... + columns, + enableGlobalFilter: false, // disable global filtering for all columns +}) +``` diff --git a/docs/guide/grouping.md b/docs/guide/grouping.md new file mode 100644 index 0000000000..23287ed112 --- /dev/null +++ b/docs/guide/grouping.md @@ -0,0 +1,171 @@ +--- +title: Grouping Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [grouping](../framework/react/examples/grouping) + +## API + +[Grouping API](../api/features/grouping) + +## Grouping Guide + +There are 3 table features that can reorder columns, which happen in the following order: + +1. [Column Pinning](./column-pinning) - If pinning, columns are split into left, center (unpinned), and right pinned columns. +2. Manual [Column Ordering](./column-ordering) - A manually specified column order is applied. +3. **Grouping** - If grouping is enabled, a grouping state is active, and `tableOptions.groupedColumnMode` is set to `'reorder' | 'remove'`, then the grouped columns are reordered to the start of the column flow. + +Grouping in TanStack table is a feature that applies to columns and allows you to categorize and organize the table rows based on specific columns. This can be useful in cases where you have a large amount of data and you want to group them together based on certain criteria. + +To use the grouping feature, add the `columnGroupingFeature` to your features and the `groupedRowModel` to your row models. The grouped row model is responsible for grouping the rows based on the grouping state. + +```tsx +import { + useTable, + tableFeatures, + columnGroupingFeature, + createGroupedRowModel, + aggregationFns, +} from '@tanstack/react-table' + +const _features = tableFeatures({ columnGroupingFeature }) + +const table = useTable({ + _features, + _rowModels: { + groupedRowModel: createGroupedRowModel(aggregationFns), + }, + // other options... +}) +``` + +When grouping state is active, the table will add matching rows as subRows to the grouped row. The grouped row will be added to the table rows at the same index as the first matching row. The matching rows will be removed from the table rows. +To allow the user to expand and collapse the grouped rows, you can use the expanding feature. + +```tsx +const _features = tableFeatures({ columnGroupingFeature, rowExpandingFeature }) + +const table = useTable({ + _features, + _rowModels: { + groupedRowModel: createGroupedRowModel(aggregationFns), + expandedRowModel: createExpandedRowModel(), + }, + // other options... +}) +``` + +### Grouping state + +The grouping state is an array of strings, where each string is the ID of a column to group by. The order of the strings in the array determines the order of the grouping. For example, if the grouping state is ['column1', 'column2'], then the table will first group by column1, and then within each group, it will group by column2. You can control the grouping state using the setGrouping function: + +```tsx +table.setGrouping(['column1', 'column2']); +``` + +You can also reset the grouping state to its initial state using the resetGrouping function: + +```tsx +table.resetGrouping(); +``` + +By default, when a column is grouped, it is moved to the start of the table. You can control this behavior using the groupedColumnMode option. If you set it to 'reorder', then the grouped columns will be moved to the start of the table. If you set it to 'remove', then the grouped columns will be removed from the table. If you set it to false, then the grouped columns will not be moved or removed. + +```tsx +const table = useTable({ + _features, + _rowModels: { groupedRowModel: createGroupedRowModel(aggregationFns) }, + // other options... + groupedColumnMode: 'reorder', +}) +``` + +### Aggregations + +When rows are grouped, you can aggregate the data in the grouped rows by columns using the aggregationFn option. This is a string that is the ID of the aggregation function. You can define the aggregation functions using the aggregationFns option. + +```tsx +const column = columnHelper.accessor('key', { + aggregationFn: 'sum', +}) +``` + +In the above example, the sum aggregation function will be used to aggregate the data in the grouped rows. +By default, numeric columns will use the sum aggregation function, and non-numeric columns will use the count aggregation function. You can override this behavior by specifying the aggregationFn option in the column definition. + +There are several built-in aggregation functions that you can use: + +- sum - Sums the values in the grouped rows. +- count - Counts the number of rows in the grouped rows. +- min - Finds the minimum value in the grouped rows. +- max - Finds the maximum value in the grouped rows. +- extent - Finds the extent (min and max) of the values in the grouped rows. +- mean - Finds the mean of the values in the grouped rows. +- median - Finds the median of the values in the grouped rows. +- unique - Returns an array of unique values in the grouped rows. +- uniqueCount - Counts the number of unique values in the grouped rows. + +#### Custom Aggregations + +When rows are grouped, you can aggregate the data in the grouped rows using the aggregationFns option. This is a record where the keys are the IDs of the aggregation functions, and the values are the aggregation functions themselves. You can then reference these aggregation functions in a column's aggregationFn option. + +```tsx +const table = useTable({ + _features, + _rowModels: { + groupedRowModel: createGroupedRowModel({ + ...aggregationFns, + myCustomAggregation: (columnId, leafRows, childRows) => { + // return the aggregated value + }, + }), + }, + // other options... +}) +``` + +In the above example, myCustomAggregation is a custom aggregation function that takes the column ID, the leaf rows, and the child rows, and returns the aggregated value. You can then use this aggregation function in a column's aggregationFn option: + +```tsx +const column = columnHelper.accessor('key', { + aggregationFn: 'myCustomAggregation', +}) +``` + +### Manual Grouping + +If you are doing server-side grouping and aggregation, you can enable manual grouping using the manualGrouping option. When this option is set to true, the table will not automatically group rows using getGroupedRowModel() and instead will expect you to manually group the rows before passing them to the table. + +```tsx +const table = useTable({ + _features: tableFeatures({ columnGroupingFeature }), + _rowModels: {}, // no groupedRowModel needed for manual grouping + // other options... + manualGrouping: true, +}) +``` + +> **Note:** There are not currently many known easy ways to do server-side grouping with TanStack Table. You will need to do lots of custom cell rendering to make this work. + +### Grouping Change Handler + +If you want to manage the grouping state yourself, you can use the onGroupingChange option. This option is a function that is called when the grouping state changes. You can pass the managed state back to the table via the tableOptions.state.grouping option. + +```tsx +const [grouping, setGrouping] = useState([]) + +const table = useTable({ + _features, + _rowModels: { groupedRowModel: createGroupedRowModel(aggregationFns) }, + // other options... + state: { + grouping, + }, + onGroupingChange: setGrouping, +}) +``` diff --git a/docs/guide/header-groups.md b/docs/guide/header-groups.md new file mode 100644 index 0000000000..f98a0ff0d0 --- /dev/null +++ b/docs/guide/header-groups.md @@ -0,0 +1,49 @@ +--- +title: Header Groups Guide +--- + +## API + +[Header Group API](../api/core/header-group) + +## Header Groups Guide + +This quick guide will discuss the different ways you can retrieve and interact with header group objects in TanStack Table. + +### What are Header Groups? + +Header Groups are simply "rows" of headers. Don't let the name confuse you, it's just that simple. The large majority of tables will only have one row of headers (a single header group), but if you define your column structure with nested columns as with the [Column Groups example](../framework/react/examples/column-groups), you can have multiple rows of headers (multiple header groups). + +### Where to Get Header Groups From + +There are multiple `table` instance APIs you can use to retrieve header groups from the table instance. `table.getHeaderGroups` is the most common API to use, but depending on the features that you are using, you may need to use other APIs, such as `table.get[Left/Center/Right]HeaderGroups` if you are using column pinning features. + +### Header Group Objects + +Header Group objects are similar to [Row](./rows) objects, though simpler since there is not as much going on in header rows as there are in the body rows. + +By default, header groups only have three properties: + +- `id`: The unique identifier for the header group that is generated from its depth (index). This is useful as a key for React components. +- `depth`: The depth of the header group, zero-indexed based. Think of this as the row index amongst all header rows. +- `headers`: An array of [Header](./headers) cell objects that belong to this header group (row). + +### Access Header Cells + +To render the header cells in a header group, you just map over the `headers` array from the header group object. + +```jsx + + {table.getHeaderGroups().map(headerGroup => { + return ( + + {headerGroup.headers.map(header => ( // map over the headerGroup headers array + + {/* */} + + ))} + + ) + })} + +``` \ No newline at end of file diff --git a/docs/guide/headers.md b/docs/guide/headers.md new file mode 100644 index 0000000000..9760568865 --- /dev/null +++ b/docs/guide/headers.md @@ -0,0 +1,84 @@ +--- +title: Headers Guide +--- + +## API + +[Header API](../api/core/header) + +## Headers Guide + +This quick guide will discuss the different ways you can retrieve and interact with `header` objects in TanStack Table. + +Headers are the equivalent of cells, but meant for the `` section of the table instead of the `` section. + +### Where to Get Headers From + +Headers come from [Header Groups](./header-groups), which are the equivalent of rows, but meant for the `` section of the table instead of the `` section. + +#### HeaderGroup Headers + +If you are in a header group, the headers are stored as an array in the `headerGroup.headers` property. Usually you will just map over this array to render your headers. + +```jsx + + {table.getHeaderGroups().map(headerGroup => { + return ( + + {headerGroup.headers.map(header => ( // map over the headerGroup headers array + + {/* */} + + ))} + + ) + })} + +``` + +#### Header Table Instance APIs + +There are multiple `table` instance APIs that you can use to retrieve a list of headers depending on the features that you are using. The most common API you might use is `table.getFlatHeaders`, which will return a flat list of all headers in the table, but there are at least a dozen other headers that are useful in tandem with the column visibility and column pinning features. APIs like `table.getLeftLeafHeaders` or `table.getRightFlatHeaders` could be useful depending on your use case. + +### Header Objects + +Header objects are similar to [Cell](./cells) objects, but meant for the `` section of the table instead of the `` section. Every header object can be associated with a `` or similar cell element in your UI. There are a few properties and methods on `header` objects that you can use to interact with the table state and extract cell values from the table based on the state of the table. + +#### Header IDs + +Every header object has an `id` property that makes it unique within the table instance. Usually you only need this `id` as a unique identifier for React keys or if you are following the [performant column resizing example](../framework/react/examples/column-resizing-performant). + +For simple headers with no advanced nested or grouped headers logic, the `header.id` will be the same as it's parent `column.id`. However, if the header is part group column or a placeholder cell, it will have a more complicated id that is constructed from the header family, depth/header row index, column id, and header group id. + +#### Nested Grouped Headers Properties + +There are a few properties on `header` objects that are only useful if the header is part of a nested or grouped header structure. These properties include: + +- `colspan`: The number of columns that the header should span. This is useful for rendering the `colSpan` attribute on the `` element. +- `rowSpan`: The number of rows that the header should span. This is useful for rendering the `rowSpan` attribute on the `` element. (Currently not implemented in default TanStack Table) +- `depth`: The header group "row index" that the header group belongs to. +- `isPlaceholder`: A boolean flag that is true if the header is a placeholder header. Placeholder headers are used to fill in the gaps when a column is hidden or when a column is part of a group column. +- `placeholderId`: The unique identifier for the placeholder header. +- `subHeaders`: The array of sub/child headers that belong to this header. Will be empty if the header is a leaf header. + +> Note: `header.index` refers to its index within the header group (row of headers), i.e. its position from left to right. It is not the same as `header.depth`, which refers to the header group "row index". + +#### Header Parent Objects + +Every header stores a reference to its parent [column](./columns) object and its parent [header group](./header-groups) object. + +### More Header APIs + +Headers have a few more useful APIs attached to them that are useful for interacting with the table state. Most of them relate to the Column sizing and resizing features. See the [Column Resizing Guide](./column-resizing) for more information. + +### Header Rendering + +Since the `header` column option you defined can be either a string, jsx, or a function returning either of those, the best way to render the headers is to use the `flexRender` utility from your adapter, which will handle all of those cases for you. + +```jsx +{headerGroup.headers.map(header => ( + + {/* Handles all possible header column def scenarios for `header` */} + {flexRender(header.column.columnDef.header, header.getContext())} + +))} \ No newline at end of file diff --git a/docs/guide/pagination.md b/docs/guide/pagination.md new file mode 100644 index 0000000000..9c90e302ad --- /dev/null +++ b/docs/guide/pagination.md @@ -0,0 +1,251 @@ +--- +title: Pagination Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [pagination](../framework/react/examples/pagination) +- [pagination-controlled (React Query)](../framework/react/examples/pagination-controlled) +- [editable-data](../framework/react/examples/editable-data) +- [expanding](../framework/react/examples/expanding) +- [filters](../framework/react/examples/filters) +- [fully-controlled](../framework/react/examples/fully-controlled) +- [row-selection](../framework/react/examples/row-selection) + +## API + +[Pagination API](../api/features/pagination) + +## Pagination Guide + +TanStack Table has great support for both client-side and server-side pagination. This guide will walk you through the different ways to implement pagination in your table. + +### Client-Side Pagination + +Using client-side pagination means that the `data` that you fetch will contain ***ALL*** of the rows for the table, and the table instance will handle pagination logic in the front-end. + +#### Should You Use Client-Side Pagination? + +Client-side pagination is usually the simplest way to implement pagination when using TanStack Table, but it might not be practical for very large datasets. + +However, a lot of people underestimate just how much data can be handled client-side. If your table will only ever have a few thousand rows or less, client-side pagination can still be a viable option. TanStack Table is designed to scale up to 10s of thousands of rows with decent performance for pagination, filtering, sorting, and grouping. The [official pagination example](../framework/react/examples/pagination) loads 100,000 rows and still performs well, albeit with only handful of columns. + +Every use-case is different and will depend on the complexity of the table, how many columns you have, how large every piece of data is, etc. The main bottlenecks to pay attention to are: + +1. Can your server query all of the data in a reasonable amount of time (and cost)? +2. What is the total size of the fetch? (This might not scale as badly as you think if you don't have many columns.) +3. Is the client's browser using too much memory if all of the data is loaded at once? + +If you're not sure, you can always start with client-side pagination and then switch to server-side pagination in the future as your data grows. + +#### Should You Use Virtualization Instead? + +Alternatively, instead of paginating the data, you can render all rows of a large dataset on the same page, but only use the browser's resources to render the rows that are visible in the viewport. This strategy is often called "virtualization" or "windowing". TanStack offers a virtualization library called [TanStack Virtual](https://tanstack.com/virtual/latest) that can work well with TanStack Table. The UI/UX of both virtualization and pagination have their own trade-offs, so see which one works best for your use-case. + +#### Pagination Row Model + +If you want to take advantage of the built-in client-side pagination in TanStack Table, add the `rowPaginationFeature` to your features and the `paginatedRowModel` to your row models: + +```jsx +import { + useTable, + tableFeatures, + rowPaginationFeature, + createPaginatedRowModel, +} from '@tanstack/react-table' + +const _features = tableFeatures({ rowPaginationFeature }) + +const table = useTable({ + _features, + _rowModels: { + paginatedRowModel: createPaginatedRowModel(), + }, + columns, + data, +}) +``` + +> **Migrating from v8?** See [useLegacyTable](../framework/react/guide/use-legacy-table) for incremental migration. + +### Manual Server-Side Pagination + +If you decide that you need to use server-side pagination, here is how you can implement it. + +No pagination row model is needed for server-side pagination, but if you have provided it for other tables that do need it in a shared component, you can still turn off the client-side pagination by setting the `manualPagination` option to `true`. Setting the `manualPagination` option to `true` will tell the table instance to use the `table.getPrePaginatedRowModel` row model under the hood, and it will make the table instance assume that the `data` that you pass in is already paginated. + +#### Page Count and Row Count + +The table instance will have no way of knowing how many rows/pages there are in total in your back-end unless you tell it. Provide either the `rowCount` or `pageCount` table option to let the table instance know how many pages there are in total. If you provide a `rowCount`, the table instance will calculate the `pageCount` internally from `rowCount` and `pageSize`. Otherwise, you can directly provide the `pageCount` if you already have it. If you don't know the page count, you can just pass in `-1` for the `pageCount`, but the `getCanNextPage` and `getCanPreviousPage` row model functions will always return `true` in this case. + +```jsx +import { + useTable, + tableFeatures, + rowPaginationFeature, +} from '@tanstack/react-table' + +const _features = tableFeatures({ rowPaginationFeature }) + +const table = useTable({ + _features, + _rowModels: {}, // no paginatedRowModel needed for server-side pagination + columns, + data, + manualPagination: true, // turn off client-side pagination + rowCount: dataQuery.data?.rowCount, // pass in the total row count so the table knows how many pages there are (pageCount calculated internally if not provided) + // pageCount: dataQuery.data?.pageCount, // alternatively directly pass in pageCount instead of rowCount +}) +``` + +> **Note**: Setting the `manualPagination` option to `true` will make the table instance assume that the `data` that you pass in is already paginated. + +### Pagination State + +Whether or not you are using client-side or manual server-side pagination, you can use the built-in `pagination` state and APIs. + +The `pagination` state is an object that contains the following properties: + +- `pageIndex`: The current page index (zero-based). +- `pageSize`: The current page size. + +You can manage the `pagination` state just like any other state in the table instance. + +```jsx +import { + useTable, + tableFeatures, + rowPaginationFeature, + createPaginatedRowModel, +} from '@tanstack/react-table' + +const _features = tableFeatures({ rowPaginationFeature }) + +const [pagination, setPagination] = useState({ + pageIndex: 0, // initial page index + pageSize: 10, // default page size +}) + +const table = useTable({ + _features, + _rowModels: { + paginatedRowModel: createPaginatedRowModel(), + }, + columns, + data, + onPaginationChange: setPagination, + state: { + pagination, + }, +}) +``` + +Alternatively, if you have no need for managing the `pagination` state in your own scope, but you need to set different initial values for the `pageIndex` and `pageSize`, you can use the `initialState` option. + +```jsx +const table = useTable({ + _features, + _rowModels: { + paginatedRowModel: createPaginatedRowModel(), + }, + columns, + data, + initialState: { + pagination: { + pageIndex: 2, // custom initial page index + pageSize: 25, // custom default page size + }, + }, +}) +``` + +> **Note**: Do NOT pass the `pagination` state to both the `state` and `initialState` options. `state` will overwrite `initialState`. Only use one or the other. + +### Pagination Options + +Besides the `manualPagination`, `pageCount`, and `rowCount` options which are useful for manual server-side pagination (and discussed [above](#manual-server-side-pagination)), there is one other table option that is useful to understand. + +#### Auto Reset Page Index + +By default, `pageIndex` is reset to `0` when page-altering state changes occur, such as when the `data` is updated, filters change, grouping changes, etc. This behavior is automatically disabled when `manualPagination` is true but it can be overridden by explicitly assigning a boolean value to the `autoResetPageIndex` table option. + +```jsx +const table = useTable({ + _features, + _rowModels: { + paginatedRowModel: createPaginatedRowModel(), + }, + columns, + data, + autoResetPageIndex: false, // turn off auto reset of pageIndex +}) +``` + +Be aware, however, that if you turn off `autoResetPageIndex`, you may need to add some logic to handle resetting the `pageIndex` yourself to avoid showing empty pages. + +### Pagination APIs + +There are several pagination table instance APIs that are useful for hooking up your pagination UI components. + +#### Pagination Button APIs + +- `getCanPreviousPage`: Useful for disabling the "previous page" button when on the first page. +- `getCanNextPage`: Useful for disabling the "next page" button when there are no more pages. +- `previousPage`: Useful for going to the previous page. (Button click handler) +- `nextPage`: Useful for going to the next page. (Button click handler) +- `firstPage`: Useful for going to the first page. (Button click handler) +- `lastPage`: Useful for going to the last page. (Button click handler) +- `setPageIndex`: Useful for a "go to page" input. +- `resetPageIndex`: Useful for resetting the table state to the original page index. +- `setPageSize`: Useful for a "page size" input/select. +- `resetPageSize`: Useful for resetting the table state to the original page size. +- `setPagination`: Useful for setting all of the pagination state at once. +- `resetPagination`: Useful for resetting the table state to the original pagination state. + +> **Note**: These pagination APIs are available when using `rowPaginationFeature`. + +```jsx + + + + + +``` + +#### Pagination Info APIs + +- `getPageCount`: Useful for showing the total number of pages. +- `getRowCount`: Useful for showing the total number of rows. diff --git a/docs/guide/pinning.md b/docs/guide/pinning.md new file mode 100644 index 0000000000..aa8c116291 --- /dev/null +++ b/docs/guide/pinning.md @@ -0,0 +1,10 @@ +--- +title: Pinning Guide +--- + + + +Pinning is split into 2 different feature guides: + +- [Column Pinning](./column-pinning) +- [Row Pinning](./row-pinning) \ No newline at end of file diff --git a/docs/guide/row-models.md b/docs/guide/row-models.md new file mode 100644 index 0000000000..798332d2aa --- /dev/null +++ b/docs/guide/row-models.md @@ -0,0 +1,142 @@ +--- +title: Row Models Guide +--- + +## Row Models Guide + +If you take a look at the most basic example of TanStack Table, you'll see a code snippet like this: + +```ts +import { tableFeatures, useTable } from '@tanstack/react-table' + +const _features = tableFeatures({}) // Core features only + +function Component() { + const table = useTable({ + _features, + _rowModels: {}, // Core row model is automatic; add others as needed + columns, + data, + }) +} +``` + +In v9, row models are configured via the `_rowModels` option. The core row model is always included automatically. You only add the row models you need for filtering, sorting, pagination, etc. This keeps your bundle small—you only import and use the code for the features you enable. + +### What are Row Models? + +Row models run under the hood of TanStack Table to transform your original data in useful ways that are needed for data grid features like filtering, sorting, grouping, expanding, and pagination. The rows that get generated and render on screen won't necessarily be a 1:1 mapping of the original data that you passed to the table. They may be sorted, filtered, paginated, etc. + +### Configuring Row Models + +You should only add the row models that you need. Here are all of the row models that are available via `_rowModels`: + +| `_rowModels` Key | Factory Function | Purpose | +|------------------|------------------|---------| +| (automatic) | — | Core row model (always included) | +| `filteredRowModel` | `createFilteredRowModel(filterFns)` | Filtering (column + global) | +| `sortedRowModel` | `createSortedRowModel(sortFns)` | Sorting | +| `paginatedRowModel` | `createPaginatedRowModel()` | Pagination | +| `expandedRowModel` | `createExpandedRowModel()` | Row expanding | +| `groupedRowModel` | `createGroupedRowModel(aggregationFns)` | Grouping and aggregation | +| `facetedRowModel` | `createFacetedRowModel()` | Faceted filtering | +| `facetedMinMaxValues` | `createFacetedMinMaxValues()` | Min/max for faceted filters | +| `facetedUniqueValues` | `createFacetedUniqueValues()` | Unique values for faceted filters | + +You must also add the corresponding features to `_features` for each row model you use. For example: + +```ts +import { + tableFeatures, + useTable, + columnFilteringFeature, + rowSortingFeature, + rowPaginationFeature, + createFilteredRowModel, + createSortedRowModel, + createPaginatedRowModel, + filterFns, + sortFns, +} from '@tanstack/react-table' + +const _features = tableFeatures({ + columnFilteringFeature, + rowSortingFeature, + rowPaginationFeature, +}) + +const table = useTable({ + _features, + _rowModels: { + filteredRowModel: createFilteredRowModel(filterFns), + sortedRowModel: createSortedRowModel(sortFns), + paginatedRowModel: createPaginatedRowModel(), + }, + columns, + data, +}) +``` + +Note that `createFilteredRowModel`, `createSortedRowModel`, and `createGroupedRowModel` accept their processing functions (`filterFns`, `sortFns`, `aggregationFns`) as parameters. This enables tree-shaking—if you use a custom filter, you don't pay for built-in filters you never use. + +### Customize/Fork Row Models + +You don't have to use the exact row models that are provided by TanStack Table. If you need some advanced customization for certain row models, feel free to copy the [source code](https://github.com/TanStack/table/tree/main/packages/table-core/src/utils) for the row model you want to customize and modify it to your needs. + +### Using Row Models + +Once your table instance has been created, you can access all of the row models that you may need directly from the table instance. There are even more derived row models available apart from the ones that you may have imported. + +For normal rendering use cases, you will probably only need to use the `table.getRowModel()` method, as this row model will use all/any of the other row models depending on which features you have enabled or disabled. All of the other row models are available for you to "dig into" some of the underlying data transformations that are happening in the table. + +### Available Row Models on Table Instance + +- **`getRowModel`** - This is the main row model that you should use for rendering your table rows markup. It will use all of the other row models to generate the final row model that you will use to render your table rows. + +- `getCoreRowModel` - returns a basic row model that is just a 1:1 mapping of the original data passed to the table. + +- `getFilteredRowModel` - returns a row model that accounts for column filtering and global filtering. +- `getPreFilteredRowModel` - returns a row model before column filtering and global filtering are applied. + +- `getGroupedRowModel` - returns a row model that applies grouping and aggregation to the data and creates sub-rows. +- `getPreGroupedRowModel` - returns a row model before grouping and aggregation are applied. + +- `getSortedRowModel` - returns a row model that has had sorting applied to it. +- `getPreSortedRowModel` - returns a row model before sorting is applied (rows are in original order). + +- `getExpandedRowModel` - returns a row model that accounts for expanded/hidden sub-rows. +- `getPreExpandedRowModel` - returns a row model that only includes root level rows with no expanded sub-rows included. Still includes sorting. + +- `getPaginatedRowModel` - returns a row model that only includes the rows that should be displayed on the current page based on the pagination state. +- `getPrePaginatedRowModel` - returns a row model without pagination applied (includes all rows). + +- `getSelectedRowModel` - returns a row model of all selected rows (but only based on the data that was passed to the table). Runs after getCoreRowModel. +- `getPreSelectedRowModel` - returns a row model before row selection is applied (Just returns getCoreRowModel). +- `getGroupedSelectedRowModel` - returns a row model of selected rows after grouping. Runs after getSortedRowModel, which runs after getGroupedRowModel, which runs after getFilteredRowModel. +- `getFilteredSelectedRowModel` - returns a row model of selected rows after column filtering and global filtering. Runs after getFilteredRowModel. + +### The Order of Row Model Execution + +Knowing how TanStack Table processes rows internally can help you gain a better understanding of what is happening under the hood, and help you debug any issues you may encounter. + +Internally, this is the order in which each of the row models are applied to the data, if their respective features are enabled: + +`getCoreRowModel` -> `getFilteredRowModel` -> `getGroupedRowModel` -> `getSortedRowModel` -> `getExpandedRowModel` -> `getPaginatedRowModel` -> `getRowModel` + +If in any case the respective feature is disabled or turned off with a `"manual*"` table option, the `getPre*RowModel` will be used instead in that step of the process. + +As you can see above, first the data is filtered, then grouped, then sorted, then expanded, and then finally paginated as the final step. + +### Row Model Data Structure + +Each row model will provide you the rows in 3 different useful formats: + +1. `rows` - An array of rows. +2. `flatRows` - An array of rows, but all sub-rows are flattened into the top level. +3. `rowsById` - An object of rows, where each row is keyed by its `id`. This is useful for quickly looking up rows by their `id` with better performance. + +```ts +console.log(table.getRowModel().rows) // array of rows +console.log(table.getRowModel().flatRows) // array of rows, but all sub-rows are flattened into the top level +console.log(table.getRowModel().rowsById['row-id']) // object of rows, where each row is keyed by its `id` +``` \ No newline at end of file diff --git a/docs/guide/row-pinning.md b/docs/guide/row-pinning.md new file mode 100644 index 0000000000..bc497a3abb --- /dev/null +++ b/docs/guide/row-pinning.md @@ -0,0 +1,20 @@ +--- +title: Row Pinning Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [row-pinning](../framework/react/examples/row-pinning) + +## API + +[Row Pinning API](../api/features/row-pinning) + +## Row Pinning Guide + +There are 2 table features that can reorder rows, which happen in the following order: + +1. **Row Pinning** - If pinning, rows are split into top, center (unpinned), and bottom pinned rows. +2. [Sorting](./sorting) \ No newline at end of file diff --git a/docs/guide/row-selection.md b/docs/guide/row-selection.md new file mode 100644 index 0000000000..bde86c7972 --- /dev/null +++ b/docs/guide/row-selection.md @@ -0,0 +1,192 @@ +--- +title: Row Selection Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [React row-selection](../framework/react/examples/row-selection) +- [Vue row-selection](../framework/vue/row-selection) +- [React expanding](../framework/react/examples/expanding) + +## API + +[Row Selection API](../api/features/row-selection) + +## Row Selection Guide + +The row selection feature keeps track of which rows are selected and allows you to toggle the selection of rows in a myriad of ways. Let's take a look at some common use cases. + +### Access Row Selection State + +The table instance already manages the row selection state for you (though as seen down below, it may be more convenient to manage the row selection state in your own scope). You can access the internal row selection state or the selected rows from a few APIs. + +- `table.store.state.rowSelection` - returns the internal row selection state +- `getSelectedRowModel()` - returns selected rows +- `getFilteredSelectedRowModel()` - returns selected rows after filtering +- `getGroupedSelectedRowModel()` - returns selected rows after grouping and sorting + +```ts +console.log(table.store.state.rowSelection) //get the row selection state - { 1: true, 2: false, etc... } +console.log(table.getSelectedRowModel().rows) //get full client-side selected rows +console.log(table.getFilteredSelectedRowModel().rows) //get filtered client-side selected rows +console.log(table.getGroupedSelectedRowModel().rows) //get grouped client-side selected rows +``` + +> Note: If you are using `manualPagination`, be aware that the `getSelectedRowModel` API will only return selected rows on the current page because table row models can only generate rows based on the `data` that is passed in. Row selection state, however, can contain row ids that are not present in the `data` array just fine. + +### Manage Row Selection State + +Even though the table instance will already manage the row selection state for you, it is usually more convenient to manage the state yourself in order to have easy access to the selected row ids that you can use to make API calls or other actions. + +Use the `onRowSelectionChange` table option to hoist up the row selection state to your own scope. Then pass the row selection state back to the table instance using in the `state` table option. + +```ts +import { useTable, tableFeatures, rowSelectionFeature } from '@tanstack/react-table' + +const _features = tableFeatures({ rowSelectionFeature }) + +const [rowSelection, setRowSelection] = useState({}) + +const table = useTable({ + _features, + _rowModels: {}, + //... + onRowSelectionChange: setRowSelection, + state: { + rowSelection, + }, +}) +``` + +### Useful Row Ids + +By default, the row id for each row is simply the `row.index`. If you are using row selection features, you most likely want to use a more useful row identifier, since the row selection state is keyed by row id. You can use the `getRowId` table option to specify a function that returns a unique row id for each row. + +```ts +const table = useTable({ + _features, + _rowModels: {}, + //... + getRowId: (row) => row.uuid, // use the row's uuid from your database as the row id +}) +``` + +Now as rows are selected, the row selection state will look something like this: + +```json +{ + "13e79140-62a8-4f9c-b087-5da737903b76": true, + "f3e2a5c0-5b7a-4d8a-9a5c-9c9b8a8e5f7e": false + //... +} +``` + +instead of this: + +```json +{ + "0": true, + "1": false + //... +} +``` + +### Enable Row Selection Conditionally + +Row selection is enabled by default for all rows. To either enable row selection conditionally for certain rows or disable row selection for all rows, you can use the `enableRowSelection` table option which accepts either a boolean or a function for more granular control. + +```ts +const table = useTable({ + //... + enableRowSelection: row => row.original.age > 18, //only enable row selection for adults +}) +``` + +To enforce whether a row is selectable or not in your UI, you can use the `row.getCanSelect()` API for your checkboxes or other selection UI. + +### Single Row Selection + +By default, the table allows multiple rows to be selected at once. If, however, you only want to allow a single row to be selected at once, you can set the `enableMultiRowSelection` table option to `false` to disable multi-row selection, or pass in a function to disable multi-row selection conditionally for a row's sub-rows. + +This is useful for making tables that have radio buttons instead of checkboxes. + +```ts +const table = useTable({ + //... + enableMultiRowSelection: false, //only allow a single row to be selected at once + // enableMultiRowSelection: row => row.original.age > 18, //only allow a single row to be selected at once for adults +}) +``` + +### Sub-Row Selection + +By default, selecting a parent row will select all of its sub-rows. If you want to disable auto sub-row selection, you can set the `enableSubRowSelection` table option to `false` to disable sub-row selection, or pass in a function to disable sub-row selection conditionally for a row's sub-rows. + +```ts +const table = useTable({ + //... + enableSubRowSelection: false, //disable sub-row selection + // enableSubRowSelection: row => row.original.age > 18, //disable sub-row selection for adults +}) +``` + +### Render Row Selection UI + +TanStack table does not dictate how you should render your row selection UI. You can use checkboxes, radio buttons, or simply hook up click events to the row itself. The table instance provides a few APIs to help you render your row selection UI. + +#### Connect Row Selection APIs to Checkbox Inputs + +TanStack Table provides some handler functions that you can connect directly to your checkbox inputs to make it easy to toggle row selection. These function automatically call other internal APIs to update the row selection state and re-render the table. + +Use the `row.getToggleSelectedHandler()` API to connect to your checkbox inputs to toggle the selection of a row. + +Use the `table.getToggleAllRowsSelectedHandler()` or `table.getToggleAllPageRowsSelectedHandler` APIs to connect to your "select all" checkbox input to toggle the selection of all rows. + +If you need more granular control over these function handlers, you can always just use the `row.toggleSelected()` or `table.toggleAllRowsSelected()` APIs directly. Or you can even just call the `table.setRowSelection()` API to directly set the row selection state just as you would with any other state updater. These handler functions are just a convenience. + +```tsx +const columns = [ + { + id: 'select-col', + header: ({ table }) => ( + + ), + cell: ({ row }) => ( + + ), + }, + //... more column definitions... +] +``` + +#### Connect Row Selection APIs to UI + +If you want a simpler row selection UI, you can just hook up click events to the row itself. The `row.getToggleSelectedHandler()` API is also useful for this use case. + +```tsx + + {table.getRowModel().rows.map(row => { + return ( + + {row.getVisibleCells().map(cell => { + return {/* */} + })} + + ) + })} + +``` diff --git a/docs/guide/rows.md b/docs/guide/rows.md new file mode 100644 index 0000000000..86bf702610 --- /dev/null +++ b/docs/guide/rows.md @@ -0,0 +1,99 @@ +--- +title: Rows Guide +--- + +## API + +[Row API](../api/core/row) + +## Rows Guide + +This quick guide will discuss the different ways you can retrieve and interact with row objects in TanStack Table. + +### Where to Get Rows From + +There are multiple `table` instance APIs you can use to retrieve rows from the table instance. + +#### table.getRow + +If you need to access a specific row by its `id`, you can use the `table.getRow` table instance API. + +```js +const row = table.getRow(rowId) +``` + +#### Row Models + +The `table` instance generates `row` objects and stores them in useful arrays called ["Row Models"](./row-models). This is discussed in much more detail in the [Row Models Guide](./row-models), but here are the most common ways you may access the row models. + +##### Render Rows + +```jsx + + {table.getRowModel().rows.map(row => ( + + {/* ... */} + + ))} + +``` + +##### Get Selected Rows + +```js +const selectedRows = table.getSelectedRowModel().rows +``` + +### Row Objects + +Every row object contains row data and many APIs to either interact with the table state or extract cells from the row based on the state of the table. + +#### Row IDs + +Every row object has an `id` property that makes it unique within the table instance. By default the `row.id` is the same as the `row.index` that is created in the row model. However, it can be useful to override each row's `id` with a unique identifier from the row's data. You can use the `getRowId` table option to do this. + +```js +const table = useTable({ + _features, + _rowModels: {}, + columns, + data, + getRowId: (originalRow) => originalRow.uuid, // override the row.id with the uuid from the original row's data +}) +``` + +> Note: In some features like grouping and expanding, the `row.id` will have additional string appended to it. + +#### Access Row Values + +The recommended way to access data values from a row is to use either the `row.getValue` or `row.renderValue` APIs. Using either of these APIs will cache the results of the accessor functions and keep rendering efficient. The only difference between the two is that `row.renderValue` will return either the value or the `renderFallbackValue` if the value is undefined, whereas `row.getValue` will return the value or `undefined` if the value is undefined. + +```js +// Access data from any of the columns +const firstName = row.getValue('firstName') // read the row value from the firstName column +const renderedLastName = row.renderValue('lastName') // render the value from the lastName column +``` + +> Note: `cell.getValue` and `cell.renderValue` are shortcuts for the `row.getValue` and `row.renderValue` APIs, respectively. + +#### Access Original Row Data + +For every row object, you can access the original corresponding `data` that was passed to the table instance via the `row.original` property. None of the data in the `row.original` will have been modified by the accessors in your column definitions, so if you were doing any sort of data transformations in your accessors, those will not be reflected in the `row.original` object. + +```js +// Access any data from the original row +const firstName = row.original.firstName // { firstName: 'John', lastName: 'Doe' } +``` + +### Sub Rows + +If you are using either grouping or expanding features, your rows may contain sub-rows or parent row references. This is discussed in much more detail in the [Expanding Guide](./expanding), but here is a quick overview of useful properties and methods for working with sub-rows. + +- `row.subRows`: An array of sub-rows for the row. +- `row.depth`: The depth of the row (if nested or grouped) relative to the root row array. 0 for root level rows, 1 for child rows, 2 for grandchild rows, etc. +- `row.parentId`: The unique ID of the parent row for the row (The row that contains this row in its subRows array). +- `row.getParentRow`: Returns the parent row for the row, if it exists. + +### More Row APIs + +Depending on the features that you are using for your table, there are dozens more useful APIs for interacting with rows. See each features' respective API docs or guide for more information. \ No newline at end of file diff --git a/docs/guide/sorting.md b/docs/guide/sorting.md new file mode 100644 index 0000000000..9a8c8421e7 --- /dev/null +++ b/docs/guide/sorting.md @@ -0,0 +1,450 @@ +--- +title: Sorting Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [sorting](../framework/react/examples/sorting) +- [filters](../framework/react/examples/filters) + +## API + +[Sorting API](../api/features/sorting) + +## Sorting Guide + +TanStack Table provides solutions for just about any sorting use-case you might have. This guide will walk you through the various options that you can use to customize the built-in client-side sorting functionality, as well as how to opt out of client-side sorting in favor of manual server-side sorting. + +### Sorting State + +The sorting state is defined as an array of objects with the following shape: + +```tsx +type ColumnSort = { + id: string + desc: boolean +} +type SortingState = ColumnSort[] +``` + +Since the sorting state is an array, it is possible to sort by multiple columns at once. Read more about the multi-sorting customizations down [below](#multi-sorting). + +#### Accessing Sorting State + +You can access the sorting state directly from the table instance just like any other state using the `table.store.state` API. + +```tsx +const table = useTable({ + _features, + _rowModels: { sortedRowModel: createSortedRowModel(sortFns) }, + columns, + data, + //... +}) + +console.log(table.store.state.sorting) // access the sorting state from the table instance +``` + +However, if you need to access the sorting state before the table is initialized, you can "control" the sorting state like down below. + +#### Controlled Sorting State + +If you need easy access to the sorting state, you can control/manage the sorting state in your own state management with the `state.sorting` and `onSortingChange` table options. + +```tsx +const [sorting, setSorting] = useState([]) // can set initial sorting state here +//... +// use sorting state to fetch data from your server or something... +//... +const table = useTable({ + _features, + _rowModels: { sortedRowModel: createSortedRowModel(sortFns) }, + columns, + data, + //... + state: { + sorting, + }, + onSortingChange: setSorting, +}) +``` + +#### Initial Sorting State + +If you do not need to control the sorting state in your own state management or scope, but you still want to set an initial sorting state, you can use the `initialState` table option instead of `state`. + +```jsx +const table = useTable({ + _features, + _rowModels: { sortedRowModel: createSortedRowModel(sortFns) }, + columns, + data, + //... + initialState: { + sorting: [ + { + id: 'name', + desc: true, // sort by name in descending order by default + }, + ], + }, +}) +``` + +> **NOTE**: Do not use both `initialState.sorting` and `state.sorting` at the same time, as the initialized state in the `state.sorting` will override the `initialState.sorting`. + +### Client-Side vs Server-Side Sorting + +Whether or not you should use client-side or server-side sorting depends entirely on whether you are also using client-side or server-side pagination or filtering. Be consistent, because using client-side sorting with server-side pagination or filtering will only sort the data that is currently loaded, and not the entire dataset. + +### Manual Server-Side Sorting + +If you plan to just use your own server-side sorting in your back-end logic, you do not need to provide a sorted row model. But if you have provided a sorting row model, but you want to disable it, you can use the `manualSorting` table option. + +```jsx +const [sorting, setSorting] = useState([]) +//... +const table = useTable({ + _features: tableFeatures({ rowSortingFeature }), // feature needed for sorting state/APIs + _rowModels: {}, // no sortedRowModel needed for manual sorting + columns, + data, + manualSorting: true, // use pre-sorted row model instead of sorted row model + state: { + sorting, + }, + onSortingChange: setSorting, +}) +``` + +> **NOTE**: When `manualSorting` is set to `true`, the table will assume that the data that you provide is already sorted, and will not apply any sorting to it. + +### Client-Side Sorting + +To implement client-side sorting, add the `rowSortingFeature` to your features and the `sortedRowModel` to your row models. Import `createSortedRowModel` and `sortFns` from TanStack Table: + +```jsx +import { + useTable, + tableFeatures, + rowSortingFeature, + createSortedRowModel, + sortFns, +} from '@tanstack/react-table' + +const _features = tableFeatures({ rowSortingFeature }) + +const table = useTable({ + _features, + _rowModels: { + sortedRowModel: createSortedRowModel(sortFns), + }, + columns, + data, +}) +``` + +### Sorting RowModelFns + +The default sorting function for all columns is inferred from the data type of the column. However, it can be useful to define the exact sorting function that you want to use for a specific column, especially if any of your data is nullable or not a standard data type. + +You can determine a custom sorting function on a per-column basis using the `sortFn` column option. + +By default, there are 6 built-in sorting functions to choose from: + +- `alphanumeric` - Sorts by mixed alphanumeric values without case-sensitivity. Slower, but more accurate if your strings contain numbers that need to be naturally sorted. +- `alphanumericCaseSensitive` - Sorts by mixed alphanumeric values with case-sensitivity. Slower, but more accurate if your strings contain numbers that need to be naturally sorted. +- `text` - Sorts by text/string values without case-sensitivity. Faster, but less accurate if your strings contain numbers that need to be naturally sorted. +- `textCaseSensitive` - Sorts by text/string values with case-sensitivity. Faster, but less accurate if your strings contain numbers that need to be naturally sorted. +- `datetime` - Sorts by time, use this if your values are `Date` objects. +- `basic` - Sorts using a basic/standard `a > b ? 1 : a < b ? -1 : 0` comparison. This is the fastest sorting function, but may not be the most accurate. + +You can also define your own custom sorting functions either as the `sortFn` column option, or as a global sorting function using the `sortFns` table option. + +#### Custom Sorting Functions + +When defining a custom sorting function in either the `sortFns` table option or as a `sortFn` column option, it should have the following signature: + +```tsx +//optionally use the SortFn to infer the parameter types +const myCustomSortFn: SortFn = (rowA: Row, rowB: Row, columnId: string) => { + return //-1, 0, or 1 - access any row data using rowA.original and rowB.original +} +``` + +> Note: The comparison function does not need to take whether or not the column is in descending or ascending order into account. The row models will take of that logic. `sortFn` functions only need to provide a consistent comparison. + +Every sorting function receives 2 rows and a column ID and are expected to compare the two rows using the column ID to return `-1`, `0`, or `1` in ascending order. Here's a cheat sheet: + +| Return | Ascending Order | +| ------ | --------------- | +| `-1` | `a < b` | +| `0` | `a === b` | +| `1` | `a > b` | + +```jsx +const columns = [ + { + header: () => 'Name', + accessorKey: 'name', + sortFn: 'alphanumeric', // use built-in sorting function by name + }, + { + header: () => 'Age', + accessorKey: 'age', + sortFn: 'myCustomSortFn', // use custom global sorting function + }, + { + header: () => 'Birthday', + accessorKey: 'birthday', + sortFn: 'datetime', // recommended for date columns + }, + { + header: () => 'Profile', + accessorKey: 'profile', + // use custom sorting function directly + sortFn: (rowA, rowB, columnId) => { + return rowA.original.someProperty - rowB.original.someProperty + }, + } +] +//... +const table = useTable({ + _features, + _rowModels: { + sortedRowModel: createSortedRowModel({ + ...sortFns, + myCustomSortFn: (rowA, rowB, columnId) => + rowA.original[columnId] > rowB.original[columnId] + ? 1 + : rowA.original[columnId] < rowB.original[columnId] + ? -1 + : 0, + }), + }, + columns, + data, +}) +``` + +### Customize Sorting + +There are a lot of table and column options that you can use to further customize the sorting UX and behavior. + +#### Disable Sorting + +You can disable sorting for either a specific column or the entire table using the `enableSorting` column option or table option. + +```jsx +const columns = [ + { + header: () => 'ID', + accessorKey: 'id', + enableSorting: false, // disable sorting for this column + }, + { + header: () => 'Name', + accessorKey: 'name', + }, + //... +] +//... +const table = useTable({ + _features, + _rowModels: { sortedRowModel: createSortedRowModel(sortFns) }, + columns, + data, + enableSorting: false, // disable sorting for the entire table +}) +``` + +#### Sorting Direction + +By default, the first sorting direction when cycling through the sorting for a column using the `toggleSorting` APIs is ascending for string columns and descending for number columns. You can change this behavior with the `sortDescFirst` column option or table option. + +```jsx +const columns = [ + { + header: () => 'Name', + accessorKey: 'name', + sortDescFirst: true, //sort by name in descending order first (default is ascending for string columns) + }, + { + header: () => 'Age', + accessorKey: 'age', + sortDescFirst: false, //sort by age in ascending order first (default is descending for number columns) + }, + //... +] +//... +const table = useTable({ + _features, + _rowModels: { sortedRowModel: createSortedRowModel(sortFns) }, + columns, + data, + sortDescFirst: true, //sort by all columns in descending order first (default is ascending for string columns and descending for number columns) +}) +``` + +> **NOTE**: You may want to explicitly set the `sortDescFirst` column option on any columns that have nullable values. The table may not be able to properly determine if a column is a number or a string if it contains nullable values. + +#### Invert Sorting + +Inverting sorting is not the same as changing the default sorting direction. If `invertSorting` column option is `true` for a column, then the "desc/asc" sorting states will still cycle like normal, but the actual sorting of the rows will be inverted. This is useful for values that have an inverted best/worst scale where lower numbers are better, eg. a ranking (1st, 2nd, 3rd) or golf-like scoring. + +```jsx +const columns = [ + { + header: () => 'Rank', + accessorKey: 'rank', + invertSorting: true, // invert the sorting for this column. 1st -> 2nd -> 3rd -> ... even if "desc" sorting is applied + }, + //... +] +``` + +#### Sort Undefined Values + +Any undefined values will be sorted to the beginning or end of the list based on the `sortUndefined` column option or table option. You can customize this behavior for your specific use-case. + +In not specified, the default value for `sortUndefined` is `1`, and undefined values will be sorted with lower priority (descending), if ascending, undefined will appear on the end of the list. + +- `'first'` - Undefined values will be pushed to the beginning of the list +- `'last'` - Undefined values will be pushed to the end of the list +- `false` - Undefined values will be considered tied and need to be sorted by the next column filter or original index (whichever applies) +- `-1` - Undefined values will be sorted with higher priority (ascending) (if ascending, undefined will appear on the beginning of the list) +- `1` - Undefined values will be sorted with lower priority (descending) (if ascending, undefined will appear on the end of the list) + +> NOTE: `'first'` and `'last'` options are available in v9. + +```jsx +const columns = [ + { + header: () => 'Rank', + accessorKey: 'rank', + sortUndefined: -1, // 'first' | 'last' | 1 | -1 | false + }, +] +``` + +#### Sorting Removal + +By default, the ability to remove sorting while cycling through the sorting states for a column is enabled. You can disable this behavior using the `enableSortingRemoval` table option. This behavior is useful if you want to ensure that at least one column is always sorted. + +The default behavior when using either the `getToggleSortingHandler` or `toggleSorting` APIs is to cycle through the sorting states like this: + +`'none' -> 'desc' -> 'asc' -> 'none' -> 'desc' -> 'asc' -> ...` + +If you disable sorting removal, the behavior will be like this: + +`'none' -> 'desc' -> 'asc' -> 'desc' -> 'asc' -> ...` + +Once a column is sorted and `enableSortingRemoval` is `false`, toggling the sorting on that column will never remove the sorting. However, if the user sorts by another column and it is not a multi-sort event, then the sorting will be removed from the previous column and just applied to the new column. + +> Set `enableSortingRemoval` to `false` if you want to ensure that at least one column is always sorted. + +```jsx +const table = useTable({ + _features, + _rowModels: { sortedRowModel: createSortedRowModel(sortFns) }, + columns, + data, + enableSortingRemoval: false, // disable the ability to remove sorting on columns (always none -> asc -> desc -> asc) +}) +``` + +#### Multi-Sorting + +Sorting by multiple columns at once is enabled by default if using the `column.getToggleSortingHandler` API. If the user holds the `Shift` key while clicking on a column header, the table will sort by that column in addition to the columns that are already sorted. If you use the `column.toggleSorting` API, you have to manually pass in whether or not to use multi-sorting. (`column.toggleSorting(desc, multi)`). + +##### Disable Multi-Sorting + +You can disable multi-sorting for either a specific column or the entire table using the `enableMultiSort` column option or table option. Disabling multi-sorting for a specific column will replace all existing sorting with the new column's sorting. + +```jsx +const columns = [ + { + header: () => 'Created At', + accessorKey: 'createdAt', + enableMultiSort: false, // always sort by just this column if sorting by this column + }, + //... +] +//... +const table = useTable({ + _features, + _rowModels: { sortedRowModel: createSortedRowModel(sortFns) }, + columns, + data, + enableMultiSort: false, // disable multi-sorting for the entire table +}) +``` + +##### Customize Multi-Sorting Trigger + +By default, the `Shift` key is used to trigger multi-sorting. You can change this behavior with the `isMultiSortEvent` table option. You can even specify that all sorting events should trigger multi-sorting by returning `true` from the custom function. + +```jsx +const table = useTable({ + _features, + _rowModels: { sortedRowModel: createSortedRowModel(sortFns) }, + columns, + data, + isMultiSortEvent: (e) => true, // normal click triggers multi-sorting + //or + isMultiSortEvent: (e) => e.ctrlKey || e.shiftKey, // also use the `Ctrl` key to trigger multi-sorting +}) +``` + +##### Multi-Sorting Limit + +By default, there is no limit to the number of columns that can be sorted at once. You can set a limit using the `maxMultiSortColCount` table option. + +```jsx +const table = useTable({ + _features, + _rowModels: { sortedRowModel: createSortedRowModel(sortFns) }, + columns, + data, + maxMultiSortColCount: 3, // only allow 3 columns to be sorted at once +}) +``` + +##### Multi-Sorting Removal + +By default, the ability to remove multi-sorts is enabled. You can disable this behavior using the `enableMultiRemove` table option. + +```jsx +const table = useTable({ + _features, + _rowModels: { sortedRowModel: createSortedRowModel(sortFns) }, + columns, + data, + enableMultiRemove: false, // disable the ability to remove multi-sorts +}) +``` + +### Sorting APIs + +There are a lot of sorting related APIs that you can use to hook up to your UI or other logic. Here is a list of all of the sorting APIs and some of their use-cases. + +- `table.setSorting` - Set the sorting state directly. +- `table.resetSorting` - Reset the sorting state to the initial state or clear it. + +- `column.getCanSort` - Useful for enabling/disabling the sorting UI for a column. +- `column.getIsSorted` - Useful for showing a visual sorting indicator for a column. + +- `column.getToggleSortingHandler` - Useful for hooking up the sorting UI for a column. Add to a sort arrow (icon button), menu item, or simply the entire column header cell. This handler will call `column.toggleSorting` with the correct parameters. +- `column.toggleSorting` - Useful for hooking up the sorting UI for a column. If using instead of `column.getToggleSortingHandler`, you have to manually pass in whether or not to use multi-sorting. (`column.toggleSorting(desc, multi)`) +- `column.clearSorting` - Useful for a "clear sorting" button or menu item for a specific column. + +- `column.getNextSortingOrder` - Useful for showing which direction the column will sort by next. (asc/desc/clear in a tooltip/menu item/aria-label or something) +- `column.getFirstSortDir` - Useful for showing which direction the column will sort by first. (asc/desc in a tooltip/menu item/aria-label or something) +- `column.getAutoSortDir` - Determines whether the first sorting direction will be ascending or descending for a column. +- `column.getAutoSortFn` - Used internally to find the default sorting function for a column if none is specified. +- `column.getSortFn` - Returns the exact sorting function being used for a column. + +- `column.getCanMultiSort` - Useful for enabling/disabling the multi-sorting UI for a column. +- `column.getSortIndex` - Useful for showing a badge or indicator of the column's sort order in a multi-sort scenario. i.e. whether or not it is the first, second, third, etc. column to be sorted. diff --git a/docs/guide/tables.md b/docs/guide/tables.md new file mode 100644 index 0000000000..f3d4af7046 --- /dev/null +++ b/docs/guide/tables.md @@ -0,0 +1,108 @@ +--- +title: Table Instance Guide +--- + +## API + +[Table API](../api/core/table) + +## Table Instance Guide + +TanStack Table is a headless UI library. When we talk about the `table` or "table instance", we're not talking about a literal `` element. Instead, we're referring to the core table object that contains the table state and APIs. The `table` instance is created by calling your adapter's `_createTable` function (e.g. `useTable`, `createTable`, or `injectTable`). + +The `table` instance that is returned from the `_createTable` function (from the framework adapter) is the main object that you will interact with to read and mutate the table state. It is the one place where everything happens in TanStack Table. When you get to the point where you are rendering your UI, you will use APIs from this `table` instance. + +### Creating a Table Instance + +To create a table instance, 3 `options` are required: `columns`, `data`, and `_features`. The `_features` option declares which table features your table uses (enabling tree-shaking—you only bundle what you use). The core row model is included automatically; add additional row models via `_rowModels` when you need filtering, sorting, pagination, etc. There are dozens of other table options to configure features and behavior. + +#### Defining Data + +Define your data as an array of objects with a stable reference. `data` can come from anywhere like an API response or defined statically in your code, but it must have a stable reference to prevent infinite re-renders. If using TypeScript, the type that you give your data will be used as a `TData` generic. See the [Data Guide](./data) for more info. + +#### Defining Columns + +Column definitions are covered in detail in the previous section in the [Column Def Guide](./column-defs). We'll note here, however, that when you define the type of your columns, you should use the same `TData` type that you used for your data. + +```ts +const _features = tableFeatures({}) // Define which features your table uses +const columns: ColumnDef[] = [] // Pass User type as TData; use typeof _features for TFeatures +//or +const columnHelper = createColumnHelper() // Pass both TFeatures and TData in v9 +``` + +The column definitions are where we will tell TanStack Table how each column should access and/or transform row data with either an `accessorKey` or `accessorFn`. See the [Column Def Guide](./column-defs#creating-accessor-columns) for more info. + +#### Defining Features and Row Models + +This is explained in much more detail in the [Row Models Guide](./row-models). In v9, you declare which features your table uses via `_features` (using `tableFeatures()`), and which row models to apply via `_rowModels`. The core row model is always included automatically. For a basic table with no filtering, sorting, or pagination, pass an empty features object and empty row models: + +```ts +import { tableFeatures } from '@tanstack/[framework]-table' + +const _features = tableFeatures({}) // Core features only; add columnFilteringFeature, rowSortingFeature, etc. as needed + +const table = _createTable({ + _features, + _rowModels: {}, // Core row model is automatic; add filteredRowModel, sortedRowModel, etc. as needed + columns, + data, +}) +``` + +#### Initializing the Table Instance + +With our `_features`, `columns`, `data`, and `_rowModels` defined, we can now create our basic table instance, along side any other table options that we want to pass in. + +> **Framework note:** This guide uses React examples. Other frameworks (Angular, Lit, Solid, Svelte, Vue) use `createTable`, `injectTable`, or similar with the same options. + +```ts +//vanilla js +const table = _createTable({ _features, _rowModels: {}, columns, data }) + +//angular +this.table = injectTable({ _features, _rowModels: {}, columns: this.columns, data: this.data() }) + +//lit +const table = this.tableController.table({ _features, _rowModels: {}, columns, data }) + +//react +const table = useTable({ _features, _rowModels: {}, columns, data }) + +//solid +const table = createTable({ _features, _rowModels: {}, columns, get data() { return data() } }) + +//svelte +const table = createTable({ _features, _rowModels: {}, columns, data }) + +//vue +const table = useTable({ _features, _rowModels: {}, columns, data }) +``` + +So what's in the `table` instance? Let's take a look at what interactions we can have with the table instance. + +### Table State + +The table instance contains all of the table state, which can be accessed via the `table.store.state` API. Each table feature registers various states in the table state. For example, the row selection feature registers `rowSelection` state, the pagination feature registers `pagination` state, etc. + +Each feature will also have corresponding state setter APIs and state resetter APIs on the table instance. For example, the row selection feature will have a `setRowSelection` API and a `resetRowSelection`. + +```ts +table.store.state.rowSelection //read the row selection state +table.setRowSelection((old) => ({...old})) //set the row selection state +table.resetRowSelection() //reset the row selection state +``` + +This is covered in more detail in the [Table State Guides](../framework/react/guide/table-state) + +### Table APIs + +There are dozens of table APIs created by each feature to help you either read or mutate the table state in different ways. + +API reference docs for the core table instance and all other feature APIs can be found throughout the API docs. + +For example, you can find the core table instance API docs here: [Table API](../api/core/table#table-api) + +### Table Row Models + +There is a special set of table instance APIs for reading rows out of the table instance called row models. TanStack Table has advanced features where the rows that are generated may be very different than the array of `data` that you originally passed in. To learn more about the different row models that you can pass in as a table option, see the [Row Models Guide](./row-models). diff --git a/docs/guide/virtualization.md b/docs/guide/virtualization.md new file mode 100644 index 0000000000..6adc58c3ae --- /dev/null +++ b/docs/guide/virtualization.md @@ -0,0 +1,20 @@ +--- +title: Virtualization Guide +--- + +## Examples + +Want to skip to the implementation? Check out these examples: + +- [virtualized-columns](../framework/react/examples/virtualized-columns) +- [virtualized-rows (dynamic row height)](../framework/react/examples/virtualized-rows) +- [virtualized-rows (fixed row height)](https://tanstack.com/virtual/latest/docs/framework/react/examples/table) +- [virtualized-infinite-scrolling](../framework/react/examples/virtualized-infinite-scrolling) + +## API + +[TanStack Virtual Virtualizer API](https://tanstack.com/virtual/latest/docs/api/virtualizer) + +## Virtualization Guide + +The TanStack Table packages do not come with any virtualization APIs or features built-in, but TanStack Table can easily work with other virtualization libraries like [react-window](https://www.npmjs.com/package/react-window) or TanStack's own [TanStack Virtual](https://tanstack.com/virtual/v3). This guide will show some strategies for using TanStack Table with TanStack Virtual. diff --git a/docs/installation.md b/docs/installation.md new file mode 100644 index 0000000000..503f67f913 --- /dev/null +++ b/docs/installation.md @@ -0,0 +1,54 @@ +--- +title: Installation +--- + +Before we dig in to the API, let's get you set up! + +Install your table adapter as a dependency using your preferred package manager: + + + +react: @tanstack/react-table +vue: @tanstack/vue-table +solid: @tanstack/solid-table +svelte: @tanstack/svelte-table +angular: @tanstack/angular-table +lit: @tanstack/lit-table + + + + + +# React + +The `@tanstack/react-table` package works with React 16.8, React 17, React 18, and React 19. + +> [!NOTE] +> Even though the React adapter works with React 19, it may not work with the new React Compiler that's coming out alongside React 19. This may be fixed in future TanStack Table updates. + +# Vue + +The `@tanstack/vue-table` package works with Vue 3. + +# Solid + +The `@tanstack/solid-table` package works with Solid-JS 1. + +# Svelte + +The `@tanstack/svelte-table` package works with Svelte 3 and Svelte 4. + +> [!NOTE] +> There is not a built-in Svelte 5 adapter yet, but you can still use TanStack Table with Svelte 5 by installing the `@tanstack/table-core` package and using a custom adapter from the community. See this [PR](https://github.com/TanStack/table/pull/5403) for inspiration. + +# Angular + +The `@tanstack/angular-table` package works with Angular 17. The Angular adapter uses a new Angular Signal implementation. + +# Lit + +The `@tanstack/lit-table` package works with Lit 3. + + + +Don't see your favorite framework (or favorite version of your framework) listed? You can always just use the `@tanstack/table-core` package and build your own adapter in your own codebase. Usually, only a thin wrapper is needed to manage state and rendering for your specific framework. Browse the [source code](https://github.com/TanStack/table/tree/main/packages) of all of the other adapters to see how they work. diff --git a/docs/introduction.md b/docs/introduction.md new file mode 100644 index 0000000000..86fc18df01 --- /dev/null +++ b/docs/introduction.md @@ -0,0 +1,69 @@ +--- +title: Introduction +--- + +TanStack Table is a **Headless UI** library for building powerful tables & datagrids for TS/JS, React, Vue, Solid, and Svelte. + +## What is "headless" UI? + +**Headless UI** is a term for libraries and utilities that provide the logic, state, processing and API for UI elements and interactions, but **do not provide markup, styles, or pre-built implementations**. Scratching your head yet? 😉 Headless UI has a few main goals: + +The hardest parts of building complex UIs usually revolve around state, events, side-effects, data computation/management. By removing these concerns from the markup, styles and implementation details, our logic and components can be more modular and reusable. + +Building UI is a very branded and custom experience, even if that means choosing a design system or adhering to a design spec. To support this custom experience, component-based UI libraries need to support a massive (and seemingly endless) API surface around markup and style customization. Headless UI libraries decouple your logic from your UI + +When you use a headless UI library, the complex task of **data-processing, state-management, and business logic** are handled for you, leaving you to worry about higher-cardinality decisions that differ across implementations and use cases. + +> Want to dive deeper? [Read more about Headless UI](https://www.merrickchristensen.com/articles/headless-user-interface-components/). + +## Component-based libraries vs Headless libraries + +In the ecosystem of table/datagrid libraries, there are two main categories: + +- Component-based table libraries +- Headless table libraries + +### Which kind of table library should I use? + +Each approach has subtle tradeoffs. Understanding these subtleties will help you make the right decision for your application and team. + +### Component-based Table Libraries + +Component-based table libraries will typically supply you with a feature-rich drop-in solution and ready-to-use components/markup complete with styles/theming. [AG Grid](https://ag-grid.com/react-data-grid/?utm_source=reacttable&utm_campaign=githubreacttable) is a great example of this type of table library. + +**Pros:** + +- Ship with ready-to-use markup/styles +- Little setup required +- Turn-key experience + +**Cons:** + +- Less control over markup +- Custom styles are typically theme-based +- Larger bundle-sizes +- Highly coupled to framework adapters and platforms + +**If you want a ready-to-use table and design/bundle-size are not hard requirements**, then you should consider using a component-based table library. + +There are a lot of component-based table libraries out there, but we believe [AG Grid](https://ag-grid.com/react-data-grid/?utm_source=reacttable&utm_campaign=githubreacttable) is the gold standard and is by far our favorite grid-sibling (don't tell the others 🤫). + +### Headless Table Libraries + +Headless table libraries will typically supply you with functions, state, utilities and event listeners to build your own table markup or attach to existing table markups. + +**Pros:** + +- Full control over markup and styles +- Supports all styling patterns (CSS, CSS-in-JS, UI libraries, etc) +- Smaller bundle-sizes +- Portable. Run anywhere JS runs! + +**Cons:** + +- More setup required +- No markup, styles or themes provided + +**If you want a lighter-weight table or full control over the design**, then you should consider using a headless table library. + +There are very few headless table libraries out there and obviously, **TanStack Table** is our favorite! diff --git a/docs/overview.md b/docs/overview.md new file mode 100644 index 0000000000..e3026346e9 --- /dev/null +++ b/docs/overview.md @@ -0,0 +1,63 @@ +--- +title: Overview +--- + +TanStack Table's core is **framework agnostic**, which means its API is the same regardless of the framework you're using. Adapters are provided to make working with the table core easier depending on your framework. See the Adapters menu for available adapters. + +## Typescript + +While TanStack Table is written in [TypeScript](https://www.typescriptlang.org/), using TypeScript in your application is optional (but recommended as it comes with outstanding benefits to both you and your codebase) + +If you use TypeScript, you will get top-notch type safety and editor autocomplete for all table APIs and state. + +## Headless + +As it was mentioned extensively in the [Intro](./introduction) section, TanStack Table is **headless**. This means that it doesn't render any DOM elements, and instead relies on you, the UI/UX developer to provide the table's markup and styles. This is a great way to build a table that can be used in any UI framework, including React, Vue, Solid, Svelte, Angular, and even JS-to-native platforms like React Native! + +## Agnostic + +Since TanStack Table is headless and runs on a vanilla JavaScript core, it is agnostic in a couple of ways: + +1. TanStack Table is **Framework Agnostic**, which means you can use it with any JavaScript framework (or library) that you want. TanStack Table provides ready-to-use adapters for React, Vue, Solid, Svelte out of the box, but you can create your own adapter if you need to. +2. TanStack Table is **CSS / Component Library Agnostic**, which means that you can use TanStack Table with whatever CSS strategy or component library you want. TanStack Table itself does not render any table markup or styles. You bring your own! Want to use Tailwind or ShadCN? No problem! Want to use Material UI or Bootstrap? No problem! Have your own custom design system? TanStack Table was made for you! + +## Core Objects and Types + +The table core uses the following abstractions, commonly exposed by adapters: + +- [Data](./guide/data) - The core data array you provide the table +- [Column Defs](./guide/column-defs): Objects used to configure a column and its data model, display templates, and more +- [Table Instance](./guide/tables): The core table object containing both state and API +- [Row Models](./guide/row-models): How the `data` array is transformed into useful rows depending on the features you are using +- [Rows](./guide/rows): Each row mirrors its respective row data and provides row-specific APIs +- [Cells](./guide/cells): Each cell mirrors its respective row-column intersection and provides cell-specific APIs +- [Header Groups](./guide/header-groups): Header groups are computed slices of nested header levels, each containing a group of headers +- [Headers](./guide/headers): Each header is either directly associated with or derived from its column def and provides header-specific APIs +- [Columns](./guide/columns): Each column mirrors its respective column def and also provides column-specific APIs + +## Features + +TanStack Table will help you build just about any type of table you can imagine. It has built-in state and APIs for the following features: + +- [Column Faceting](./guide/column-faceting) - List unique lists of column values or min/max values for a column +- [Column Filtering](./guide/column-filtering) - Filter rows based on search values for a column +- [Column Grouping](./guide/grouping) - Group columns together, run aggregations, and more +- [Column Ordering](./guide/column-ordering) - Dynamically change the order of columns +- [Column Pinning](./guide/column-pinning) - Pin (Freeze) columns to the left or right of the table +- [Column Sizing](./guide/column-sizing) - Dynamically change the size of columns (column resizing handles) +- [Column Visibility](./guide/column-visibility) - Hide/show columns +- [Global Faceting](./guide/global-faceting) - List unique lists of column values or min/max values for the entire table +- [Global Filtering](./guide/global-filtering) - Filter rows based on search values for the entire table +- [Row Expanding](./guide/expanding) - Expand/collapse rows (sub-rows) +- [Row Pagination](./guide/pagination) - Paginate rows +- [Row Pinning](./guide/row-pinning) - Pin (Freeze) rows to the top or bottom of the table +- [Row Selection](./guide/row-selection) - Select/deselect rows (checkboxes) +- [Row Sorting](./guide/sorting) - Sort rows by column values + +These are just some of the capabilities that you can build with TanStack Table. There are many more features that are possible with TanStack Table that you can add along-side the built-in features. + +[Virtualization](./guide/virtualization) is an example of a feature that is not built-in to TanStack Table, but can be achieved by using another library (like [TanStack Virtual](https://tanstack.com/virtual/v3)) and adding it along-side your other table rendering logic. + +TanStack Table also supports [Custom Features](./guide/custom-features) (plugins) that you can use to modify the table instance to add your own custom logic to the table in a more integrated way. + +And of course, you can just write your own state and hooks to add whatever other features you want for your table. The features from the TanStack Table core are just a solid foundation to build on, with a large focus on performance and DX. diff --git a/docs/package.json b/docs/package.json deleted file mode 100644 index 3cc6127e10..0000000000 --- a/docs/package.json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "name": "new", - "version": "0.1.0", - "private": true, - "devDependencies": { - "autoprefixer": "^6.7.0", - "babel-cli": "6.14.0", - "babel-eslint": "6.1.2", - "babel-preset-es2015": "6.14.0", - "babel-preset-react": "6.11.1", - "babel-preset-stage-2": "6.13.0", - "eslint": "^4.1.1", - "eslint-config-standard": "^10.2.1", - "eslint-plugin-class-property": "^1.0.6", - "eslint-plugin-import": "^2.8.0", - "eslint-plugin-jsx-a11y": "^6.0.2", - "eslint-plugin-node": "^5.2.1", - "eslint-plugin-promise": "^3.6.0", - "eslint-plugin-react": "^7.4.0", - "eslint-plugin-standard": "^3.0.1", - "html-element-attributes": "^1.3.0", - "match-sorter": "^1.8.0", - "npm-run-all": "^3.1.1", - "onchange": "^3.0.2", - "postcss-cli": "^2.6.0", - "react": "^15.4.2", - "react-dom": "^15.4.2", - "react-json-tree": "^0.10.9", - "rimraf": "^2.6.1", - "standard": "^10.0.2", - "stylus": "^0.54.5" - }, - "dependencies": { - "eslint-config-react-tools": "^1.0.10", - "github-markdown-css": "^2.6.0", - "marked": "^0.3.6", - "namor": "^1.0.1", - "raw-loader": "^0.5.1", - "react": "^15.5.4", - "react-dom": "^15.5.4", - "react-json-tree": "^0.10.9", - "react-script": "^2.0.5", - "react-scripts": "^0.9.5", - "react-story": "^0.0.10", - "shortid": "^2.2.8" - }, - "scripts": { - "start": "react-scripts start", - "build": "react-scripts build", - "test": "react-scripts test --env=jsdom", - "eject": "react-scripts eject" - } -} diff --git a/docs/public/au_500_tree.json b/docs/public/au_500_tree.json deleted file mode 100644 index e67eed69b2..0000000000 --- a/docs/public/au_500_tree.json +++ /dev/null @@ -1,6502 +0,0 @@ -[ - { - "first_name": "Soledad", - "last_name": "Mockus", - "company_name": "Sinclair Machine Products Inc", - "address": "75 Elm Rd #1190", - "state": "ACT", - "post": 2600, - "city": "Barton", - "phone1": "02-1291-8182", - "phone2": "0444-126-746", - "email": "soledad_mockus@yahoo.com", - "web": "http://www.sinclairmachineproductsinc.com.au" - }, - { - "first_name": "Dana", - "last_name": "Vock", - "company_name": "Fried, Monte Esq", - "address": "49 Walnut St", - "state": "ACT", - "post": 2600, - "city": "Yarralumla", - "phone1": "02-6689-1150", - "phone2": "0411-398-917", - "email": "dana_vock@yahoo.com", - "web": "http://www.friedmonteesq.com.au" - }, - { - "first_name": "Roy", - "last_name": "Nybo", - "company_name": "Phoenix Phototype", - "address": "823 Fishers Ln", - "state": "ACT", - "post": 2603, - "city": "Red Hill", - "phone1": "02-5311-7778", - "phone2": "0416-394-795", - "email": "rnybo@nybo.net.au", - "web": "http://www.phoenixphototype.com.au" - }, - { - "first_name": "Annamae", - "last_name": "Lothridge", - "company_name": "Highland Meadows Golf Club", - "address": "584 Meridian St #997", - "state": "ACT", - "post": 2608, - "city": "Civic Square", - "phone1": "02-1919-3941", - "phone2": "0495-759-817", - "email": "alothridge@hotmail.com", - "web": "http://www.highlandmeadowsgolfclub.com.au" - }, - { - "first_name": "Katheryn", - "last_name": "Lamers", - "company_name": "Sonoco Products Co", - "address": "62171 E 6th Ave", - "state": "ACT", - "post": 2609, - "city": "Fyshwick", - "phone1": "02-4885-1611", - "phone2": "0497-455-126", - "email": "katheryn_lamers@gmail.com", - "web": "http://www.sonocoproductsco.com.au" - }, - { - "first_name": "Jamie", - "last_name": "Kushnir", - "company_name": "Bell Electric Co", - "address": "3216 W Wabansia Ave", - "state": "ACT", - "post": 2901, - "city": "Tuggeranong Dc", - "phone1": "02-4623-8120", - "phone2": "0426-830-817", - "email": "jamie@kushnir.net.au", - "web": "http://www.bellelectricco.com.au" - }, - { - "first_name": "Wenona", - "last_name": "Carmel", - "company_name": "Maier, Kristine M", - "address": "44 Bush St", - "state": "NSW", - "post": 1220, - "city": "Grosvenor Place", - "phone1": "02-2832-1545", - "phone2": "0439-849-209", - "email": "wenona@gmail.com", - "web": "http://www.maierkristinem.com.au" - }, - { - "first_name": "Deane", - "last_name": "Haag", - "company_name": "Malsbary Mfg Co", - "address": "9 Hamilton Blvd #299", - "state": "NSW", - "post": 1235, - "city": "Sydney South", - "phone1": "02-9718-2944", - "phone2": "0453-828-758", - "email": "dhaag@hotmail.com", - "web": "http://www.malsbarymfgco.com.au" - }, - { - "first_name": "Nenita", - "last_name": "Mckenna", - "company_name": "Southern Imperial Inc", - "address": "709 New Market St", - "state": "NSW", - "post": 1455, - "city": "Botany", - "phone1": "02-5059-2649", - "phone2": "0419-730-349", - "email": "nmckenna@yahoo.com", - "web": "http://www.southernimperialinc.com.au" - }, - { - "first_name": "Mayra", - "last_name": "Bena", - "company_name": "Buelt, David L Esq", - "address": "808 Glen Cove Ave", - "state": "NSW", - "post": 1595, - "city": "Lane Cove", - "phone1": "02-1455-6085", - "phone2": "0453-666-885", - "email": "mayra.bena@gmail.com", - "web": "http://www.bueltdavidlesq.com.au" - }, - { - "first_name": "Samuel", - "last_name": "Arellanes", - "company_name": "Ryan, Barry M Esq", - "address": "286 Santa Rosa Ave", - "state": "NSW", - "post": 1595, - "city": "Lane Cove", - "phone1": "02-7995-6787", - "phone2": "0446-710-661", - "email": "samuel.arellanes@arellanes.net.au", - "web": "http://www.ryanbarrymesq.com.au" - }, - { - "first_name": "Princess", - "last_name": "Saffo", - "company_name": "Asian Jewelry", - "address": "12398 Duluth St", - "state": "NSW", - "post": 1835, - "city": "Auburn", - "phone1": "02-2656-6234", - "phone2": "0467-758-219", - "email": "princess_saffo@hotmail.com", - "web": "http://www.asianjewelry.com.au" - }, - { - "first_name": "Michael", - "last_name": "Orehek", - "company_name": "Robinson, Michael C Esq", - "address": "892 Sw Broadway #8", - "state": "NSW", - "post": 2000, - "city": "Millers Point", - "phone1": "02-1919-1709", - "phone2": "0482-613-598", - "email": "michael_orehek@gmail.com", - "web": "http://www.robinsonmichaelcesq.com.au" - }, - { - "first_name": "Casandra", - "last_name": "Gordis", - "company_name": "Carlyle Abstract Co", - "address": "6 Walnut St", - "state": "NSW", - "post": 2008, - "city": "Chippendale", - "phone1": "02-5808-6388", - "phone2": "0418-327-906", - "email": "casandra_gordis@gordis.com.au", - "web": "http://www.carlyleabstractco.com.au" - }, - { - "first_name": "Leonor", - "last_name": "Prez", - "company_name": "Vinco Furniture Inc", - "address": "968 Delaware Ave", - "state": "NSW", - "post": 2017, - "city": "Waterloo", - "phone1": "02-7463-8776", - "phone2": "0466-155-348", - "email": "lprez@prez.com.au", - "web": "http://www.vincofurnitureinc.com.au" - }, - { - "first_name": "Bernadine", - "last_name": "Elamin", - "company_name": "Tarix Printing", - "address": "61550 S Figueroa St", - "state": "NSW", - "post": 2024, - "city": "Waverley", - "phone1": "02-1815-8700", - "phone2": "0448-195-542", - "email": "bernadine_elamin@yahoo.com", - "web": "http://www.tarixprinting.com.au" - }, - { - "first_name": "Cherilyn", - "last_name": "Fraize", - "company_name": "Witchs Brew", - "address": "84826 Plaza Dr", - "state": "NSW", - "post": 2030, - "city": "Rose Bay North", - "phone1": "02-4873-1914", - "phone2": "0468-743-337", - "email": "cherilyn_fraize@fraize.net.au", - "web": "http://www.witchsbrew.com.au" - }, - { - "first_name": "Katie", - "last_name": "Magro", - "company_name": "Jones, Andrew D Esq", - "address": "8 E North Ave", - "state": "NSW", - "post": 2035, - "city": "Pagewood", - "phone1": "02-7265-9702", - "phone2": "0439-832-641", - "email": "katie_magro@gmail.com", - "web": "http://www.jonesandrewdesq.com.au" - }, - { - "first_name": "Beckie", - "last_name": "Apodace", - "company_name": "Reich, Richard J Esq", - "address": "26 Ripley St #5444", - "state": "NSW", - "post": 2068, - "city": "Middle Cove", - "phone1": "02-5630-3114", - "phone2": "0469-490-273", - "email": "bapodace@gmail.com", - "web": "http://www.reichrichardjesq.com.au" - }, - { - "first_name": "Nickole", - "last_name": "Derenzis", - "company_name": "Lehigh Furn Divsn Lehigh", - "address": "2 Pompton Ave", - "state": "NSW", - "post": 2082, - "city": "Berowra Heights", - "phone1": "02-5573-6627", - "phone2": "0480-120-597", - "email": "nderenzis@hotmail.com", - "web": "http://www.lehighfurndivsnlehigh.com.au" - }, - { - "first_name": "Fidelia", - "last_name": "Dampier", - "company_name": "Signs Now", - "address": "947 W Harrison St #640", - "state": "NSW", - "post": 2083, - "city": "Dangar Island", - "phone1": "02-8035-9997", - "phone2": "0478-179-538", - "email": "fidelia_dampier@gmail.com", - "web": "http://www.signsnow.com.au" - }, - { - "first_name": "Oren", - "last_name": "Lobosco", - "company_name": "Vei Inc", - "address": "1585 Salem Church Rd #59", - "state": "NSW", - "post": 2083, - "city": "Dangar Island", - "phone1": "02-5046-1307", - "phone2": "0495-838-492", - "email": "olobosco@hotmail.com", - "web": "http://www.veiinc.com.au" - }, - { - "first_name": "Lou", - "last_name": "Kriner", - "company_name": "Joondeph, Jerome J Esq", - "address": "39 Broad St", - "state": "NSW", - "post": 2092, - "city": "Seaforth", - "phone1": "02-7328-3350", - "phone2": "0496-387-592", - "email": "lou.kriner@hotmail.com", - "web": "http://www.joondephjeromejesq.com.au" - }, - { - "first_name": "Lachelle", - "last_name": "Andrzejewski", - "company_name": "Lucas Cntrl Systems Prod Deeco", - "address": "262 Montauk Blvd", - "state": "NSW", - "post": 2126, - "city": "Cherrybrook", - "phone1": "02-3416-9617", - "phone2": "0453-493-910", - "email": "lachelle.andrzejewski@andrzejewski.com.au", - "web": "http://www.lucascntrlsystemsproddeeco.com.au" - }, - { - "first_name": "Tommy", - "last_name": "Gennusa", - "company_name": "Cooper And Raley", - "address": "2 New Brooklyn Rd", - "state": "NSW", - "post": 2138, - "city": "Concord West", - "phone1": "02-5444-1961", - "phone2": "0498-290-826", - "email": "tommy@hotmail.com", - "web": "http://www.cooperandraley.com.au" - }, - { - "first_name": "Aide", - "last_name": "Ghera", - "company_name": "Nathaniel Electronics", - "address": "22 Livingston Ave", - "state": "NSW", - "post": 2138, - "city": "Rhodes", - "phone1": "02-3738-7508", - "phone2": "0443-448-467", - "email": "aide.ghera@ghera.com.au", - "web": "http://www.nathanielelectronics.com.au" - }, - { - "first_name": "Novella", - "last_name": "Fritch", - "company_name": "Voils, Otis V", - "address": "5 Ellestad Dr", - "state": "NSW", - "post": 2145, - "city": "Girraween", - "phone1": "02-2612-1455", - "phone2": "0458-731-791", - "email": "nfritch@fritch.com.au", - "web": "http://www.voilsotisv.com.au" - }, - { - "first_name": "Sherman", - "last_name": "Mahmud", - "company_name": "Gencheff, Nelson E Do", - "address": "9 Memorial Pky Nw", - "state": "NSW", - "post": 2150, - "city": "Harris Park", - "phone1": "02-2621-3361", - "phone2": "0468-488-918", - "email": "sherman@mahmud.com.au", - "web": "http://www.gencheffnelsonedo.com.au" - }, - { - "first_name": "Madelyn", - "last_name": "Maestri", - "company_name": "Mervis Steel Co", - "address": "60 S 4th St", - "state": "NSW", - "post": 2155, - "city": "Rouse Hill", - "phone1": "02-2129-8131", - "phone2": "0413-115-438", - "email": "madelyn.maestri@yahoo.com", - "web": "http://www.mervissteelco.com.au" - }, - { - "first_name": "Ben", - "last_name": "Kellman", - "company_name": "Anderson, Julie A Esq", - "address": "30024 Whipple Ave Nw", - "state": "NSW", - "post": 2159, - "city": "Berrilee", - "phone1": "02-7968-9243", - "phone2": "0441-733-809", - "email": "ben_kellman@kellman.net.au", - "web": "http://www.andersonjulieaesq.com.au" - }, - { - "first_name": "Sharita", - "last_name": "Kruk", - "company_name": "Long, Robert B Jr", - "address": "8808 Northern Blvd", - "state": "NSW", - "post": 2160, - "city": "Merrylands", - "phone1": "02-7386-4544", - "phone2": "0442-976-132", - "email": "sharita_kruk@gmail.com", - "web": "http://www.longrobertbjr.com.au" - }, - { - "first_name": "Maryrose", - "last_name": "Cove", - "company_name": "Brown Bear Bait Company", - "address": "1 Vogel Rd", - "state": "NSW", - "post": 2166, - "city": "Cabramatta", - "phone1": "02-8010-8344", - "phone2": "0440-811-454", - "email": "mcove@hotmail.com", - "web": "http://www.brownbearbaitcompany.com.au" - }, - { - "first_name": "Johanna", - "last_name": "Saffer", - "company_name": "Springer Industrial Equip Inc", - "address": "750 Lancaster Ave", - "state": "NSW", - "post": 2194, - "city": "Campsie", - "phone1": "02-5970-1748", - "phone2": "0477-424-229", - "email": "johanna@yahoo.com", - "web": "http://www.springerindustrialequipinc.com.au" - }, - { - "first_name": "Kimberely", - "last_name": "Weyman", - "company_name": "Scientific Agrcltl Svc Inc", - "address": "7721 Harrison St", - "state": "NSW", - "post": 2208, - "city": "Kingsway West", - "phone1": "02-7091-8948", - "phone2": "0441-151-810", - "email": "kweyman@weyman.com.au", - "web": "http://www.scientificagrcltlsvcinc.com.au" - }, - { - "first_name": "Claudia", - "last_name": "Gawrych", - "company_name": "Abe Goldstein Ofc Furn", - "address": "3 Wall St #26", - "state": "NSW", - "post": 2229, - "city": "Lilli Pilli", - "phone1": "02-4246-3092", - "phone2": "0465-885-293", - "email": "claudia@gmail.com", - "web": "http://www.abegoldsteinofcfurn.com.au" - }, - { - "first_name": "German", - "last_name": "Dones", - "company_name": "Oaz Communications", - "address": "9 N Nevada Ave", - "state": "NSW", - "post": 2232, - "city": "Woronora", - "phone1": "02-2393-3289", - "phone2": "0495-882-447", - "email": "german@gmail.com", - "web": "http://www.oazcommunications.com.au" - }, - { - "first_name": "Rupert", - "last_name": "Hinkson", - "company_name": "Northwestern Mutual Life Ins", - "address": "1 E 17th St", - "state": "NSW", - "post": 2250, - "city": "East Gosford", - "phone1": "02-7160-2066", - "phone2": "0489-430-358", - "email": "rupert_hinkson@hinkson.net.au", - "web": "http://www.northwesternmutuallifeins.com.au" - }, - { - "first_name": "Darnell", - "last_name": "Moothart", - "company_name": "Melco Embroidery Systems", - "address": "40 E 19th Ave", - "state": "NSW", - "post": 2257, - "city": "Empire Bay", - "phone1": "02-3996-9188", - "phone2": "0419-656-117", - "email": "darnell_moothart@yahoo.com", - "web": "http://www.melcoembroiderysystems.com.au" - }, - { - "first_name": "Cordie", - "last_name": "Meikle", - "company_name": "Shapiro Bag Company", - "address": "40809 Rockburn Hill Rd", - "state": "NSW", - "post": 2259, - "city": "Hamlyn Terrace", - "phone1": "02-8727-4906", - "phone2": "0441-386-796", - "email": "cordie.meikle@hotmail.com", - "web": "http://www.shapirobagcompany.com.au" - }, - { - "first_name": "Camellia", - "last_name": "Pylant", - "company_name": "Blackley, William J Pa", - "address": "570 W Pine St", - "state": "NSW", - "post": 2259, - "city": "Tuggerawong", - "phone1": "02-5171-4345", - "phone2": "0423-446-913", - "email": "camellia_pylant@gmail.com", - "web": "http://www.blackleywilliamjpa.com.au" - }, - { - "first_name": "Jamal", - "last_name": "Korczynski", - "company_name": "Helricks Inc", - "address": "404 Broxton Ave", - "state": "NSW", - "post": 2261, - "city": "Bateau Bay", - "phone1": "02-3877-9654", - "phone2": "0427-970-674", - "email": "jamal_korczynski@gmail.com", - "web": "http://www.helricksinc.com.au" - }, - { - "first_name": "Holley", - "last_name": "Worland", - "company_name": "Lord Aeck & Sargent Architects", - "address": "2 Route 9", - "state": "NSW", - "post": 2262, - "city": "Blue Haven", - "phone1": "02-9885-9593", - "phone2": "0469-808-491", - "email": "holley.worland@hotmail.com", - "web": "http://www.lordaecksargentarchitects.com.au" - }, - { - "first_name": "Julio", - "last_name": "Puccini", - "company_name": "Streator Onized Fed Crdt Un", - "address": "2244 Franquette Ave", - "state": "NSW", - "post": 2263, - "city": "Gorokan", - "phone1": "02-5632-9914", - "phone2": "0452-766-262", - "email": "julio@gmail.com", - "web": "http://www.streatoronizedfedcrdtun.com.au" - }, - { - "first_name": "Lauran", - "last_name": "Tovmasyan", - "company_name": "United Christian Cmnty Crdt Un", - "address": "199 Maple Ave", - "state": "NSW", - "post": 2284, - "city": "Boolaroo", - "phone1": "02-2546-5344", - "phone2": "0459-680-488", - "email": "ltovmasyan@tovmasyan.net.au", - "web": "http://www.unitedchristiancmntycrdtun.com.au" - }, - { - "first_name": "Jacklyn", - "last_name": "Wojnar", - "company_name": "Nationwide Insurance", - "address": "16949 Harristown Rd", - "state": "NSW", - "post": 2287, - "city": "Summer Hill", - "phone1": "02-6287-8787", - "phone2": "0434-382-805", - "email": "jacklyn@hotmail.com", - "web": "http://www.nationwideinsurance.com.au" - }, - { - "first_name": "Norah", - "last_name": "Daleo", - "company_name": "Gateway Refrigeration", - "address": "754 Sammis Ave", - "state": "NSW", - "post": 2289, - "city": "Kotara Fair", - "phone1": "02-5322-6127", - "phone2": "0462-327-613", - "email": "ndaleo@daleo.net.au", - "web": "http://www.gatewayrefrigeration.com.au" - }, - { - "first_name": "Anastacia", - "last_name": "Carranzo", - "company_name": "Debbies Golden Touch", - "address": "654 Se 29th St", - "state": "NSW", - "post": 2298, - "city": "Waratah West", - "phone1": "02-6078-3417", - "phone2": "0481-193-115", - "email": "anastacia@yahoo.com", - "web": "http://www.debbiesgoldentouch.com.au" - }, - { - "first_name": "Lashawn", - "last_name": "Urion", - "company_name": "U Stor", - "address": "6 Argyle Rd", - "state": "NSW", - "post": 2300, - "city": "Bar Beach", - "phone1": "02-4794-6673", - "phone2": "0436-337-750", - "email": "lurion@yahoo.com", - "web": "http://www.ustor.com.au" - }, - { - "first_name": "Dorinda", - "last_name": "Markoff", - "company_name": "Alumi Span Inc", - "address": "5 Columbia Pike", - "state": "NSW", - "post": 2304, - "city": "Mayfield East", - "phone1": "02-6529-9317", - "phone2": "0412-153-776", - "email": "dorinda_markoff@hotmail.com", - "web": "http://www.alumispaninc.com.au" - }, - { - "first_name": "Florinda", - "last_name": "Gudgel", - "company_name": "Transit Cargo Services Inc", - "address": "53597 W Clarendon Ave", - "state": "NSW", - "post": 2311, - "city": "Halton", - "phone1": "02-2501-8301", - "phone2": "0444-376-606", - "email": "fgudgel@gudgel.com.au", - "web": "http://www.transitcargoservicesinc.com.au" - }, - { - "first_name": "Keva", - "last_name": "Moehring", - "company_name": "Rapid Reproductions Printing", - "address": "37564 Grace Ln", - "state": "NSW", - "post": 2317, - "city": "Salamander Bay", - "phone1": "02-9187-4769", - "phone2": "0448-465-944", - "email": "keva.moehring@moehring.net.au", - "web": "http://www.rapidreproductionsprinting.com.au" - }, - { - "first_name": "Della", - "last_name": "Selestewa", - "company_name": "Aztech Controls Inc", - "address": "64 Prairie Ave", - "state": "NSW", - "post": 2321, - "city": "Gillieston Heights", - "phone1": "02-4885-8382", - "phone2": "0456-162-659", - "email": "della.selestewa@gmail.com", - "web": "http://www.aztechcontrolsinc.com.au" - }, - { - "first_name": "Verdell", - "last_name": "Garness", - "company_name": "Ronald Massingill Pc", - "address": "39 Plummer St", - "state": "NSW", - "post": 2322, - "city": "Thornton", - "phone1": "02-6291-7620", - "phone2": "0474-367-875", - "email": "verdell.garness@yahoo.com", - "web": "http://www.ronaldmassingillpc.com.au" - }, - { - "first_name": "Karima", - "last_name": "Cheever", - "company_name": "Kwik Kopy Printing & Copying", - "address": "20907 65s S", - "state": "NSW", - "post": 2322, - "city": "Woodberry", - "phone1": "02-5977-8561", - "phone2": "0416-963-557", - "email": "karima_cheever@hotmail.com", - "web": "http://www.kwikkopyprintingcopying.com.au" - }, - { - "first_name": "Micheal", - "last_name": "Ocken", - "company_name": "New Orleans Credit Service Inc", - "address": "4 E Aven #284", - "state": "NSW", - "post": 2323, - "city": "Freemans Waterhole", - "phone1": "02-9828-4921", - "phone2": "0449-668-295", - "email": "micheal.ocken@ocken.net.au", - "web": "http://www.neworleanscreditserviceinc.com.au" - }, - { - "first_name": "Jerrod", - "last_name": "Luening", - "company_name": "Mcmillan, Regina E Esq", - "address": "6629 Main St", - "state": "NSW", - "post": 2324, - "city": "Tea Gardens", - "phone1": "02-9554-9632", - "phone2": "0451-857-511", - "email": "jerrod_luening@luening.com.au", - "web": "http://www.mcmillanreginaeesq.com.au" - }, - { - "first_name": "Ramonita", - "last_name": "Picotte", - "company_name": "Art Material Services Inc", - "address": "504 Steve Dr", - "state": "NSW", - "post": 2326, - "city": "Weston", - "phone1": "02-4360-8467", - "phone2": "0479-654-997", - "email": "ramonita_picotte@yahoo.com", - "web": "http://www.artmaterialservicesinc.com.au" - }, - { - "first_name": "Tori", - "last_name": "Tepley", - "company_name": "Mcwhirter Realty Corp", - "address": "1036 Malone Rd", - "state": "NSW", - "post": 2329, - "city": "Uarbry", - "phone1": "02-2493-1870", - "phone2": "0449-807-281", - "email": "tori@tepley.net.au", - "web": "http://www.mcwhirterrealtycorp.com.au" - }, - { - "first_name": "Jodi", - "last_name": "Naifeh", - "company_name": "Cahill, Steven J Esq", - "address": "89 N Himes Ave", - "state": "NSW", - "post": 2330, - "city": "Dural", - "phone1": "02-6193-5184", - "phone2": "0488-646-644", - "email": "jodi@hotmail.com", - "web": "http://www.cahillstevenjesq.com.au" - }, - { - "first_name": "Elliot", - "last_name": "Scatton", - "company_name": "Nilad Machining", - "address": "5 W Allen St", - "state": "NSW", - "post": 2333, - "city": "Mccullys Gap", - "phone1": "02-3647-9507", - "phone2": "0481-878-290", - "email": "elliot.scatton@hotmail.com", - "web": "http://www.niladmachining.com.au" - }, - { - "first_name": "Veronika", - "last_name": "Buchauer", - "company_name": "Adkins, Russell Esq", - "address": "6 Flex Ave", - "state": "NSW", - "post": 2339, - "city": "Willow Tree", - "phone1": "02-4202-5191", - "phone2": "0434-402-895", - "email": "veronika.buchauer@buchauer.net.au", - "web": "http://www.adkinsrussellesq.com.au" - }, - { - "first_name": "Rosamond", - "last_name": "Amlin", - "company_name": "Donovan, William P Esq", - "address": "5399 Mcwhorter Rd", - "state": "NSW", - "post": 2340, - "city": "Calala", - "phone1": "02-8007-5034", - "phone2": "0438-251-615", - "email": "rosamond.amlin@gmail.com", - "web": "http://www.donovanwilliampesq.com.au" - }, - { - "first_name": "Tamekia", - "last_name": "Kajder", - "company_name": "Santek Inc", - "address": "16 Talmadge Rd", - "state": "NSW", - "post": 2340, - "city": "West Tamworth", - "phone1": "02-7498-8576", - "phone2": "0418-218-423", - "email": "tamekia_kajder@yahoo.com", - "web": "http://www.santekinc.com.au" - }, - { - "first_name": "Janessa", - "last_name": "Ruthers", - "company_name": "Mackraft Signs", - "address": "1255 W Passaic St #1553", - "state": "NSW", - "post": 2372, - "city": "Bolivia", - "phone1": "02-2367-6845", - "phone2": "0410-358-989", - "email": "janessa@yahoo.com", - "web": "http://www.mackraftsigns.com.au" - }, - { - "first_name": "Quinn", - "last_name": "Weissbrodt", - "company_name": "Economy Stainless Supl Co Inc", - "address": "7659 Market St", - "state": "NSW", - "post": 2381, - "city": "Premer", - "phone1": "02-7239-9923", - "phone2": "0432-253-912", - "email": "qweissbrodt@weissbrodt.com.au", - "web": "http://www.economystainlesssuplcoinc.com.au" - }, - { - "first_name": "Julio", - "last_name": "Mikel", - "company_name": "Lombardi Bros Inc", - "address": "2803 N Catalina Ave", - "state": "NSW", - "post": 2388, - "city": "Pilliga", - "phone1": "02-6995-9902", - "phone2": "0464-594-316", - "email": "julio.mikel@mikel.net.au", - "web": "http://www.lombardibrosinc.com.au" - }, - { - "first_name": "Winifred", - "last_name": "Kingshott", - "company_name": "Remc South Eastern", - "address": "532 Saint Marks Ct", - "state": "NSW", - "post": 2420, - "city": "Marshdale", - "phone1": "02-5318-1342", - "phone2": "0471-558-187", - "email": "winifred.kingshott@yahoo.com", - "web": "http://www.remcsoutheastern.com.au" - }, - { - "first_name": "Colene", - "last_name": "Tolbent", - "company_name": "Saw Repair & Supply Co", - "address": "891 Union Pacific Ave #8463", - "state": "NSW", - "post": 2422, - "city": "Gloucester", - "phone1": "02-4376-1104", - "phone2": "0466-541-467", - "email": "colene.tolbent@tolbent.net.au", - "web": "http://www.sawrepairsupplyco.com.au" - }, - { - "first_name": "Santos", - "last_name": "Wisenbaker", - "company_name": "Brattleboro Printing Inc", - "address": "67729 180th St", - "state": "NSW", - "post": 2425, - "city": "Allworth", - "phone1": "02-2957-4812", - "phone2": "0411-294-588", - "email": "swisenbaker@wisenbaker.net.au", - "web": "http://www.brattleboroprintinginc.com.au" - }, - { - "first_name": "Desmond", - "last_name": "Amuso", - "company_name": "Carson, Scott W Esq", - "address": "79 Runamuck Pl", - "state": "NSW", - "post": 2429, - "city": "Caparra", - "phone1": "02-1706-8506", - "phone2": "0427-106-677", - "email": "desmond@hotmail.com", - "web": "http://www.carsonscottwesq.com.au" - }, - { - "first_name": "Patria", - "last_name": "Popa", - "company_name": "Blaney Sheet Metal", - "address": "21 W 2nd St", - "state": "NSW", - "post": 2429, - "city": "Killabakh", - "phone1": "02-6522-3993", - "phone2": "0493-319-728", - "email": "patria.popa@gmail.com", - "web": "http://www.blaneysheetmetal.com.au" - }, - { - "first_name": "Ben", - "last_name": "Majorga", - "company_name": "Voyager Travel Service", - "address": "13904 S 35th St", - "state": "NSW", - "post": 2429, - "city": "Wherrol Flat", - "phone1": "02-8171-9051", - "phone2": "0462-648-621", - "email": "ben.majorga@hotmail.com", - "web": "http://www.voyagertravelservice.com.au" - }, - { - "first_name": "Clarence", - "last_name": "Gabbert", - "company_name": "M C Publishing", - "address": "35983 Daubert St", - "state": "NSW", - "post": 2440, - "city": "Verges Creek", - "phone1": "02-4776-1384", - "phone2": "0486-302-652", - "email": "clarence.gabbert@gmail.com", - "web": "http://www.mcpublishing.com.au" - }, - { - "first_name": "Carlota", - "last_name": "Gephardt", - "company_name": "Ultimate In Womens Apparel The", - "address": "96605 Pioneer Rd", - "state": "NSW", - "post": 2441, - "city": "Kundabung", - "phone1": "02-5078-4389", - "phone2": "0415-230-654", - "email": "carlota.gephardt@gephardt.com.au", - "web": "http://www.ultimateinwomensapparelthe.com.au" - }, - { - "first_name": "Crista", - "last_name": "Padua", - "company_name": "Breathitt Fnrl Home & Mnmt Co", - "address": "1607 Laurel St", - "state": "NSW", - "post": 2443, - "city": "North Haven", - "phone1": "02-9472-5814", - "phone2": "0471-602-916", - "email": "crista_padua@gmail.com", - "web": "http://www.breathittfnrlhomemnmtco.com.au" - }, - { - "first_name": "Genevive", - "last_name": "Sanborn", - "company_name": "Central Hudson Ent Corp", - "address": "78 31st St", - "state": "NSW", - "post": 2446, - "city": "Bellangry", - "phone1": "02-6246-5711", - "phone2": "0431-413-930", - "email": "genevive@hotmail.com", - "web": "http://www.centralhudsonentcorp.com.au" - }, - { - "first_name": "Victor", - "last_name": "Laroia", - "company_name": "Midwest Marketing Inc", - "address": "166 N Maple Dr", - "state": "NSW", - "post": 2447, - "city": "Scotts Head", - "phone1": "02-8156-6969", - "phone2": "0421-987-667", - "email": "victor@laroia.net.au", - "web": "http://www.midwestmarketinginc.com.au" - }, - { - "first_name": "Johnson", - "last_name": "Mcenery", - "company_name": "Overseas General Business Co", - "address": "7 Hall St", - "state": "NSW", - "post": 2448, - "city": "Nambucca Heads", - "phone1": "02-1718-4983", - "phone2": "0446-721-262", - "email": "johnson@gmail.com", - "web": "http://www.overseasgeneralbusinessco.com.au" - }, - { - "first_name": "Keena", - "last_name": "Rebich", - "company_name": "Affilated Consulting Group Inc", - "address": "3713 Poway Rd", - "state": "NSW", - "post": 2452, - "city": "Sawtell", - "phone1": "02-4972-3570", - "phone2": "0468-708-802", - "email": "krebich@rebich.net.au", - "web": "http://www.affilatedconsultinggroupinc.com.au" - }, - { - "first_name": "Magda", - "last_name": "Lindbeck", - "company_name": "Thomas Torto Constr Corp", - "address": "6 Kings St #4790", - "state": "NSW", - "post": 2456, - "city": "Emerald Beach", - "phone1": "02-3713-3646", - "phone2": "0451-383-562", - "email": "magda_lindbeck@yahoo.com", - "web": "http://www.thomastortoconstrcorp.com.au" - }, - { - "first_name": "Earlean", - "last_name": "Suffern", - "company_name": "Booster Farms", - "address": "5351 E Thousand Oaks Blvd", - "state": "NSW", - "post": 2463, - "city": "Woodford", - "phone1": "02-9653-2199", - "phone2": "0452-941-575", - "email": "earlean.suffern@suffern.net.au", - "web": "http://www.boosterfarms.com.au" - }, - { - "first_name": "Karol", - "last_name": "Sarkissian", - "company_name": "Pep Boys Manny Moe & Jack", - "address": "9296 Prince Rodgers Ave", - "state": "NSW", - "post": 2469, - "city": "Chatsworth", - "phone1": "02-3490-2407", - "phone2": "0419-430-467", - "email": "ksarkissian@yahoo.com", - "web": "http://www.pepboysmannymoejack.com.au" - }, - { - "first_name": "Tegan", - "last_name": "Ebershoff", - "company_name": "Multiform Business Printing", - "address": "28 Aaronwood Ave Ne", - "state": "NSW", - "post": 2470, - "city": "Coombell", - "phone1": "02-6604-9720", - "phone2": "0499-760-910", - "email": "tegan_ebershoff@hotmail.com", - "web": "http://www.multiformbusinessprinting.com.au" - }, - { - "first_name": "Alica", - "last_name": "Alerte", - "company_name": "Valley Hi Bank", - "address": "9892 Hernando W", - "state": "NSW", - "post": 2474, - "city": "Grevillia", - "phone1": "02-6974-7785", - "phone2": "0423-831-803", - "email": "aalerte@alerte.com.au", - "web": "http://www.valleyhibank.com.au" - }, - { - "first_name": "Hester", - "last_name": "Dollins", - "company_name": "Eagle Plywood & Door Mfrs Inc", - "address": "4864 N 168th Ave", - "state": "NSW", - "post": 2474, - "city": "The Risk", - "phone1": "02-1622-6412", - "phone2": "0473-268-319", - "email": "hester_dollins@gmail.com", - "web": "http://www.eagleplywooddoormfrsinc.com.au" - }, - { - "first_name": "Fredric", - "last_name": "Johanningmeie", - "company_name": "Galaxie Displays Inc", - "address": "23 S Orange Ave #55", - "state": "NSW", - "post": 2477, - "city": "Wardell", - "phone1": "02-1827-1736", - "phone2": "0425-214-447", - "email": "fredric@hotmail.com", - "web": "http://www.galaxiedisplaysinc.com.au" - }, - { - "first_name": "Temeka", - "last_name": "Bodine", - "company_name": "Consolidated Manufacturing Inc", - "address": "407 E 57th Ave", - "state": "NSW", - "post": 2480, - "city": "Clunes", - "phone1": "02-2581-7479", - "phone2": "0452-835-388", - "email": "temeka.bodine@gmail.com", - "web": "http://www.consolidatedmanufacturinginc.com.au" - }, - { - "first_name": "Jesus", - "last_name": "Liversedge", - "company_name": "White, Mark A Cpa", - "address": "18514 E 4th St #8", - "state": "NSW", - "post": 2481, - "city": "Broken Head", - "phone1": "02-4418-5927", - "phone2": "0467-331-796", - "email": "jesus.liversedge@hotmail.com", - "web": "http://www.whitemarkacpa.com.au" - }, - { - "first_name": "Annice", - "last_name": "Kunich", - "company_name": "Hassanein, Nesa E Esq", - "address": "406 E 4th St", - "state": "NSW", - "post": 2481, - "city": "Tyagarah", - "phone1": "02-6769-6153", - "phone2": "0449-775-616", - "email": "annice_kunich@kunich.net.au", - "web": "http://www.hassaneinnesaeesq.com.au" - }, - { - "first_name": "Eliseo", - "last_name": "Mikovec", - "company_name": "Air Flow Co Inc", - "address": "25488 Brickell Ave", - "state": "NSW", - "post": 2483, - "city": "Ocean Shores", - "phone1": "02-9829-2371", - "phone2": "0497-955-472", - "email": "emikovec@mikovec.com.au", - "web": "http://www.airflowcoinc.com.au" - }, - { - "first_name": "Nancey", - "last_name": "Whal", - "company_name": "National Mortgage Co", - "address": "398 Fort Campbell Blvd #923", - "state": "NSW", - "post": 2484, - "city": "Cudgera Creek", - "phone1": "02-3248-3283", - "phone2": "0426-612-418", - "email": "nancey@whal.net.au", - "web": "http://www.nationalmortgageco.com.au" - }, - { - "first_name": "Rolf", - "last_name": "Gene", - "company_name": "Jolley, Mark A Cpa", - "address": "99968 Merced St #79", - "state": "NSW", - "post": 2529, - "city": "Flinders", - "phone1": "02-4458-2810", - "phone2": "0482-882-653", - "email": "rolf_gene@gene.com.au", - "web": "http://www.jolleymarkacpa.com.au" - }, - { - "first_name": "Sherrell", - "last_name": "Sprowl", - "company_name": "Country Comfort", - "address": "2 State Hwy", - "state": "NSW", - "post": 2529, - "city": "Oak Flats", - "phone1": "02-4074-4461", - "phone2": "0417-795-558", - "email": "sherrell_sprowl@hotmail.com", - "web": "http://www.countrycomfort.com.au" - }, - { - "first_name": "Barabara", - "last_name": "Amedro", - "company_name": "Unicircuit Inc", - "address": "95412 16th St #6", - "state": "NSW", - "post": 2530, - "city": "Yallah", - "phone1": "02-3449-6894", - "phone2": "0467-209-469", - "email": "barabara@amedro.net.au", - "web": "http://www.unicircuitinc.com.au" - }, - { - "first_name": "Reuben", - "last_name": "Hegland", - "company_name": "Welders Supply Service Inc", - "address": "6 W 39th St", - "state": "NSW", - "post": 2538, - "city": "Milton", - "phone1": "02-1402-5215", - "phone2": "0489-476-500", - "email": "reuben@yahoo.com", - "web": "http://www.welderssupplyserviceinc.com.au" - }, - { - "first_name": "Wava", - "last_name": "Ochs", - "company_name": "Knights Inn", - "address": "9 Chandler Ave #355", - "state": "NSW", - "post": 2539, - "city": "Bawley Point", - "phone1": "02-1222-7812", - "phone2": "0445-285-375", - "email": "wava.ochs@gmail.com", - "web": "http://www.knightsinn.com.au" - }, - { - "first_name": "Rodrigo", - "last_name": "Schuh", - "company_name": "Hospitality Design Group", - "address": "512 E Idaho St", - "state": "NSW", - "post": 2540, - "city": "Burrier", - "phone1": "02-3869-4096", - "phone2": "0430-503-397", - "email": "rodrigo_schuh@gmail.com", - "web": "http://www.hospitalitydesigngroup.com.au" - }, - { - "first_name": "Scot", - "last_name": "Jarva", - "company_name": "Biancas La Petite French Bkry", - "address": "68 Camden Rd", - "state": "NSW", - "post": 2550, - "city": "Kingswood", - "phone1": "02-9676-4462", - "phone2": "0445-480-672", - "email": "scot.jarva@jarva.com.au", - "web": "http://www.biancaslapetitefrenchbkry.com.au" - }, - { - "first_name": "Emmanuel", - "last_name": "Avera", - "company_name": "Bank Of New York Na", - "address": "3883 N Central Ave", - "state": "NSW", - "post": 2560, - "city": "Appin", - "phone1": "02-1987-8525", - "phone2": "0498-489-459", - "email": "emmanuel@yahoo.com", - "web": "http://www.bankofnewyorkna.com.au" - }, - { - "first_name": "Isreal", - "last_name": "Calizo", - "company_name": "Milner Inn", - "address": "2 Landmeier Rd", - "state": "NSW", - "post": 2580, - "city": "Wombeyan Caves", - "phone1": "02-3494-3282", - "phone2": "0455-472-994", - "email": "isreal_calizo@gmail.com", - "web": "http://www.milnerinn.com.au" - }, - { - "first_name": "Gracia", - "last_name": "Pecot", - "company_name": "Kern Valley Printing", - "address": "2452 Bango Rd", - "state": "NSW", - "post": 2620, - "city": "Gundaroo", - "phone1": "02-8081-3883", - "phone2": "0472-903-534", - "email": "gpecot@hotmail.com", - "web": "http://www.kernvalleyprinting.com.au" - }, - { - "first_name": "Gerardo", - "last_name": "Woodka", - "company_name": "Morris Downing & Sherred", - "address": "69206 Jackson Ave", - "state": "NSW", - "post": 2640, - "city": "Talmalmo", - "phone1": "02-6044-4682", - "phone2": "0443-795-912", - "email": "gerardo_woodka@hotmail.com", - "web": "http://www.morrisdowningsherred.com.au" - }, - { - "first_name": "Son", - "last_name": "Magnotta", - "company_name": "Lisko, Roy K Esq", - "address": "8 Collins Ave", - "state": "NSW", - "post": 2650, - "city": "Collingullie", - "phone1": "02-2376-7653", - "phone2": "0446-520-807", - "email": "son.magnotta@magnotta.net.au", - "web": "http://www.liskoroykesq.com.au" - }, - { - "first_name": "Onita", - "last_name": "Milbrandt", - "company_name": "Fairfield Inn By Marriott", - "address": "93 Bloomfield Ave #829", - "state": "NSW", - "post": 2650, - "city": "Wagga Wagga South", - "phone1": "02-1157-3829", - "phone2": "0485-105-744", - "email": "onita.milbrandt@milbrandt.com.au", - "web": "http://www.fairfieldinnbymarriott.com.au" - }, - { - "first_name": "Stephania", - "last_name": "Connon", - "company_name": "Printing Delite", - "address": "297 8th Ave S #9", - "state": "NSW", - "post": 2652, - "city": "Gumly Gumly", - "phone1": "02-5725-5992", - "phone2": "0416-443-185", - "email": "stephania.connon@connon.com.au", - "web": "http://www.printingdelite.com.au" - }, - { - "first_name": "Katy", - "last_name": "Saltourides", - "company_name": "J C S Iron Works Inc", - "address": "5040 Teague Rd #65", - "state": "NSW", - "post": 2663, - "city": "Junee", - "phone1": "02-3003-1369", - "phone2": "0481-278-876", - "email": "katy_saltourides@yahoo.com", - "web": "http://www.jcsironworksinc.com.au" - }, - { - "first_name": "Rebeca", - "last_name": "Baley", - "company_name": "R A C E Enterprises Inc", - "address": "9591 Bayshore Rd #637", - "state": "NSW", - "post": 2665, - "city": "Mirrool", - "phone1": "02-7049-7728", - "phone2": "0486-736-129", - "email": "rebeca_baley@hotmail.com", - "web": "http://www.raceenterprisesinc.com.au" - }, - { - "first_name": "Alysa", - "last_name": "Lehoux", - "company_name": "Signs Of The Times", - "address": "186 Geary Blvd #923", - "state": "NSW", - "post": 2666, - "city": "Trungley Hall", - "phone1": "02-1385-3480", - "phone2": "0475-366-466", - "email": "alysa@hotmail.com", - "web": "http://www.signsofthetimes.com.au" - }, - { - "first_name": "Anna", - "last_name": "Ovit", - "company_name": "Georgia Business Machines", - "address": "722 E Liberty St", - "state": "NSW", - "post": 2669, - "city": "Bygalorie", - "phone1": "02-4649-5341", - "phone2": "0459-496-184", - "email": "anna.ovit@hotmail.com", - "web": "http://www.georgiabusinessmachines.com.au" - }, - { - "first_name": "Craig", - "last_name": "Vandersloot", - "company_name": "Maverik Country Stores Inc", - "address": "3 S Willow St #82", - "state": "NSW", - "post": 2669, - "city": "Bygalorie", - "phone1": "02-5487-7528", - "phone2": "0492-408-109", - "email": "craig_vandersloot@yahoo.com", - "web": "http://www.maverikcountrystoresinc.com.au" - }, - { - "first_name": "Francene", - "last_name": "Skursky", - "company_name": "Cullen, Jack J Esq", - "address": "5 30w W #3083", - "state": "NSW", - "post": 2675, - "city": "Hillston", - "phone1": "02-5941-3178", - "phone2": "0485-944-417", - "email": "francene.skursky@skursky.net.au", - "web": "http://www.cullenjackjesq.com.au" - }, - { - "first_name": "Arlie", - "last_name": "Borra", - "company_name": "Analytical Laboratories", - "address": "59215 W 80th St", - "state": "NSW", - "post": 2700, - "city": "Morundah", - "phone1": "02-1211-3823", - "phone2": "0423-740-512", - "email": "arlie.borra@gmail.com", - "web": "http://www.analyticallaboratories.com.au" - }, - { - "first_name": "Susana", - "last_name": "Baumgarter", - "company_name": "Leigh, Lewis R Esq", - "address": "7 Elm Ave", - "state": "NSW", - "post": 2703, - "city": "Yanco", - "phone1": "02-5410-5137", - "phone2": "0491-209-954", - "email": "susana.baumgarter@yahoo.com", - "web": "http://www.leighlewisresq.com.au" - }, - { - "first_name": "Jacquelyne", - "last_name": "Rosso", - "company_name": "Barragar, Anne L Esq", - "address": "6940 Prospect Pl", - "state": "NSW", - "post": 2710, - "city": "Caldwell", - "phone1": "02-4565-6425", - "phone2": "0464-763-350", - "email": "jacquelyne.rosso@yahoo.com", - "web": "http://www.barragarannelesq.com.au" - }, - { - "first_name": "Marsha", - "last_name": "Farnham", - "company_name": "Comfort Inn Of Revere", - "address": "577 Cleveland Ave", - "state": "NSW", - "post": 2745, - "city": "Glenmore Park", - "phone1": "02-5402-8024", - "phone2": "0470-386-894", - "email": "marsha@farnham.com.au", - "web": "http://www.comfortinnofrevere.com.au" - }, - { - "first_name": "Magnolia", - "last_name": "Overbough", - "company_name": "Marin Sun Printing", - "address": "65484 Bainbridge Rd", - "state": "NSW", - "post": 2750, - "city": "Penrith", - "phone1": "02-7947-2980", - "phone2": "0488-624-111", - "email": "moverbough@overbough.com.au", - "web": "http://www.marinsunprinting.com.au" - }, - { - "first_name": "Shawnta", - "last_name": "Woodhams", - "company_name": "Leo, Frank M", - "address": "9 Gunnison St", - "state": "NSW", - "post": 2761, - "city": "Oakhurst", - "phone1": "02-5770-8546", - "phone2": "0410-116-435", - "email": "shawnta@woodhams.com.au", - "web": "http://www.leofrankm.com.au" - }, - { - "first_name": "Sanjuana", - "last_name": "Goodness", - "company_name": "Woods Manufactured Housing", - "address": "343 E Main St", - "state": "NSW", - "post": 2765, - "city": "Maraylya", - "phone1": "02-2208-2711", - "phone2": "0436-444-424", - "email": "sgoodness@goodness.net.au", - "web": "http://www.woodsmanufacturedhousing.com.au" - }, - { - "first_name": "Dorian", - "last_name": "Eischens", - "company_name": "Thomas Somerville Co", - "address": "1 Rock Island Rd #8", - "state": "NSW", - "post": 2786, - "city": "Bell", - "phone1": "02-7739-6600", - "phone2": "0428-946-162", - "email": "deischens@gmail.com", - "web": "http://www.thomassomervilleco.com.au" - }, - { - "first_name": "Annalee", - "last_name": "Graleski", - "company_name": "Lescure Company Inc", - "address": "9 Green Rd #5877", - "state": "NSW", - "post": 2793, - "city": "Darbys Falls", - "phone1": "02-6118-8773", - "phone2": "0447-563-450", - "email": "annalee.graleski@hotmail.com", - "web": "http://www.lescurecompanyinc.com.au" - }, - { - "first_name": "Jonell", - "last_name": "Biasi", - "company_name": "Pestmaster Services Inc", - "address": "75 Ryan Dr #70", - "state": "NSW", - "post": 2795, - "city": "Duramana", - "phone1": "02-5095-2983", - "phone2": "0486-778-453", - "email": "jbiasi@biasi.net.au", - "web": "http://www.pestmasterservicesinc.com.au" - }, - { - "first_name": "Aliza", - "last_name": "Akiyama", - "company_name": "Kelly, Charles G Esq", - "address": "700 Wilmson Rd", - "state": "NSW", - "post": 2798, - "city": "Forest Reefs", - "phone1": "02-9324-7803", - "phone2": "0445-609-538", - "email": "aliza@yahoo.com", - "web": "http://www.kellycharlesgesq.com.au" - }, - { - "first_name": "Ena", - "last_name": "Desjardiws", - "company_name": "Selsor, Robert J Esq", - "address": "60562 Ky Rt 321", - "state": "NSW", - "post": 2803, - "city": "Bendick Murrell", - "phone1": "02-5226-9402", - "phone2": "0415-961-606", - "email": "ena_desjardiws@desjardiws.com.au", - "web": "http://www.selsorrobertjesq.com.au" - }, - { - "first_name": "Hayley", - "last_name": "Taghon", - "company_name": "Biltmore Textile Co Inc", - "address": "72 Wyoming Ave", - "state": "NSW", - "post": 2806, - "city": "Eugowra", - "phone1": "02-1638-4380", - "phone2": "0491-976-291", - "email": "htaghon@taghon.net.au", - "web": "http://www.biltmoretextilecoinc.com.au" - }, - { - "first_name": "Reita", - "last_name": "Tabar", - "company_name": "Cooper Myers Y Co", - "address": "79620 Timber Dr", - "state": "NSW", - "post": 2820, - "city": "Arthurville", - "phone1": "02-3518-7078", - "phone2": "0431-669-863", - "email": "rtabar@hotmail.com", - "web": "http://www.coopermyersyco.com.au" - }, - { - "first_name": "Bettina", - "last_name": "Diciano", - "company_name": "Greater Ky Corp", - "address": "11999 Main St", - "state": "NSW", - "post": 2820, - "city": "Dripstone", - "phone1": "02-3566-7608", - "phone2": "0472-631-448", - "email": "bdiciano@diciano.com.au", - "web": "http://www.greaterkycorp.com.au" - }, - { - "first_name": "Jeannetta", - "last_name": "Vonstaden", - "company_name": "Burlington Homes Of Maine", - "address": "269 Executive Dr", - "state": "NSW", - "post": 2850, - "city": "Ilford", - "phone1": "02-8222-9319", - "phone2": "0435-530-318", - "email": "jvonstaden@gmail.com", - "web": "http://www.burlingtonhomesofmaine.com.au" - }, - { - "first_name": "Lenora", - "last_name": "Delacruz", - "company_name": "Stilling, William J Esq", - "address": "5400 Market St", - "state": "NSW", - "post": 2850, - "city": "Turill", - "phone1": "02-7862-5151", - "phone2": "0454-434-110", - "email": "lenora@delacruz.net.au", - "web": "http://www.stillingwilliamjesq.com.au" - }, - { - "first_name": "Elmer", - "last_name": "Redlon", - "company_name": "Kdhl Am Radio", - "address": "53 Euclid Ave", - "state": "NSW", - "post": 2871, - "city": "Forbes", - "phone1": "02-1075-4690", - "phone2": "0463-757-229", - "email": "elmer@hotmail.com", - "web": "http://www.kdhlamradio.com.au" - }, - { - "first_name": "Cassie", - "last_name": "Digregorio", - "company_name": "Musgrave, R Todd Esq", - "address": "8650 S Valley View Bld #6941", - "state": "NSW", - "post": 2877, - "city": "Condobolin", - "phone1": "02-7922-5417", - "phone2": "0433-677-495", - "email": "cdigregorio@digregorio.net.au", - "web": "http://www.musgravertoddesq.com.au" - }, - { - "first_name": "Adaline", - "last_name": "Galagher", - "company_name": "Debbie Reynolds Hotel", - "address": "32716 N Michigan Ave #82", - "state": "NSW", - "post": 3644, - "city": "Barooga", - "phone1": "02-3225-1954", - "phone2": "0416-156-336", - "email": "adaline.galagher@galagher.com.au", - "web": "http://www.debbiereynoldshotel.com.au" - }, - { - "first_name": "Rossana", - "last_name": "Biler", - "company_name": "Norfolk County Newton Lung", - "address": "60481 N Clark St", - "state": "NT", - "post": 810, - "city": "Lee Point", - "phone1": "08-9855-2125", - "phone2": "0461-569-843", - "email": "rossana.biler@biler.net.au", - "web": "http://www.norfolkcountynewtonlung.com.au" - }, - { - "first_name": "Kristian", - "last_name": "Ellerbusch", - "company_name": "Butler, Frank B Esq", - "address": "71585 S Ayon Ave #9", - "state": "NT", - "post": 810, - "city": "Wanguri", - "phone1": "08-2748-1250", - "phone2": "0442-982-316", - "email": "kristian@yahoo.com", - "web": "http://www.butlerfrankbesq.com.au" - }, - { - "first_name": "Annita", - "last_name": "Lek", - "company_name": "Busada Manufacturing Corp", - "address": "86274 Howell Mill Rd Nw", - "state": "NT", - "post": 812, - "city": "Karama", - "phone1": "08-3384-3181", - "phone2": "0426-888-203", - "email": "annita.lek@lek.net.au", - "web": "http://www.busadamanufacturingcorp.com.au" - }, - { - "first_name": "Barb", - "last_name": "Latina", - "company_name": "Die Craft Stamping", - "address": "1 National Plac #6619", - "state": "NT", - "post": 820, - "city": "Larrakeyah", - "phone1": "08-8506-7259", - "phone2": "0443-657-148", - "email": "blatina@hotmail.com", - "web": "http://www.diecraftstamping.com.au" - }, - { - "first_name": "Louis", - "last_name": "Brueck", - "company_name": "Sassy Lassie Dolls", - "address": "73 12th St", - "state": "NT", - "post": 820, - "city": "Larrakeyah", - "phone1": "08-5228-3628", - "phone2": "0471-229-188", - "email": "louis.brueck@brueck.net.au", - "web": "http://www.sassylassiedolls.com.au" - }, - { - "first_name": "Lorenza", - "last_name": "Schoenleber", - "company_name": "Mail Boxes Etc", - "address": "562 Nw Cornell Rd", - "state": "NT", - "post": 836, - "city": "Humpty Doo", - "phone1": "08-8081-7779", - "phone2": "0445-830-408", - "email": "lorenza.schoenleber@schoenleber.com.au", - "web": "http://www.mailboxesetc.com.au" - }, - { - "first_name": "Keshia", - "last_name": "Wasp", - "company_name": "Cole, Gary D Esq", - "address": "75 E Main", - "state": "NT", - "post": 846, - "city": "Adelaide River", - "phone1": "08-1683-9243", - "phone2": "0439-885-729", - "email": "kwasp@wasp.net.au", - "web": "http://www.colegarydesq.com.au" - }, - { - "first_name": "Catrice", - "last_name": "Fowlkes", - "company_name": "Kappus Co", - "address": "39828 Abbott Rd", - "state": "QLD", - "post": 4001, - "city": "Waterfront Place", - "phone1": "07-9032-5149", - "phone2": "0418-429-485", - "email": "cfowlkes@hotmail.com", - "web": "http://www.kappusco.com.au" - }, - { - "first_name": "Arleen", - "last_name": "Kane", - "company_name": "Colosi, Darryl J Esq", - "address": "78717 Graves Ln", - "state": "QLD", - "post": 4009, - "city": "Eagle Farm", - "phone1": "07-3476-2066", - "phone2": "0430-271-168", - "email": "arleen.kane@hotmail.com", - "web": "http://www.colosidarryljesq.com.au" - }, - { - "first_name": "Rose", - "last_name": "Jebb", - "company_name": "Old Cider Mill Grove", - "address": "27916 Tarrytown Rd", - "state": "QLD", - "post": 4030, - "city": "Wooloowin", - "phone1": "07-4941-9471", - "phone2": "0496-441-929", - "email": "rose@jebb.net.au", - "web": "http://www.oldcidermillgrove.com.au" - }, - { - "first_name": "Glory", - "last_name": "Carlo", - "company_name": "Swanson Travel", - "address": "50808 A Pamalee Dr", - "state": "QLD", - "post": 4051, - "city": "Grange", - "phone1": "07-9265-7183", - "phone2": "0490-570-424", - "email": "glory_carlo@gmail.com", - "web": "http://www.swansontravel.com.au" - }, - { - "first_name": "Veda", - "last_name": "Mishkin", - "company_name": "Smith, Sean O Esq", - "address": "98247 Russell Blvd", - "state": "QLD", - "post": 4053, - "city": "Stafford Heights", - "phone1": "07-6034-2422", - "phone2": "0474-823-917", - "email": "veda.mishkin@mishkin.com.au", - "web": "http://www.smithseanoesq.com.au" - }, - { - "first_name": "Merrilee", - "last_name": "Fajen", - "company_name": "Gazette Record", - "address": "1 Jenks Ave", - "state": "QLD", - "post": 4055, - "city": "Upper Kedron", - "phone1": "07-9104-1459", - "phone2": "0489-493-308", - "email": "merrilee@fajen.net.au", - "web": "http://www.gazetterecord.com.au" - }, - { - "first_name": "Ryann", - "last_name": "Riston", - "company_name": "Best Western Gloucester Inn", - "address": "38494 Port Reading Ave", - "state": "QLD", - "post": 4064, - "city": "Milton", - "phone1": "07-9920-3550", - "phone2": "0423-341-752", - "email": "ryann@hotmail.com", - "web": "http://www.bestwesterngloucesterinn.com.au" - }, - { - "first_name": "Zana", - "last_name": "Ploszaj", - "company_name": "Community Insurance Agy Inc", - "address": "25 Swift Ave", - "state": "QLD", - "post": 4066, - "city": "Auchenflower", - "phone1": "07-7991-8880", - "phone2": "0430-656-502", - "email": "zana_ploszaj@ploszaj.net.au", - "web": "http://www.communityinsuranceagyinc.com.au" - }, - { - "first_name": "Honey", - "last_name": "Lymaster", - "company_name": "Joiner & Goudeau Law Offices", - "address": "7 Wilshire Blvd", - "state": "QLD", - "post": 4068, - "city": "Taringa", - "phone1": "07-8087-2603", - "phone2": "0411-717-109", - "email": "honey_lymaster@lymaster.net.au", - "web": "http://www.joinergoudeaulawoffices.com.au" - }, - { - "first_name": "Nida", - "last_name": "Fitz", - "company_name": "Star Limousine", - "address": "17720 Beach Blvd", - "state": "QLD", - "post": 4075, - "city": "Oxley", - "phone1": "07-7445-2572", - "phone2": "0473-495-435", - "email": "nfitz@hotmail.com", - "web": "http://www.starlimousine.com.au" - }, - { - "first_name": "Adelaide", - "last_name": "Ender", - "company_name": "Williams Design Group", - "address": "175 N Central Ave", - "state": "QLD", - "post": 4120, - "city": "Greenslopes", - "phone1": "07-7538-5504", - "phone2": "0473-505-816", - "email": "aender@gmail.com", - "web": "http://www.williamsdesigngroup.com.au" - }, - { - "first_name": "Tabetha", - "last_name": "Bai", - "company_name": "Howard Johnson", - "address": "2 Gateway Ctr", - "state": "QLD", - "post": 4122, - "city": "Upper Mount Gravatt", - "phone1": "07-6813-6477", - "phone2": "0438-141-107", - "email": "tabetha.bai@gmail.com", - "web": "http://www.howardjohnson.com.au" - }, - { - "first_name": "Tashia", - "last_name": "Charney", - "company_name": "Gallagher, Owen Esq", - "address": "9 13th Ave S", - "state": "QLD", - "post": 4128, - "city": "Shailer Park", - "phone1": "07-7659-5711", - "phone2": "0450-769-383", - "email": "tashia.charney@charney.net.au", - "web": "http://www.gallagherowenesq.com.au" - }, - { - "first_name": "Adrianna", - "last_name": "Poncio", - "company_name": "H T Communications Group Ltd", - "address": "9 34th Ave #69", - "state": "QLD", - "post": 4205, - "city": "Bethania", - "phone1": "07-6113-9653", - "phone2": "0432-130-553", - "email": "adrianna@poncio.com.au", - "web": "http://www.htcommunicationsgroupltd.com.au" - }, - { - "first_name": "Shantell", - "last_name": "Lizama", - "company_name": "Astromatic", - "address": "9787 Dunksferry Rd", - "state": "QLD", - "post": 4207, - "city": "Logan Village", - "phone1": "07-5346-5917", - "phone2": "0459-937-449", - "email": "shantell.lizama@gmail.com", - "web": "http://www.astromatic.com.au" - }, - { - "first_name": "Wilford", - "last_name": "Pata", - "company_name": "Era Mclachlan John Morgan Real", - "address": "8855 North Ave", - "state": "QLD", - "post": 4214, - "city": "Ashmore", - "phone1": "07-7445-2538", - "phone2": "0445-797-121", - "email": "wilford_pata@pata.net.au", - "web": "http://www.eramclachlanjohnmorganreal.com.au" - }, - { - "first_name": "Theresia", - "last_name": "Salomone", - "company_name": "Curran, Carol N Esq", - "address": "1337 N 26th St", - "state": "QLD", - "post": 4217, - "city": "Bundall", - "phone1": "07-8250-2277", - "phone2": "0437-687-429", - "email": "theresia_salomone@gmail.com", - "web": "http://www.currancarolnesq.com.au" - }, - { - "first_name": "Carli", - "last_name": "Bame", - "company_name": "Hampton Inn Hotel", - "address": "6584 S Bascom Ave #371", - "state": "QLD", - "post": 4221, - "city": "Elanora", - "phone1": "07-5354-7251", - "phone2": "0499-207-236", - "email": "carli@yahoo.com", - "web": "http://www.hamptoninnhotel.com.au" - }, - { - "first_name": "Dante", - "last_name": "Freiman", - "company_name": "Gaylord", - "address": "76 Daylight Way #7", - "state": "QLD", - "post": 4227, - "city": "Varsity Lakes", - "phone1": "07-1964-4238", - "phone2": "0432-682-937", - "email": "dante_freiman@freiman.net.au", - "web": "http://www.gaylord.com.au" - }, - { - "first_name": "Gladis", - "last_name": "Kazemi", - "company_name": "Dippin Flavors", - "address": "3266 Welsh Rd", - "state": "QLD", - "post": 4227, - "city": "Varsity Lakes", - "phone1": "07-6444-3666", - "phone2": "0444-157-156", - "email": "gkazemi@kazemi.net.au", - "web": "http://www.dippinflavors.com.au" - }, - { - "first_name": "Paris", - "last_name": "Kinnison", - "company_name": "Saratoga Land Office", - "address": "2 Old Corlies Ave", - "state": "QLD", - "post": 4305, - "city": "Eastern Heights", - "phone1": "07-4518-4450", - "phone2": "0454-257-906", - "email": "paris.kinnison@gmail.com", - "web": "http://www.saratogalandoffice.com.au" - }, - { - "first_name": "Jackie", - "last_name": "Kellebrew", - "company_name": "Senior Village Nursing Home", - "address": "25 Sw End Blvd #609", - "state": "QLD", - "post": 4311, - "city": "Coominya", - "phone1": "07-9840-6419", - "phone2": "0448-206-407", - "email": "jackie.kellebrew@kellebrew.com.au", - "web": "http://www.seniorvillagenursinghome.com.au" - }, - { - "first_name": "Pearlene", - "last_name": "Boudrie", - "company_name": "Design Rite Homes Inc", - "address": "8978 W Henrietta Rd", - "state": "QLD", - "post": 4311, - "city": "Minden", - "phone1": "07-4463-7223", - "phone2": "0462-627-260", - "email": "pboudrie@boudrie.net.au", - "web": "http://www.designritehomesinc.com.au" - }, - { - "first_name": "Dorethea", - "last_name": "Taketa", - "company_name": "Fraser Dante Ltd", - "address": "7 N 4th St", - "state": "QLD", - "post": 4313, - "city": "Lower Cressbrook", - "phone1": "07-2209-2731", - "phone2": "0436-606-487", - "email": "dtaketa@taketa.net.au", - "web": "http://www.fraserdanteltd.com.au" - }, - { - "first_name": "Trina", - "last_name": "Oto", - "company_name": "N Amer Plast & Chemls Co Inc", - "address": "6149 Kapiolani Blvd #6", - "state": "QLD", - "post": 4343, - "city": "Placid Hills", - "phone1": "07-1153-8567", - "phone2": "0460-377-727", - "email": "trina@oto.com.au", - "web": "http://www.namerplastchemlscoinc.com.au" - }, - { - "first_name": "Shawna", - "last_name": "Albrough", - "company_name": "Wood, J Scott Esq", - "address": "43157 Cypress St", - "state": "QLD", - "post": 4343, - "city": "Ringwood", - "phone1": "07-7977-6039", - "phone2": "0441-255-802", - "email": "shawna.albrough@albrough.com.au", - "web": "http://www.woodjscottesq.com.au" - }, - { - "first_name": "Amira", - "last_name": "Chudej", - "company_name": "Public Works Department", - "address": "3684 N Wacker Dr", - "state": "QLD", - "post": 4343, - "city": "Rockside", - "phone1": "07-8135-3271", - "phone2": "0478-867-289", - "email": "amira.chudej@chudej.net.au", - "web": "http://www.publicworksdepartment.com.au" - }, - { - "first_name": "Dylan", - "last_name": "Chaleun", - "company_name": "Berhanu International Foods", - "address": "5 Montana Ave", - "state": "QLD", - "post": 4344, - "city": "Lilydale", - "phone1": "07-2319-2889", - "phone2": "0412-631-864", - "email": "dylan_chaleun@hotmail.com", - "web": "http://www.berhanuinternationalfoods.com.au" - }, - { - "first_name": "Leigha", - "last_name": "Capelli", - "company_name": "Saturn Of Delray", - "address": "8039 Howard Ave", - "state": "QLD", - "post": 4350, - "city": "East Toowoomba", - "phone1": "07-4823-9785", - "phone2": "0432-580-634", - "email": "leigha.capelli@capelli.com.au", - "web": "http://www.saturnofdelray.com.au" - }, - { - "first_name": "Malcolm", - "last_name": "Gohlke", - "company_name": "Imagelink", - "address": "53247 Montgomery St #36", - "state": "QLD", - "post": 4350, - "city": "Southtown", - "phone1": "07-9826-3950", - "phone2": "0450-887-422", - "email": "malcolm@yahoo.com", - "web": "http://www.imagelink.com.au" - }, - { - "first_name": "Gerri", - "last_name": "Perra", - "company_name": "Byrne, Beth Hobbs", - "address": "15126 Goldenwest St", - "state": "QLD", - "post": 4350, - "city": "Toowoomba South", - "phone1": "07-6019-7861", - "phone2": "0416-887-937", - "email": "gerri@yahoo.com", - "web": "http://www.byrnebethhobbs.com.au" - }, - { - "first_name": "Linette", - "last_name": "Summerfield", - "company_name": "Mortenson Broadcasting Co", - "address": "78 S Robson", - "state": "QLD", - "post": 4355, - "city": "Crows Nest", - "phone1": "07-7489-7577", - "phone2": "0453-580-611", - "email": "linette.summerfield@hotmail.com", - "web": "http://www.mortensonbroadcastingco.com.au" - }, - { - "first_name": "Gerald", - "last_name": "Kloepper", - "company_name": "Pleasantville Finance Dept", - "address": "42 United Dr", - "state": "QLD", - "post": 4355, - "city": "Pierces Creek", - "phone1": "07-4297-4607", - "phone2": "0437-819-518", - "email": "gerald@yahoo.com", - "web": "http://www.pleasantvillefinancedept.com.au" - }, - { - "first_name": "Alfreda", - "last_name": "Delsoin", - "company_name": "Harris, Eric C Esq", - "address": "4373 Washington St", - "state": "QLD", - "post": 4356, - "city": "Bongeen", - "phone1": "07-7369-8849", - "phone2": "0419-246-570", - "email": "adelsoin@yahoo.com", - "web": "http://www.harrisericcesq.com.au" - }, - { - "first_name": "Vince", - "last_name": "Siena", - "company_name": "Vincent J Petti & Co", - "address": "70 S 18th Pl", - "state": "QLD", - "post": 4356, - "city": "Purrawunda", - "phone1": "07-3184-9989", - "phone2": "0411-732-965", - "email": "vince_siena@yahoo.com", - "web": "http://www.vincentjpettico.com.au" - }, - { - "first_name": "Alease", - "last_name": "Strawbridge", - "company_name": "Marscher, William F Iii", - "address": "35673 Annapolis Rd #190", - "state": "QLD", - "post": 4359, - "city": "Ascot", - "phone1": "07-3760-1546", - "phone2": "0497-868-525", - "email": "alease_strawbridge@strawbridge.com.au", - "web": "http://www.marscherwilliamfiii.com.au" - }, - { - "first_name": "Major", - "last_name": "Studwell", - "company_name": "Wood Sign & Banner Co", - "address": "5 Buford Hwy Ne #3", - "state": "QLD", - "post": 4362, - "city": "Allora", - "phone1": "07-1377-6898", - "phone2": "0426-784-480", - "email": "major@gmail.com", - "web": "http://www.woodsignbannerco.com.au" - }, - { - "first_name": "Nicholle", - "last_name": "Hulme", - "company_name": "Oxner Vallerie", - "address": "7 N Glenn Rd", - "state": "QLD", - "post": 4387, - "city": "Whetstone", - "phone1": "07-7144-4719", - "phone2": "0476-915-729", - "email": "nicholle_hulme@hulme.com.au", - "web": "http://www.oxnervallerie.com.au" - }, - { - "first_name": "Bea", - "last_name": "Iida", - "company_name": "Reliance Credit Union", - "address": "72 W Ripley Ave", - "state": "QLD", - "post": 4401, - "city": "Oakey", - "phone1": "07-6984-9278", - "phone2": "0493-653-304", - "email": "bea_iida@iida.net.au", - "web": "http://www.reliancecreditunion.com.au" - }, - { - "first_name": "Ines", - "last_name": "Tokich", - "company_name": "De Woskin, Alan E Esq", - "address": "192 N Sheffield Ave", - "state": "QLD", - "post": 4405, - "city": "Bunya Mountains", - "phone1": "07-5017-7337", - "phone2": "0481-799-605", - "email": "ines_tokich@tokich.net.au", - "web": "http://www.dewoskinalaneesq.com.au" - }, - { - "first_name": "Fanny", - "last_name": "Stoneking", - "company_name": "Di Giacomo, Richard F Esq", - "address": "50968 Kurtz St #45", - "state": "QLD", - "post": 4411, - "city": "Warra", - "phone1": "07-3721-9123", - "phone2": "0465-778-983", - "email": "fstoneking@hotmail.com", - "web": "http://www.digiacomorichardfesq.com.au" - }, - { - "first_name": "Mica", - "last_name": "Simco", - "company_name": "Katz Brothers Market Inc", - "address": "5610 Holliday Rd", - "state": "QLD", - "post": 4412, - "city": "Brigalow", - "phone1": "07-1037-3391", - "phone2": "0471-169-302", - "email": "msimco@gmail.com", - "web": "http://www.katzbrothersmarketinc.com.au" - }, - { - "first_name": "Muriel", - "last_name": "Drozdowski", - "company_name": "Harfred Oil Co", - "address": "1 S Maryland Pky", - "state": "QLD", - "post": 4454, - "city": "Durham Downs", - "phone1": "07-5686-8088", - "phone2": "0473-213-595", - "email": "muriel_drozdowski@hotmail.com", - "web": "http://www.harfredoilco.com.au" - }, - { - "first_name": "Ruth", - "last_name": "Niglio", - "company_name": "Amberley Suite Hotels", - "address": "6 W Cornelia Ave", - "state": "QLD", - "post": 4455, - "city": "Orange Hill", - "phone1": "07-5128-8956", - "phone2": "0428-843-553", - "email": "ruth.niglio@hotmail.com", - "web": "http://www.amberleysuitehotels.com.au" - }, - { - "first_name": "Hailey", - "last_name": "Kopet", - "company_name": "Stokes, Fred J Esq", - "address": "5 France Ave S", - "state": "QLD", - "post": 4481, - "city": "Tanbar", - "phone1": "07-3799-1667", - "phone2": "0443-979-875", - "email": "hailey_kopet@kopet.com.au", - "web": "http://www.stokesfredjesq.com.au" - }, - { - "first_name": "Louann", - "last_name": "Susmilch", - "company_name": "M Sorkin Sanford Associates", - "address": "6 Lafayette St #3034", - "state": "QLD", - "post": 4489, - "city": "Wyandra", - "phone1": "07-5035-4889", - "phone2": "0489-594-290", - "email": "louann_susmilch@yahoo.com", - "web": "http://www.msorkinsanfordassociates.com.au" - }, - { - "first_name": "Miles", - "last_name": "Feldner", - "company_name": "Antietam Cable Television", - "address": "28465 Downey Ave #4238", - "state": "QLD", - "post": 4490, - "city": "Barringun", - "phone1": "07-8561-5894", - "phone2": "0475-337-188", - "email": "miles@hotmail.com", - "web": "http://www.antietamcabletelevision.com.au" - }, - { - "first_name": "Mose", - "last_name": "Vonseggern", - "company_name": "Art Concepts", - "address": "1 E Main St", - "state": "QLD", - "post": 4493, - "city": "Hungerford", - "phone1": "07-5769-8004", - "phone2": "0467-531-601", - "email": "mose_vonseggern@hotmail.com", - "web": "http://www.artconcepts.com.au" - }, - { - "first_name": "Lynette", - "last_name": "Beaureguard", - "company_name": "Young, Craig C Md", - "address": "630 E Plano Pky", - "state": "QLD", - "post": 4494, - "city": "Tarawera", - "phone1": "07-6679-3722", - "phone2": "0417-544-301", - "email": "lynette.beaureguard@hotmail.com", - "web": "http://www.youngcraigcmd.com.au" - }, - { - "first_name": "Felicitas", - "last_name": "Gong", - "company_name": "Telcom Communication Center", - "address": "173 Howard Ave", - "state": "QLD", - "post": 4497, - "city": "Weengallon", - "phone1": "07-8516-6453", - "phone2": "0470-655-661", - "email": "fgong@gong.com.au", - "web": "http://www.telcomcommunicationcenter.com.au" - }, - { - "first_name": "Rosina", - "last_name": "Sidhu", - "company_name": "Anchorage Yamaha", - "address": "660 N Green St", - "state": "QLD", - "post": 4505, - "city": "Burpengary", - "phone1": "07-6460-4488", - "phone2": "0458-753-924", - "email": "rosina_sidhu@gmail.com", - "web": "http://www.anchorageyamaha.com.au" - }, - { - "first_name": "Emeline", - "last_name": "Sotelo", - "company_name": "Reporters Inc", - "address": "46 Broadway St", - "state": "QLD", - "post": 4516, - "city": "Elimbah", - "phone1": "07-7240-6480", - "phone2": "0451-790-704", - "email": "emeline@gmail.com", - "web": "http://www.reportersinc.com.au" - }, - { - "first_name": "Kent", - "last_name": "Ivans", - "company_name": "Demer Normann Smith Ltd", - "address": "56710 Euclid Ave", - "state": "QLD", - "post": 4520, - "city": "Camp Mountain", - "phone1": "07-8661-4016", - "phone2": "0429-746-524", - "email": "kent_ivans@yahoo.com", - "web": "http://www.demernormannsmithltd.com.au" - }, - { - "first_name": "Mabelle", - "last_name": "Ramero", - "company_name": "Mchale, Joseph G Esq", - "address": "15258 W Charleston Blvd", - "state": "QLD", - "post": 4551, - "city": "Aroona", - "phone1": "07-8857-6463", - "phone2": "0427-579-588", - "email": "mabelle.ramero@ramero.net.au", - "web": "http://www.mchalejosephgesq.com.au" - }, - { - "first_name": "Katlyn", - "last_name": "Flitcroft", - "company_name": "Bill, Michael M", - "address": "7177 E 14th St", - "state": "QLD", - "post": 4552, - "city": "Maleny", - "phone1": "07-1778-9968", - "phone2": "0465-519-356", - "email": "kflitcroft@hotmail.com", - "web": "http://www.billmichaelm.com.au" - }, - { - "first_name": "Anthony", - "last_name": "Stever", - "company_name": "Burton & Davis", - "address": "91114 Grand Ave", - "state": "QLD", - "post": 4555, - "city": "Hunchy", - "phone1": "07-7092-8542", - "phone2": "0495-801-419", - "email": "anthony.stever@hotmail.com", - "web": "http://www.burtondavis.com.au" - }, - { - "first_name": "Lacey", - "last_name": "Francis", - "company_name": "Anthony & Langford", - "address": "44 105th Ave", - "state": "QLD", - "post": 4555, - "city": "Hunchy", - "phone1": "07-4119-3981", - "phone2": "0415-135-989", - "email": "lacey.francis@francis.net.au", - "web": "http://www.anthonylangford.com.au" - }, - { - "first_name": "Maybelle", - "last_name": "Bewley", - "company_name": "Angelo International", - "address": "387 Airway Cir #62", - "state": "QLD", - "post": 4560, - "city": "Mapleton", - "phone1": "07-9387-7293", - "phone2": "0448-221-640", - "email": "mbewley@yahoo.com", - "web": "http://www.angelointernational.com.au" - }, - { - "first_name": "Stephaine", - "last_name": "Manin", - "company_name": "Malmon, Alvin S Esq", - "address": "8202 Cornwall Rd", - "state": "QLD", - "post": 4562, - "city": "Eumundi", - "phone1": "07-2031-6566", - "phone2": "0438-847-885", - "email": "stephaine_manin@yahoo.com", - "web": "http://www.malmonalvinsesq.com.au" - }, - { - "first_name": "Isadora", - "last_name": "Yurick", - "company_name": "J M Edmunds Co Inc", - "address": "6 Mahler Rd", - "state": "QLD", - "post": 4564, - "city": "Pacific Paradise", - "phone1": "07-9595-6042", - "phone2": "0412-855-847", - "email": "iyurick@hotmail.com", - "web": "http://www.jmedmundscoinc.com.au" - }, - { - "first_name": "Tijuana", - "last_name": "Mesch", - "company_name": "Rochelle Cold Storage", - "address": "61 Center St #8", - "state": "QLD", - "post": 4570, - "city": "Corella", - "phone1": "07-1415-9307", - "phone2": "0444-393-673", - "email": "tijuana_mesch@gmail.com", - "web": "http://www.rochellecoldstorage.com.au" - }, - { - "first_name": "Twanna", - "last_name": "Sieber", - "company_name": "Rudolph, William S Cpa", - "address": "66094 Pioneer Rd", - "state": "QLD", - "post": 4570, - "city": "Upper Glastonbury", - "phone1": "07-5235-7319", - "phone2": "0451-406-157", - "email": "twanna@yahoo.com", - "web": "http://www.rudolphwilliamscpa.com.au" - }, - { - "first_name": "Catherin", - "last_name": "Aguele", - "company_name": "Hanna, Robert J Esq", - "address": "75962 E Drinker St", - "state": "QLD", - "post": 4605, - "city": "Sunny Nook", - "phone1": "07-6476-1399", - "phone2": "0444-150-950", - "email": "caguele@gmail.com", - "web": "http://www.hannarobertjesq.com.au" - }, - { - "first_name": "Albert", - "last_name": "Sonier", - "company_name": "Quartzite Processing Inc", - "address": "4 Brookcrest Dr #7786", - "state": "QLD", - "post": 4610, - "city": "Inverlaw", - "phone1": "07-9354-2612", - "phone2": "0420-575-355", - "email": "albert.sonier@gmail.com", - "web": "http://www.quartziteprocessinginc.com.au" - }, - { - "first_name": "Julieta", - "last_name": "Cropsey", - "company_name": "Atrium Marketing Inc", - "address": "9 Commerce Cir", - "state": "QLD", - "post": 4610, - "city": "Kingaroy", - "phone1": "07-4217-6258", - "phone2": "0420-286-404", - "email": "julieta@yahoo.com", - "web": "http://www.atriummarketinginc.com.au" - }, - { - "first_name": "Stevie", - "last_name": "Hallo", - "company_name": "Landrum Temporary Services", - "address": "22222 Acoma St", - "state": "QLD", - "post": 4613, - "city": "Proston", - "phone1": "07-9997-3366", - "phone2": "0497-622-620", - "email": "stevie.hallo@hotmail.com", - "web": "http://www.landrumtemporaryservices.com.au" - }, - { - "first_name": "Wilbert", - "last_name": "Beckes", - "company_name": "Alvis, John W Esq", - "address": "2799 Cajon Blvd", - "state": "QLD", - "post": 4615, - "city": "East Nanango", - "phone1": "07-9178-6430", - "phone2": "0455-947-547", - "email": "wilbert@hotmail.com", - "web": "http://www.alvisjohnwesq.com.au" - }, - { - "first_name": "Deeann", - "last_name": "Nicklous", - "company_name": "Philip Kingsley Trichological", - "address": "79 Mechanic St", - "state": "QLD", - "post": 4615, - "city": "Pimpimbudgee", - "phone1": "07-6382-5073", - "phone2": "0440-980-784", - "email": "deeann_nicklous@gmail.com", - "web": "http://www.philipkingsleytrichological.com.au" - }, - { - "first_name": "Ardella", - "last_name": "Dieterich", - "company_name": "Custom Jig Grinding", - "address": "94 Delta Fair Blvd #2702", - "state": "QLD", - "post": 4615, - "city": "Runnymede", - "phone1": "07-3581-9462", - "phone2": "0426-488-593", - "email": "ardella.dieterich@yahoo.com", - "web": "http://www.customjiggrinding.com.au" - }, - { - "first_name": "Alpha", - "last_name": "Prudhomme", - "company_name": "Davis, J Mark Esq", - "address": "979 S La Cienega Blvd #627", - "state": "QLD", - "post": 4615, - "city": "Tarong", - "phone1": "07-9053-8045", - "phone2": "0464-687-686", - "email": "aprudhomme@hotmail.com", - "web": "http://www.davisjmarkesq.com.au" - }, - { - "first_name": "Ira", - "last_name": "Zihal", - "company_name": "American Express Publshng Corp", - "address": "6 W Meadow St", - "state": "QLD", - "post": 4621, - "city": "Degilbo", - "phone1": "07-4724-9987", - "phone2": "0466-603-340", - "email": "ira.zihal@yahoo.com", - "web": "http://www.americanexpresspublshngcorp.com.au" - }, - { - "first_name": "Jill", - "last_name": "Davoren", - "company_name": "Broaches Inc", - "address": "26 Old William Penn Hwy", - "state": "QLD", - "post": 4626, - "city": "Boynewood", - "phone1": "07-1698-9047", - "phone2": "0468-451-905", - "email": "jill_davoren@davoren.net.au", - "web": "http://www.broachesinc.com.au" - }, - { - "first_name": "Ling", - "last_name": "Dibello", - "company_name": "Reese Press Inc", - "address": "6 Monte Ave", - "state": "QLD", - "post": 4659, - "city": "Beelbi Creek", - "phone1": "07-1330-6750", - "phone2": "0444-175-406", - "email": "ling_dibello@yahoo.com", - "web": "http://www.reesepressinc.com.au" - }, - { - "first_name": "Mary", - "last_name": "Dingler", - "company_name": "Autocrat Inc", - "address": "470 W Irving Park Rd", - "state": "QLD", - "post": 4670, - "city": "Bundaberg North", - "phone1": "07-3963-4469", - "phone2": "0452-920-972", - "email": "mary.dingler@gmail.com", - "web": "http://www.autocratinc.com.au" - }, - { - "first_name": "Jamey", - "last_name": "Tetter", - "company_name": "Vicon Corporation", - "address": "28 Standiford Ave #6", - "state": "QLD", - "post": 4670, - "city": "Bundaberg West", - "phone1": "07-6073-5039", - "phone2": "0481-690-589", - "email": "jamey.tetter@gmail.com", - "web": "http://www.viconcorporation.com.au" - }, - { - "first_name": "Nilsa", - "last_name": "Pawell", - "company_name": "Jersey Wholesale Fence Co Inc", - "address": "57 N Weinbach Ave", - "state": "QLD", - "post": 4670, - "city": "Bundaberg West", - "phone1": "07-8997-8513", - "phone2": "0486-504-582", - "email": "npawell@pawell.net.au", - "web": "http://www.jerseywholesalefencecoinc.com.au" - }, - { - "first_name": "Vanesa", - "last_name": "Glockner", - "company_name": "Nelson, Michael J Esq", - "address": "28220 Park Avenue W", - "state": "QLD", - "post": 4680, - "city": "Taragoola", - "phone1": "07-7052-4547", - "phone2": "0496-610-278", - "email": "vanesa@glockner.com.au", - "web": "http://www.nelsonmichaeljesq.com.au" - }, - { - "first_name": "Samira", - "last_name": "Heninger", - "company_name": "Alb Inc", - "address": "40490 Morrow St", - "state": "QLD", - "post": 4702, - "city": "Bluff", - "phone1": "07-9512-2457", - "phone2": "0443-539-658", - "email": "sheninger@yahoo.com", - "web": "http://www.albinc.com.au" - }, - { - "first_name": "Mickie", - "last_name": "Upton", - "company_name": "Oakey & Oakey Abstrct Burnett", - "address": "900 W Wood St", - "state": "QLD", - "post": 4703, - "city": "Barmaryee", - "phone1": "07-7647-5420", - "phone2": "0499-576-666", - "email": "mickie.upton@yahoo.com", - "web": "http://www.oakeyoakeyabstrctburnett.com.au" - }, - { - "first_name": "Tracie", - "last_name": "Huro", - "company_name": "Jin Shin Travel Agency", - "address": "39701 6th Ave #1485", - "state": "QLD", - "post": 4703, - "city": "Pacific Heights", - "phone1": "07-1951-6787", - "phone2": "0494-620-234", - "email": "thuro@gmail.com", - "web": "http://www.jinshintravelagency.com.au" - }, - { - "first_name": "Torie", - "last_name": "Deras", - "company_name": "Reynolds, Stephen R Esq", - "address": "700 Factory Ave #5649", - "state": "QLD", - "post": 4703, - "city": "Yeppoon", - "phone1": "07-8371-4719", - "phone2": "0426-991-115", - "email": "torie_deras@yahoo.com", - "web": "http://www.reynoldsstephenresq.com.au" - }, - { - "first_name": "Lindy", - "last_name": "Vandermeer", - "company_name": "Southern National Bank S Car", - "address": "4244 Lucas Creek Rd", - "state": "QLD", - "post": 4710, - "city": "Emu Park", - "phone1": "07-9407-9202", - "phone2": "0417-325-352", - "email": "lindy@vandermeer.com.au", - "web": "http://www.southernnationalbankscar.com.au" - }, - { - "first_name": "Trina", - "last_name": "Bakey", - "company_name": "Dewitt Cnty Fed Svngs & Ln", - "address": "31 Guilford Rd #7904", - "state": "QLD", - "post": 4712, - "city": "Duaringa", - "phone1": "07-5922-1983", - "phone2": "0495-376-112", - "email": "tbakey@bakey.com.au", - "web": "http://www.dewittcntyfedsvngsln.com.au" - }, - { - "first_name": "Julian", - "last_name": "Laprade", - "company_name": "Forsyth Steel Co", - "address": "5 Pittsburg St", - "state": "QLD", - "post": 4718, - "city": "Mungabunda", - "phone1": "07-2627-9976", - "phone2": "0419-587-898", - "email": "jlaprade@laprade.net.au", - "web": "http://www.forsythsteelco.com.au" - }, - { - "first_name": "Luz", - "last_name": "Broccoli", - "company_name": "Wynn, Mary Ellen Esq", - "address": "4 S Main St #285", - "state": "QLD", - "post": 4719, - "city": "Glenmoral", - "phone1": "07-2679-1774", - "phone2": "0416-525-908", - "email": "luz_broccoli@hotmail.com", - "web": "http://www.wynnmaryellenesq.com.au" - }, - { - "first_name": "Suzan", - "last_name": "Landa", - "company_name": "Vista Grande Baptist Church", - "address": "15 Campville Rd #191", - "state": "QLD", - "post": 4721, - "city": "Clermont", - "phone1": "07-1576-1412", - "phone2": "0471-251-939", - "email": "suzan.landa@gmail.com", - "web": "http://www.vistagrandebaptistchurch.com.au" - }, - { - "first_name": "Kirby", - "last_name": "Litherland", - "company_name": "Cross Western Store", - "address": "92 South St", - "state": "QLD", - "post": 4740, - "city": "Alligator Creek", - "phone1": "07-5284-3845", - "phone2": "0480-676-186", - "email": "kirby.litherland@hotmail.com", - "web": "http://www.crosswesternstore.com.au" - }, - { - "first_name": "Desmond", - "last_name": "Tarkowski", - "company_name": "Body Part Connection", - "address": "5920 E Arapahoe Rd", - "state": "QLD", - "post": 4740, - "city": "Andergrove", - "phone1": "07-6793-5954", - "phone2": "0445-121-372", - "email": "desmond_tarkowski@hotmail.com", - "web": "http://www.bodypartconnection.com.au" - }, - { - "first_name": "Cherri", - "last_name": "Miccio", - "company_name": "Hong Iwai Hulbert & Kawano", - "address": "3 Bustleton Ave", - "state": "QLD", - "post": 4740, - "city": "Balnagowan", - "phone1": "07-5626-7937", - "phone2": "0476-736-800", - "email": "cherri_miccio@gmail.com", - "web": "http://www.hongiwaihulbertkawano.com.au" - }, - { - "first_name": "Jonelle", - "last_name": "Epps", - "company_name": "Kvoo Radio", - "address": "52347 San Fernando Rd", - "state": "QLD", - "post": 4741, - "city": "Coppabella", - "phone1": "07-8085-8351", - "phone2": "0461-339-731", - "email": "jepps@hotmail.com", - "web": "http://www.kvooradio.com.au" - }, - { - "first_name": "Alida", - "last_name": "Helger", - "company_name": "Ballinger, Maria Chan Esq", - "address": "6 Hope Rd #10", - "state": "QLD", - "post": 4741, - "city": "Pinnacle", - "phone1": "07-1642-3251", - "phone2": "0412-699-567", - "email": "alida@helger.com.au", - "web": "http://www.ballingermariachanesq.com.au" - }, - { - "first_name": "Dana", - "last_name": "Ladeau", - "company_name": "Higgins, Daniel B Esq", - "address": "63 W 41st Ave #93", - "state": "QLD", - "post": 4741, - "city": "Pinnacle", - "phone1": "07-3511-9233", - "phone2": "0480-125-331", - "email": "dana@ladeau.net.au", - "web": "http://www.higginsdanielbesq.com.au" - }, - { - "first_name": "Tomas", - "last_name": "Fults", - "company_name": "Test Tools Inc", - "address": "3 Hwy 61 #2491", - "state": "QLD", - "post": 4754, - "city": "Mirani", - "phone1": "07-1536-4805", - "phone2": "0473-757-584", - "email": "tomas_fults@fults.net.au", - "web": "http://www.testtoolsinc.com.au" - }, - { - "first_name": "Dan", - "last_name": "Platz", - "company_name": "Ny Stat Trial Lawyers Assn", - "address": "5210 E Airy St #2", - "state": "QLD", - "post": 4800, - "city": "Brandy Creek", - "phone1": "07-4306-1623", - "phone2": "0441-978-907", - "email": "dan_platz@hotmail.com", - "web": "http://www.nystattriallawyersassn.com.au" - }, - { - "first_name": "Gerald", - "last_name": "Chrusciel", - "company_name": "Prusax, Maximilian M Esq", - "address": "76596 Pleasant Hill Rd", - "state": "QLD", - "post": 4813, - "city": "Townsville Milpo", - "phone1": "07-7446-6315", - "phone2": "0426-833-750", - "email": "gerald@chrusciel.net.au", - "web": "http://www.prusaxmaximilianmesq.com.au" - }, - { - "first_name": "Aaron", - "last_name": "Kloska", - "company_name": "Radecker, H Philip Jr", - "address": "423 S Navajo St #56", - "state": "QLD", - "post": 4816, - "city": "Brookhill", - "phone1": "07-9896-4827", - "phone2": "0473-600-733", - "email": "aaron_kloska@kloska.net.au", - "web": "http://www.radeckerhphilipjr.com.au" - }, - { - "first_name": "Linsey", - "last_name": "Gedman", - "company_name": "Eagle Computer Services Inc", - "address": "1529 Prince Rodgers Ave", - "state": "QLD", - "post": 4816, - "city": "Kennedy", - "phone1": "07-4785-3781", - "phone2": "0433-965-131", - "email": "lgedman@gedman.net.au", - "web": "http://www.eaglecomputerservicesinc.com.au" - }, - { - "first_name": "Nidia", - "last_name": "Horr", - "company_name": "Goodknight, David R", - "address": "2 W Henrietta Rd #6", - "state": "QLD", - "post": 4816, - "city": "Paluma", - "phone1": "07-8441-8214", - "phone2": "0437-170-488", - "email": "nidia@gmail.com", - "web": "http://www.goodknightdavidr.com.au" - }, - { - "first_name": "Osvaldo", - "last_name": "Falvey", - "company_name": "Avila, Edward G Esq", - "address": "6434 Westchester Ave #28", - "state": "QLD", - "post": 4820, - "city": "Queenton", - "phone1": "07-4854-5045", - "phone2": "0437-545-265", - "email": "osvaldo.falvey@yahoo.com", - "web": "http://www.avilaedwardgesq.com.au" - }, - { - "first_name": "Lillian", - "last_name": "Dominique", - "company_name": "West Pac Environmental Inc", - "address": "92417 Arbuckle Ct", - "state": "QLD", - "post": 4823, - "city": "Julia Creek", - "phone1": "07-3594-6592", - "phone2": "0490-548-561", - "email": "lillian@hotmail.com", - "web": "http://www.westpacenvironmentalinc.com.au" - }, - { - "first_name": "Dannette", - "last_name": "Heimbaugh", - "company_name": "Accent Copy Center Inc", - "address": "5 Carpenter Ave", - "state": "QLD", - "post": 4825, - "city": "Breakaway", - "phone1": "07-8738-4205", - "phone2": "0422-884-614", - "email": "dannette@gmail.com", - "web": "http://www.accentcopycenterinc.com.au" - }, - { - "first_name": "Josefa", - "last_name": "Oakland", - "company_name": "Duncan & Associates", - "address": "259 1st Ave", - "state": "QLD", - "post": 4856, - "city": "Mccutcheon", - "phone1": "07-5404-6221", - "phone2": "0493-826-469", - "email": "josefa_oakland@oakland.com.au", - "web": "http://www.duncanassociates.com.au" - }, - { - "first_name": "Shawn", - "last_name": "Vugteveen", - "company_name": "Shine", - "address": "81 Us Highway 9", - "state": "QLD", - "post": 4858, - "city": "Etty Bay", - "phone1": "07-3103-8372", - "phone2": "0480-561-819", - "email": "svugteveen@vugteveen.net.au", - "web": "http://www.shine.com.au" - }, - { - "first_name": "Annette", - "last_name": "Breyer", - "company_name": "Xyvision Inc", - "address": "26921 Vassar St", - "state": "QLD", - "post": 4860, - "city": "Daradgee", - "phone1": "07-5417-9612", - "phone2": "0484-806-405", - "email": "abreyer@hotmail.com", - "web": "http://www.xyvisioninc.com.au" - }, - { - "first_name": "William", - "last_name": "Devol", - "company_name": "Low Country Kitchen & Bath", - "address": "35 Jefferson Ave", - "state": "QLD", - "post": 4860, - "city": "Goondi Hill", - "phone1": "07-4963-5297", - "phone2": "0485-183-917", - "email": "wdevol@devol.net.au", - "web": "http://www.lowcountrykitchenbath.com.au" - }, - { - "first_name": "Elenor", - "last_name": "Siefken", - "company_name": "Chateau Sonesta Hotel", - "address": "136 2nd Ave N", - "state": "QLD", - "post": 4870, - "city": "Cairns City", - "phone1": "07-5085-8138", - "phone2": "0419-509-353", - "email": "elenor.siefken@yahoo.com", - "web": "http://www.chateausonestahotel.com.au" - }, - { - "first_name": "Ludivina", - "last_name": "Calamarino", - "company_name": "Components & Equipment Co", - "address": "1456 Hill Rd", - "state": "QLD", - "post": 4871, - "city": "Croydon", - "phone1": "07-5378-4498", - "phone2": "0482-267-844", - "email": "lcalamarino@yahoo.com", - "web": "http://www.componentsequipmentco.com.au" - }, - { - "first_name": "Misty", - "last_name": "Leriche", - "company_name": "K J N Advertising Inc", - "address": "5289 Ramblewood Dr", - "state": "QLD", - "post": 4871, - "city": "Glen Boughton", - "phone1": "07-5486-1002", - "phone2": "0414-661-490", - "email": "mleriche@yahoo.com", - "web": "http://www.kjnadvertisinginc.com.au" - }, - { - "first_name": "Sunny", - "last_name": "Catton", - "company_name": "Highway Rentals Inc", - "address": "79346 Firestone Blvd", - "state": "QLD", - "post": 4871, - "city": "Gununa", - "phone1": "07-1217-9907", - "phone2": "0450-440-670", - "email": "scatton@catton.com.au", - "web": "http://www.highwayrentalsinc.com.au" - }, - { - "first_name": "Anglea", - "last_name": "Andrion", - "company_name": "Engelbrecht, William H Esq", - "address": "910 21st St", - "state": "QLD", - "post": 4871, - "city": "Laura", - "phone1": "07-3239-2830", - "phone2": "0442-946-694", - "email": "anglea.andrion@andrion.com.au", - "web": "http://www.engelbrechtwilliamhesq.com.au" - }, - { - "first_name": "Royal", - "last_name": "Costeira", - "company_name": "Wynns Precision Inc Az Div", - "address": "970 Waterloo Rd", - "state": "QLD", - "post": 4879, - "city": "Ellis Beach", - "phone1": "07-5338-6357", - "phone2": "0480-443-612", - "email": "royal_costeira@costeira.com.au", - "web": "http://www.wynnsprecisionincazdiv.com.au" - }, - { - "first_name": "Donte", - "last_name": "Resureccion", - "company_name": "N E Industrial Distr Inc", - "address": "65898 E St Nw", - "state": "QLD", - "post": 4887, - "city": "Watsonville", - "phone1": "07-2373-6048", - "phone2": "0478-459-448", - "email": "donte.resureccion@yahoo.com", - "web": "http://www.neindustrialdistrinc.com.au" - }, - { - "first_name": "Latricia", - "last_name": "Schmoyer", - "company_name": "Flanagan Lieberman Hoffman", - "address": "6 Central Ave #4", - "state": "SA", - "post": 5011, - "city": "Woodville", - "phone1": "08-5444-3296", - "phone2": "0459-945-995", - "email": "latricia_schmoyer@hotmail.com", - "web": "http://www.flanaganliebermanhoffman.com.au" - }, - { - "first_name": "Stefan", - "last_name": "Mongolo", - "company_name": "Keith Altizer & Company Pa", - "address": "2 Pennington St", - "state": "SA", - "post": 5015, - "city": "Port Adelaide", - "phone1": "08-4563-6214", - "phone2": "0495-777-435", - "email": "stefan_mongolo@mongolo.net.au", - "web": "http://www.keithaltizercompanypa.com.au" - }, - { - "first_name": "Paris", - "last_name": "Tuccio", - "company_name": "Nancy Brandon Realtor", - "address": "2677 S Jackson St", - "state": "SA", - "post": 5025, - "city": "Kidman Park", - "phone1": "08-8868-2010", - "phone2": "0417-281-870", - "email": "paris.tuccio@hotmail.com", - "web": "http://www.nancybrandonrealtor.com.au" - }, - { - "first_name": "Elin", - "last_name": "Koerner", - "company_name": "Theos Software Corp", - "address": "8 Cabot Rd", - "state": "SA", - "post": 5034, - "city": "Wayville", - "phone1": "08-5221-9700", - "phone2": "0472-281-671", - "email": "elin_koerner@koerner.com.au", - "web": "http://www.theossoftwarecorp.com.au" - }, - { - "first_name": "Hyman", - "last_name": "Hegeman", - "company_name": "Jerico Group", - "address": "1 S Marginal Rd", - "state": "SA", - "post": 5042, - "city": "Flinders University", - "phone1": "08-9280-9177", - "phone2": "0413-650-821", - "email": "hyman@hotmail.com", - "web": "http://www.jericogroup.com.au" - }, - { - "first_name": "Brent", - "last_name": "Ahlborn", - "company_name": "Apex Bottle Co", - "address": "86351 Pine Ave", - "state": "SA", - "post": 5046, - "city": "Oaklands Park", - "phone1": "08-4563-9520", - "phone2": "0492-994-709", - "email": "bahlborn@ahlborn.com.au", - "web": "http://www.apexbottleco.com.au" - }, - { - "first_name": "Buck", - "last_name": "Pascucci", - "company_name": "A B C Pattern & Foundry Co", - "address": "5 Shakespeare Ave", - "state": "SA", - "post": 5062, - "city": "Kingswood", - "phone1": "08-9279-1731", - "phone2": "0453-818-566", - "email": "buck@yahoo.com", - "web": "http://www.abcpatternfoundryco.com.au" - }, - { - "first_name": "Tyisha", - "last_name": "Layland", - "company_name": "Freitag Pc", - "address": "270 5th Ave", - "state": "SA", - "post": 5063, - "city": "Eastwood", - "phone1": "08-2158-6758", - "phone2": "0490-478-206", - "email": "tyisha@yahoo.com", - "web": "http://www.freitagpc.com.au" - }, - { - "first_name": "Zack", - "last_name": "Warman", - "company_name": "Roswell Honda Partners", - "address": "9181 E 26th St", - "state": "SA", - "post": 5068, - "city": "Kensington Park", - "phone1": "08-9948-2940", - "phone2": "0414-749-850", - "email": "zwarman@gmail.com", - "web": "http://www.roswellhondapartners.com.au" - }, - { - "first_name": "Micaela", - "last_name": "Shiflett", - "company_name": "W R Grace & Co", - "address": "4 Commerce Center Dr", - "state": "SA", - "post": 5083, - "city": "Nailsworth", - "phone1": "08-8856-8589", - "phone2": "0451-514-152", - "email": "micaela_shiflett@shiflett.com.au", - "web": "http://www.wrgraceco.com.au" - }, - { - "first_name": "Francoise", - "last_name": "Byon", - "company_name": "H P Stran & Co", - "address": "5496 Ne Columbia Blvd", - "state": "SA", - "post": 5087, - "city": "Klemzig", - "phone1": "08-3914-9404", - "phone2": "0430-357-187", - "email": "francoise@hotmail.com", - "web": "http://www.hpstranco.com.au" - }, - { - "first_name": "Michel", - "last_name": "Hoyne", - "company_name": "B & B Environmental Inc", - "address": "11408 Green St", - "state": "SA", - "post": 5113, - "city": "Elizabeth West", - "phone1": "08-6183-9260", - "phone2": "0481-466-206", - "email": "michel@hoyne.com.au", - "web": "http://www.bbenvironmentalinc.com.au" - }, - { - "first_name": "Jesusita", - "last_name": "Druck", - "company_name": "House Of Ing", - "address": "9526 Lincoln St", - "state": "SA", - "post": 5115, - "city": "Munno Para", - "phone1": "08-3605-3943", - "phone2": "0424-741-530", - "email": "jesusita@druck.net.au", - "web": "http://www.houseofing.com.au" - }, - { - "first_name": "Tora", - "last_name": "Telch", - "company_name": "Shamrock Food Service", - "address": "6139 Contractors Dr #450", - "state": "SA", - "post": 5120, - "city": "Buckland Park", - "phone1": "08-8808-8104", - "phone2": "0429-419-390", - "email": "tora@telch.net.au", - "web": "http://www.shamrockfoodservice.com.au" - }, - { - "first_name": "Fairy", - "last_name": "Burket", - "company_name": "Walker & Brehn Pa", - "address": "20 Sw 28th Ter", - "state": "SA", - "post": 5126, - "city": "Fairview Park", - "phone1": "08-9159-7562", - "phone2": "0472-806-350", - "email": "fairy_burket@burket.com.au", - "web": "http://www.walkerbrehnpa.com.au" - }, - { - "first_name": "Leah", - "last_name": "Milsap", - "company_name": "Schwartz, Seymour I Md", - "address": "45 Mountain View Ave", - "state": "SA", - "post": 5131, - "city": "Lower Hermitage", - "phone1": "08-4040-9192", - "phone2": "0452-193-155", - "email": "leah@milsap.com.au", - "web": "http://www.schwartzseymourimd.com.au" - }, - { - "first_name": "Hildred", - "last_name": "Eilbeck", - "company_name": "Plastic Supply Inc", - "address": "83 Longhurst Rd", - "state": "SA", - "post": 5153, - "city": "Longwood", - "phone1": "08-2922-4115", - "phone2": "0463-881-817", - "email": "hildred_eilbeck@eilbeck.net.au", - "web": "http://www.plasticsupplyinc.com.au" - }, - { - "first_name": "Carin", - "last_name": "Georgiades", - "company_name": "Dgstv Diseases Cnslnts", - "address": "95830 Webster Dr", - "state": "SA", - "post": 5158, - "city": "Trott Park", - "phone1": "08-8343-3550", - "phone2": "0475-701-279", - "email": "cgeorgiades@gmail.com", - "web": "http://www.dgstvdiseasescnslnts.com.au" - }, - { - "first_name": "Ronald", - "last_name": "Grube", - "company_name": "Deep Creek Pharmacy", - "address": "73778 Battery St", - "state": "SA", - "post": 5159, - "city": "Happy Valley", - "phone1": "08-3305-5436", - "phone2": "0457-126-909", - "email": "ronald.grube@yahoo.com", - "web": "http://www.deepcreekpharmacy.com.au" - }, - { - "first_name": "Jeffrey", - "last_name": "Leuenberger", - "company_name": "Walter W Lawrence Ink", - "address": "564 Almeria Ave #7474", - "state": "SA", - "post": 5171, - "city": "Pedler Creek", - "phone1": "08-1267-4421", - "phone2": "0436-612-609", - "email": "jleuenberger@yahoo.com", - "web": "http://www.walterwlawrenceink.com.au" - }, - { - "first_name": "Alfred", - "last_name": "Pacleb", - "company_name": "Roundys Pole Fence Co", - "address": "523 N Prince St", - "state": "SA", - "post": 5172, - "city": "Willunga", - "phone1": "08-9450-7978", - "phone2": "0453-896-533", - "email": "alfred@pacleb.net.au", - "web": "http://www.roundyspolefenceco.com.au" - }, - { - "first_name": "Shayne", - "last_name": "Sundahl", - "company_name": "Jaywork, John Terence Esq", - "address": "5614 Public Sq", - "state": "SA", - "post": 5204, - "city": "Normanville", - "phone1": "08-8587-1196", - "phone2": "0443-386-213", - "email": "shayne.sundahl@gmail.com", - "web": "http://www.jayworkjohnterenceesq.com.au" - }, - { - "first_name": "Huey", - "last_name": "Bukovac", - "company_name": "Venino And Venino", - "address": "6 Jefferson St", - "state": "SA", - "post": 5213, - "city": "Middleton", - "phone1": "08-5236-2143", - "phone2": "0486-924-555", - "email": "huey.bukovac@hotmail.com", - "web": "http://www.veninoandvenino.com.au" - }, - { - "first_name": "Aretha", - "last_name": "Bodle", - "company_name": "Palmetto Food Equipment Co Inc", - "address": "9561 Chartres St", - "state": "SA", - "post": 5220, - "city": "Parndana", - "phone1": "08-7385-2716", - "phone2": "0481-452-729", - "email": "aretha_bodle@hotmail.com", - "web": "http://www.palmettofoodequipmentcoinc.com.au" - }, - { - "first_name": "Valda", - "last_name": "Levay", - "company_name": "Branom Instrument Co", - "address": "7463 Elmwood Park Blvd", - "state": "SA", - "post": 5236, - "city": "Tungkillo", - "phone1": "08-2401-5672", - "phone2": "0434-637-971", - "email": "vlevay@levay.net.au", - "web": "http://www.branominstrumentco.com.au" - }, - { - "first_name": "Stefany", - "last_name": "Figueras", - "company_name": "Burke, Jonathan H Esq", - "address": "37 Saint Louis Ave #292", - "state": "SA", - "post": 5240, - "city": "Lenswood", - "phone1": "08-2209-8647", - "phone2": "0474-975-307", - "email": "stefany@figueras.net.au", - "web": "http://www.burkejonathanhesq.com.au" - }, - { - "first_name": "Gennie", - "last_name": "Pastorino", - "company_name": "Henry, Robert J Esq", - "address": "5 Austin Ave", - "state": "SA", - "post": 5244, - "city": "Charleston", - "phone1": "08-4753-2870", - "phone2": "0425-685-933", - "email": "gennie.pastorino@gmail.com", - "web": "http://www.henryrobertjesq.com.au" - }, - { - "first_name": "Lindsey", - "last_name": "Rathmann", - "company_name": "Pakzad Advertising", - "address": "5 Main St", - "state": "SA", - "post": 5291, - "city": "Kongorong", - "phone1": "08-1269-1489", - "phone2": "0499-741-651", - "email": "lindsey_rathmann@rathmann.com.au", - "web": "http://www.pakzadadvertising.com.au" - }, - { - "first_name": "Launa", - "last_name": "Vanauken", - "company_name": "Tripuraneni, Prabhakar Md", - "address": "30338 S Dunworth St", - "state": "SA", - "post": 5301, - "city": "Peake", - "phone1": "08-9808-2647", - "phone2": "0423-125-880", - "email": "launa@gmail.com", - "web": "http://www.tripuraneniprabhakarmd.com.au" - }, - { - "first_name": "Brice", - "last_name": "Bogacz", - "company_name": "Thurmon, Steven P", - "address": "76 San Pablo Ave", - "state": "SA", - "post": 5353, - "city": "Sedan", - "phone1": "08-5203-2193", - "phone2": "0467-821-930", - "email": "bbogacz@hotmail.com", - "web": "http://www.thurmonstevenp.com.au" - }, - { - "first_name": "Theron", - "last_name": "Jarding", - "company_name": "Prentiss, Paul F Esq", - "address": "8839 Ventura Blvd", - "state": "SA", - "post": 5357, - "city": "Blanchetown", - "phone1": "08-6890-4661", - "phone2": "0461-862-457", - "email": "tjarding@hotmail.com", - "web": "http://www.prentisspaulfesq.com.au" - }, - { - "first_name": "Edison", - "last_name": "Sumera", - "company_name": "Mcclier Corp", - "address": "52404 S Clinton Ave", - "state": "SA", - "post": 5374, - "city": "Bower", - "phone1": "08-9114-1763", - "phone2": "0463-377-181", - "email": "edison.sumera@sumera.net.au", - "web": "http://www.mccliercorp.com.au" - }, - { - "first_name": "Rene", - "last_name": "Burnsworth", - "company_name": "Nurses Ofr Newborns", - "address": "80289 Victory Ave #9", - "state": "SA", - "post": 5416, - "city": "Farrell Flat", - "phone1": "08-8222-3171", - "phone2": "0422-183-541", - "email": "rene@burnsworth.net.au", - "web": "http://www.nursesofrnewborns.com.au" - }, - { - "first_name": "Halina", - "last_name": "Dellen", - "company_name": "Roane, Matthew H Esq", - "address": "3318 Buckelew Ave", - "state": "SA", - "post": 5480, - "city": "Appila", - "phone1": "08-6742-2308", - "phone2": "0478-235-293", - "email": "halina.dellen@dellen.com.au", - "web": "http://www.roanematthewhesq.com.au" - }, - { - "first_name": "Cary", - "last_name": "Orazine", - "company_name": "Para Laboratories", - "address": "16 Governors Dr Sw", - "state": "SA", - "post": 5483, - "city": "Melrose", - "phone1": "08-7718-8495", - "phone2": "0419-720-227", - "email": "cary.orazine@hotmail.com", - "web": "http://www.paralaboratories.com.au" - }, - { - "first_name": "Charolette", - "last_name": "Turk", - "company_name": "Weil Mclain Co", - "address": "1 Wyckoff Ave", - "state": "SA", - "post": 5485, - "city": "Wilmington", - "phone1": "08-4735-5054", - "phone2": "0430-400-899", - "email": "cturk@yahoo.com", - "web": "http://www.weilmclainco.com.au" - }, - { - "first_name": "Dominga", - "last_name": "Barchacky", - "company_name": "South Side Machine Works Inc", - "address": "3 Ridge Rd W #949", - "state": "SA", - "post": 5495, - "city": "Port Flinders", - "phone1": "08-3087-9658", - "phone2": "0412-225-824", - "email": "dominga.barchacky@hotmail.com", - "web": "http://www.southsidemachineworksinc.com.au" - }, - { - "first_name": "Sommer", - "last_name": "Agar", - "company_name": "Poole Publications Inc", - "address": "3 N Ridge Ave", - "state": "SA", - "post": 5554, - "city": "Kadina", - "phone1": "08-9130-3372", - "phone2": "0486-599-199", - "email": "sagar@agar.net.au", - "web": "http://www.poolepublicationsinc.com.au" - }, - { - "first_name": "Alexis", - "last_name": "Morguson", - "company_name": "Carrera Casting Corp", - "address": "9 Old York Rd #418", - "state": "SA", - "post": 5573, - "city": "Weetulta", - "phone1": "08-1895-1457", - "phone2": "0475-760-952", - "email": "amorguson@morguson.com.au", - "web": "http://www.carreracastingcorp.com.au" - }, - { - "first_name": "Moira", - "last_name": "Qadir", - "company_name": "Airnetics Engineering Co", - "address": "661 Plummer St #963", - "state": "SA", - "post": 5603, - "city": "Arno Bay", - "phone1": "08-7687-4883", - "phone2": "0471-106-909", - "email": "moira.qadir@gmail.com", - "web": "http://www.airneticsengineeringco.com.au" - }, - { - "first_name": "Ngoc", - "last_name": "Guglielmina", - "company_name": "Verde, Louis J Esq", - "address": "156 Morris St", - "state": "SA", - "post": 5642, - "city": "Darke Peak", - "phone1": "08-2264-5559", - "phone2": "0490-128-503", - "email": "ngoc_guglielmina@hotmail.com", - "web": "http://www.verdelouisjesq.com.au" - }, - { - "first_name": "Gladys", - "last_name": "Schmale", - "company_name": "Amercn Spdy Printg Ctrs Ocala", - "address": "514 Glenn Way", - "state": "SA", - "post": 5661, - "city": "Wirrulla", - "phone1": "08-4564-2338", - "phone2": "0410-812-931", - "email": "gschmale@schmale.net.au", - "web": "http://www.amercnspdyprintgctrsocala.com.au" - }, - { - "first_name": "Audria", - "last_name": "Piccinich", - "company_name": "Kuhio Photo", - "address": "13 Blanchard St #996", - "state": "SA", - "post": 5723, - "city": "Coober Pedy", - "phone1": "08-9757-2379", - "phone2": "0426-175-813", - "email": "audria.piccinich@gmail.com", - "web": "http://www.kuhiophoto.com.au" - }, - { - "first_name": "Domingo", - "last_name": "Mckale", - "company_name": "Fables Gallery", - "address": "80968 Armitage Ave", - "state": "SA", - "post": 5724, - "city": "Marla", - "phone1": "08-9919-7850", - "phone2": "0418-290-707", - "email": "domingo_mckale@mckale.net.au", - "web": "http://www.fablesgallery.com.au" - }, - { - "first_name": "Hyman", - "last_name": "Phinazee", - "company_name": "Als Village Stationers", - "address": "42741 Anania Dr", - "state": "SA", - "post": 5730, - "city": "Beltana", - "phone1": "08-5756-9456", - "phone2": "0446-460-955", - "email": "hphinazee@yahoo.com", - "web": "http://www.alsvillagestationers.com.au" - }, - { - "first_name": "Candra", - "last_name": "Deritis", - "company_name": "Girling Health Care Inc", - "address": "43 Nolan St", - "state": "TAS", - "post": 7004, - "city": "Battery Point", - "phone1": "03-4231-3633", - "phone2": "0439-769-439", - "email": "candra@deritis.net.au", - "web": "http://www.girlinghealthcareinc.com.au" - }, - { - "first_name": "Ashton", - "last_name": "Sutherburg", - "company_name": "Southwark Corporation", - "address": "960 S Arroyo Pkwy", - "state": "TAS", - "post": 7004, - "city": "South Hobart", - "phone1": "03-9215-3224", - "phone2": "0427-327-492", - "email": "asutherburg@gmail.com", - "web": "http://www.southwarkcorporation.com.au" - }, - { - "first_name": "Ronald", - "last_name": "Gayner", - "company_name": "Moorhead, Michael D Esq", - "address": "438 E Reynolds Rd #239", - "state": "TAS", - "post": 7005, - "city": "University Of Tasmania", - "phone1": "03-7734-9557", - "phone2": "0499-737-220", - "email": "rgayner@hotmail.com", - "web": "http://www.moorheadmichaeldesq.com.au" - }, - { - "first_name": "Kris", - "last_name": "Medich", - "company_name": "Chieftain Four Inc", - "address": "94843 Trabold Rd #59", - "state": "TAS", - "post": 7030, - "city": "Shannon", - "phone1": "03-6589-2556", - "phone2": "0469-243-477", - "email": "kris.medich@hotmail.com", - "web": "http://www.chieftainfourinc.com.au" - }, - { - "first_name": "Kenny", - "last_name": "Leicht", - "company_name": "Gaddis Court Reporting", - "address": "245 5th Ave", - "state": "TAS", - "post": 7112, - "city": "Nicholls Rivulet", - "phone1": "03-6240-8274", - "phone2": "0486-712-822", - "email": "kenny@leicht.com.au", - "web": "http://www.gaddiscourtreporting.com.au" - }, - { - "first_name": "Buffy", - "last_name": "Stitely", - "company_name": "Stylecraft Corporation", - "address": "5 Madison St #4651", - "state": "TAS", - "post": 7116, - "city": "Police Point", - "phone1": "03-1600-5230", - "phone2": "0451-121-905", - "email": "buffy_stitely@stitely.com.au", - "web": "http://www.stylecraftcorporation.com.au" - }, - { - "first_name": "Robt", - "last_name": "Blanck", - "company_name": "Elan Techlgy A Divsn Mansol", - "address": "790 E Wisconsin Ave", - "state": "TAS", - "post": 7120, - "city": "Woodbury", - "phone1": "03-6517-9318", - "phone2": "0415-690-961", - "email": "robt.blanck@yahoo.com", - "web": "http://www.elantechlgyadivsnmansol.com.au" - }, - { - "first_name": "Marica", - "last_name": "Tarbor", - "company_name": "Prudential Lighting Corp", - "address": "68828 S 32nd St #6", - "state": "TAS", - "post": 7140, - "city": "Rosegarland", - "phone1": "03-1174-6817", - "phone2": "0494-982-617", - "email": "marica.tarbor@hotmail.com", - "web": "http://www.prudentiallightingcorp.com.au" - }, - { - "first_name": "Melinda", - "last_name": "Fellhauer", - "company_name": "Sterling Institute", - "address": "8275 Calle De Industrias", - "state": "TAS", - "post": 7140, - "city": "Wayatinah", - "phone1": "03-4387-3800", - "phone2": "0493-258-647", - "email": "melinda_fellhauer@fellhauer.com.au", - "web": "http://www.sterlinginstitute.com.au" - }, - { - "first_name": "Dorathy", - "last_name": "Miskelly", - "company_name": "Perrysburg Animal Care Inc", - "address": "73 Robert S", - "state": "TAS", - "post": 7140, - "city": "Westerway", - "phone1": "03-6340-9772", - "phone2": "0432-706-521", - "email": "dorathy.miskelly@gmail.com", - "web": "http://www.perrysburganimalcareinc.com.au" - }, - { - "first_name": "Frederick", - "last_name": "Tamburello", - "company_name": "Signs By Berry", - "address": "262 8th St", - "state": "TAS", - "post": 7150, - "city": "Simpsons Bay", - "phone1": "03-4800-7102", - "phone2": "0466-921-460", - "email": "frederick.tamburello@hotmail.com", - "web": "http://www.signsbyberry.com.au" - }, - { - "first_name": "Bettye", - "last_name": "Meray", - "company_name": "Sako, Bradley T Esq", - "address": "248 Academy Rd", - "state": "TAS", - "post": 7163, - "city": "Middleton", - "phone1": "03-9424-2956", - "phone2": "0420-742-142", - "email": "bmeray@yahoo.com", - "web": "http://www.sakobradleytesq.com.au" - }, - { - "first_name": "Leandro", - "last_name": "Bolka", - "company_name": "Classic Video Duplication Inc", - "address": "1886 2nd Ave", - "state": "TAS", - "post": 7172, - "city": "Wattle Hill", - "phone1": "03-8157-4609", - "phone2": "0413-530-467", - "email": "leandro_bolka@hotmail.com", - "web": "http://www.classicvideoduplicationinc.com.au" - }, - { - "first_name": "Linwood", - "last_name": "Wessner", - "company_name": "Moorhead Associates Inc", - "address": "9634 South St", - "state": "TAS", - "post": 7186, - "city": "Saltwater River", - "phone1": "03-6053-2447", - "phone2": "0487-913-509", - "email": "linwood.wessner@hotmail.com", - "web": "http://www.moorheadassociatesinc.com.au" - }, - { - "first_name": "Karon", - "last_name": "Etzler", - "company_name": "Rachmel & Company Cpa Pa", - "address": "97539 Connecticut Ave Nw #3586", - "state": "TAS", - "post": 7190, - "city": "Buckland", - "phone1": "03-6698-8416", - "phone2": "0432-184-936", - "email": "karon@hotmail.com", - "web": "http://www.rachmelcompanycpapa.com.au" - }, - { - "first_name": "Luis", - "last_name": "Yerry", - "company_name": "On Your Feet", - "address": "72984 W 1st St", - "state": "TAS", - "post": 7250, - "city": "Summerhill", - "phone1": "03-4492-4927", - "phone2": "0490-571-461", - "email": "luis@hotmail.com", - "web": "http://www.onyourfeet.com.au" - }, - { - "first_name": "Matilda", - "last_name": "Peleg", - "company_name": "A & D Pallet Co", - "address": "708 S Wilson Way", - "state": "TAS", - "post": 7252, - "city": "Weymouth", - "phone1": "03-1130-5685", - "phone2": "0481-222-272", - "email": "matilda.peleg@hotmail.com", - "web": "http://www.adpalletco.com.au" - }, - { - "first_name": "Page", - "last_name": "Entzi", - "company_name": "Roland Ashcroft", - "address": "63154 Artesia Blvd", - "state": "TAS", - "post": 7255, - "city": "Blue Rocks", - "phone1": "03-2484-5500", - "phone2": "0497-335-342", - "email": "page@entzi.net.au", - "web": "http://www.rolandashcroft.com.au" - }, - { - "first_name": "Dortha", - "last_name": "Vrieze", - "company_name": "Art In Forms", - "address": "654 Seguine Ave", - "state": "TAS", - "post": 7258, - "city": "White Hills", - "phone1": "03-1981-6209", - "phone2": "0430-222-319", - "email": "dortha@vrieze.net.au", - "web": "http://www.artinforms.com.au" - }, - { - "first_name": "Ariel", - "last_name": "Stavely", - "company_name": "Grand Rapids Right To Life", - "address": "6 7th St", - "state": "TAS", - "post": 7260, - "city": "Scottsdale", - "phone1": "03-6510-4788", - "phone2": "0441-579-823", - "email": "ariel_stavely@stavely.com.au", - "web": "http://www.grandrapidsrighttolife.com.au" - }, - { - "first_name": "Laura", - "last_name": "Bourbonnais", - "company_name": "Kansas Association Ins Agtts", - "address": "2 N Valley Mills Dr", - "state": "TAS", - "post": 7264, - "city": "Cape Portland", - "phone1": "03-6543-6688", - "phone2": "0491-455-112", - "email": "laura.bourbonnais@yahoo.com", - "web": "http://www.kansasassociationinsagtts.com.au" - }, - { - "first_name": "Kanisha", - "last_name": "Reyelts", - "company_name": "American Board Of Surgery", - "address": "9 Taylor Ave", - "state": "TAS", - "post": 7275, - "city": "Holwell", - "phone1": "03-2921-8418", - "phone2": "0423-358-965", - "email": "kreyelts@yahoo.com", - "web": "http://www.americanboardofsurgery.com.au" - }, - { - "first_name": "Margurite", - "last_name": "Okon", - "company_name": "Kent, Wendy M Esq", - "address": "32 Broadway St", - "state": "TAS", - "post": 7275, - "city": "Lanena", - "phone1": "03-9721-7313", - "phone2": "0442-360-982", - "email": "margurite.okon@hotmail.com", - "web": "http://www.kentwendymesq.com.au" - }, - { - "first_name": "Phung", - "last_name": "Krome", - "company_name": "Pacific Scientific Co", - "address": "847 Norristown Rd", - "state": "TAS", - "post": 7301, - "city": "Longford", - "phone1": "03-9617-5392", - "phone2": "0417-815-258", - "email": "pkrome@yahoo.com", - "web": "http://www.pacificscientificco.com.au" - }, - { - "first_name": "Julene", - "last_name": "Lauretta", - "company_name": "Convum Internatl Corp", - "address": "1881 Market St", - "state": "TAS", - "post": 7304, - "city": "Mole Creek", - "phone1": "03-1036-9594", - "phone2": "0451-946-241", - "email": "julene.lauretta@gmail.com", - "web": "http://www.convuminternatlcorp.com.au" - }, - { - "first_name": "Amos", - "last_name": "Limberg", - "company_name": "Pioneer Telephone Paging", - "address": "8 2nd St", - "state": "TAS", - "post": 7310, - "city": "Don", - "phone1": "03-4539-9131", - "phone2": "0492-444-651", - "email": "alimberg@limberg.com.au", - "web": "http://www.pioneertelephonepaging.com.au" - }, - { - "first_name": "Rebbecca", - "last_name": "Didio", - "company_name": "Brandt, Jonathan F Esq", - "address": "171 E 24th St", - "state": "TAS", - "post": 7315, - "city": "Leith", - "phone1": "03-8174-9123", - "phone2": "0458-665-290", - "email": "rebbecca.didio@didio.com.au", - "web": "http://www.brandtjonathanfesq.com.au" - }, - { - "first_name": "Brittney", - "last_name": "Lolley", - "company_name": "Brown Chiropractic", - "address": "2391 Pacific Blvd", - "state": "TAS", - "post": 7315, - "city": "Ulverstone", - "phone1": "03-4072-7094", - "phone2": "0451-120-660", - "email": "brittney@lolley.net.au", - "web": "http://www.brownchiropractic.com.au" - }, - { - "first_name": "Shawn", - "last_name": "Weibe", - "company_name": "Feutz, James F Esq", - "address": "4 Middletown Blvd #33", - "state": "TAS", - "post": 7316, - "city": "Camena", - "phone1": "03-9480-9611", - "phone2": "0456-595-946", - "email": "shawn@hotmail.com", - "web": "http://www.feutzjamesfesq.com.au" - }, - { - "first_name": "Ashleigh", - "last_name": "Rimmer", - "company_name": "Palmer Publications Inc", - "address": "15 W 11mile Rd", - "state": "TAS", - "post": 7321, - "city": "Boat Harbour Beach", - "phone1": "03-5354-9557", - "phone2": "0467-120-854", - "email": "ashleigh.rimmer@hotmail.com", - "web": "http://www.palmerpublicationsinc.com.au" - }, - { - "first_name": "Alonso", - "last_name": "Popper", - "company_name": "Sunrise Cirby Animal Hospital", - "address": "3175 Northwestern Hwy", - "state": "TAS", - "post": 7321, - "city": "Ridgley", - "phone1": "03-7036-7071", - "phone2": "0448-235-525", - "email": "alonso_popper@hotmail.com", - "web": "http://www.sunrisecirbyanimalhospital.com.au" - }, - { - "first_name": "Lajuana", - "last_name": "Vonderahe", - "company_name": "Milwaukee Courier Inc", - "address": "7 Wiley Post Way", - "state": "TAS", - "post": 7330, - "city": "Trowutta", - "phone1": "03-5661-2424", - "phone2": "0430-111-686", - "email": "lajuana.vonderahe@yahoo.com", - "web": "http://www.milwaukeecourierinc.com.au" - }, - { - "first_name": "Lavonne", - "last_name": "Esco", - "company_name": "Ansaring Answering Service", - "address": "377 Excalibur Dr", - "state": "VIC", - "post": 3002, - "city": "East Melbourne", - "phone1": "03-3474-2120", - "phone2": "0444-359-546", - "email": "lavonne.esco@yahoo.com", - "web": "http://www.ansaringansweringservice.com.au" - }, - { - "first_name": "Ellsworth", - "last_name": "Guenther", - "company_name": "Performance Consulting Grp Inc", - "address": "27730 American Ave", - "state": "VIC", - "post": 3008, - "city": "Docklands", - "phone1": "03-2749-1381", - "phone2": "0442-173-327", - "email": "eguenther@hotmail.com", - "web": "http://www.performanceconsultinggrpinc.com.au" - }, - { - "first_name": "Terina", - "last_name": "Wildeboer", - "company_name": "Burress, S Paige Esq", - "address": "462 Morris Ave", - "state": "VIC", - "post": 3011, - "city": "Seddon", - "phone1": "03-9107-7349", - "phone2": "0438-810-326", - "email": "terina_wildeboer@wildeboer.com.au", - "web": "http://www.burressspaigeesq.com.au" - }, - { - "first_name": "Laine", - "last_name": "Killean", - "company_name": "Bussard, Vicki L Esq", - "address": "767 9th Ave Sw", - "state": "VIC", - "post": 3019, - "city": "Braybrook", - "phone1": "03-2813-6426", - "phone2": "0411-276-383", - "email": "laine@gmail.com", - "web": "http://www.bussardvickilesq.com.au" - }, - { - "first_name": "Rosenda", - "last_name": "Petteway", - "company_name": "Choo Choo Caboose At Jade Bbq", - "address": "66 Congress St", - "state": "VIC", - "post": 3023, - "city": "Caroline Springs", - "phone1": "03-9599-4122", - "phone2": "0438-478-951", - "email": "rosenda@gmail.com", - "web": "http://www.choochoocabooseatjadebbq.com.au" - }, - { - "first_name": "Arthur", - "last_name": "Diniz", - "company_name": "American Western Mortgage", - "address": "79819 Palmetto Ave", - "state": "VIC", - "post": 3032, - "city": "Travancore", - "phone1": "03-2517-3453", - "phone2": "0429-206-122", - "email": "arthur@gmail.com", - "web": "http://www.americanwesternmortgage.com.au" - }, - { - "first_name": "Christene", - "last_name": "Cisney", - "company_name": "Danform Shoe Stores", - "address": "21058 Massillon Rd", - "state": "VIC", - "post": 3038, - "city": "Keilor Downs", - "phone1": "03-3630-2467", - "phone2": "0451-465-174", - "email": "christene@hotmail.com", - "web": "http://www.danformshoestores.com.au" - }, - { - "first_name": "Raelene", - "last_name": "Legeyt", - "company_name": "Barter Systems Inc", - "address": "8818 Century Park E #33", - "state": "VIC", - "post": 3046, - "city": "Oak Park", - "phone1": "03-4878-1766", - "phone2": "0463-745-755", - "email": "raelene@gmail.com", - "web": "http://www.bartersystemsinc.com.au" - }, - { - "first_name": "Shizue", - "last_name": "Hayduk", - "company_name": "R M Sloan Co Inc", - "address": "47 Hall St", - "state": "VIC", - "post": 3072, - "city": "Regent West", - "phone1": "03-2297-9891", - "phone2": "0456-480-906", - "email": "shayduk@gmail.com", - "web": "http://www.rmsloancoinc.com.au" - }, - { - "first_name": "Ivette", - "last_name": "Servantes", - "company_name": "Albright, Alexandra W Esq", - "address": "446 Woodward Ave #1", - "state": "VIC", - "post": 3073, - "city": "Reservoir", - "phone1": "03-9801-9429", - "phone2": "0488-109-742", - "email": "ivette_servantes@servantes.com.au", - "web": "http://www.albrightalexandrawesq.com.au" - }, - { - "first_name": "Zena", - "last_name": "Daria", - "company_name": "Kszl Am Radio", - "address": "57245 W Union Blvd #25", - "state": "VIC", - "post": 3079, - "city": "Ivanhoe East", - "phone1": "03-2822-8156", - "phone2": "0466-820-981", - "email": "zdaria@gmail.com", - "web": "http://www.kszlamradio.com.au" - }, - { - "first_name": "Francis", - "last_name": "Senters", - "company_name": "Middendorf Meat Quality Foods", - "address": "4562 Aurora Ave N", - "state": "VIC", - "post": 3081, - "city": "Heidelberg Rgh", - "phone1": "03-5933-7288", - "phone2": "0463-965-946", - "email": "fsenters@gmail.com", - "web": "http://www.middendorfmeatqualityfoods.com.au" - }, - { - "first_name": "Sang", - "last_name": "Weigner", - "company_name": "Hander, Deborah G Esq", - "address": "9 W Passaic St", - "state": "VIC", - "post": 3081, - "city": "Heidelberg Rgh", - "phone1": "03-8912-5755", - "phone2": "0419-565-485", - "email": "sweigner@gmail.com", - "web": "http://www.handerdeborahgesq.com.au" - }, - { - "first_name": "Antonio", - "last_name": "Eighmy", - "company_name": "Corporex Companies Inc", - "address": "1758 Park Pl", - "state": "VIC", - "post": 3084, - "city": "Eaglemont", - "phone1": "03-6144-7318", - "phone2": "0438-100-197", - "email": "antonio.eighmy@yahoo.com", - "web": "http://www.corporexcompaniesinc.com.au" - }, - { - "first_name": "Miesha", - "last_name": "Decelles", - "company_name": "L M H Inc", - "address": "457 St Sebastian Way #189", - "state": "VIC", - "post": 3095, - "city": "Eltham", - "phone1": "03-5185-6258", - "phone2": "0440-277-657", - "email": "mdecelles@decelles.net.au", - "web": "http://www.lmhinc.com.au" - }, - { - "first_name": "Javier", - "last_name": "Osmer", - "company_name": "Milgo Industrial Inc", - "address": "6 Ackerman Rd", - "state": "VIC", - "post": 3109, - "city": "Doncaster East", - "phone1": "03-8369-6924", - "phone2": "0489-202-570", - "email": "javier@osmer.com.au", - "web": "http://www.milgoindustrialinc.com.au" - }, - { - "first_name": "Eveline", - "last_name": "Brickhouse", - "company_name": "First Express", - "address": "288 N 168th Ave #266", - "state": "VIC", - "post": 3124, - "city": "Camberwell West", - "phone1": "03-9517-9800", - "phone2": "0463-242-525", - "email": "eveline@yahoo.com", - "web": "http://www.firstexpress.com.au" - }, - { - "first_name": "Marylou", - "last_name": "Lofts", - "company_name": "Lally, Lawrence D Esq", - "address": "812 Berry Blvd #96", - "state": "VIC", - "post": 3128, - "city": "Houston", - "phone1": "03-1765-4584", - "phone2": "0473-727-909", - "email": "marylou_lofts@lofts.com.au", - "web": "http://www.lallylawrencedesq.com.au" - }, - { - "first_name": "Farrah", - "last_name": "Malboeuf", - "company_name": "Slachter, David Esq", - "address": "803 Tupper Ln", - "state": "VIC", - "post": 3134, - "city": "Ringwood", - "phone1": "03-7139-6376", - "phone2": "0472-511-112", - "email": "farrah@malboeuf.com.au", - "web": "http://www.slachterdavidesq.com.au" - }, - { - "first_name": "Edda", - "last_name": "Mcquaide", - "company_name": "Eagles Nest", - "address": "9 Cron Hill Dr", - "state": "VIC", - "post": 3155, - "city": "Boronia", - "phone1": "03-1465-8645", - "phone2": "0416-330-811", - "email": "emcquaide@yahoo.com", - "web": "http://www.eaglesnest.com.au" - }, - { - "first_name": "Werner", - "last_name": "Hermens", - "company_name": "Community Health Law Project", - "address": "302 N 10th St #3896", - "state": "VIC", - "post": 3167, - "city": "Oakleigh South", - "phone1": "03-9085-5714", - "phone2": "0462-625-869", - "email": "whermens@hermens.net.au", - "web": "http://www.communityhealthlawproject.com.au" - }, - { - "first_name": "Burma", - "last_name": "Noa", - "company_name": "Saum, Scott J Esq", - "address": "79 State Route 35", - "state": "VIC", - "post": 3185, - "city": "Ripponlea", - "phone1": "03-6438-4586", - "phone2": "0448-770-746", - "email": "burma.noa@gmail.com", - "web": "http://www.saumscottjesq.com.au" - }, - { - "first_name": "Denae", - "last_name": "Saeteun", - "company_name": "Domurad, John M Esq", - "address": "52680 W Hwy 55 #59", - "state": "VIC", - "post": 3194, - "city": "Moorabbin Airport", - "phone1": "03-2802-7434", - "phone2": "0410-539-386", - "email": "denae_saeteun@hotmail.com", - "web": "http://www.domuradjohnmesq.com.au" - }, - { - "first_name": "Alberta", - "last_name": "Motter", - "company_name": "Turl Engineering Works", - "address": "33108 S Yosemite Ct", - "state": "VIC", - "post": 3207, - "city": "Port Melbourne", - "phone1": "03-1248-8221", - "phone2": "0491-832-907", - "email": "alberta_motter@hotmail.com", - "web": "http://www.turlengineeringworks.com.au" - }, - { - "first_name": "Nikita", - "last_name": "Novosel", - "company_name": "Universal Granite & Marble Inc", - "address": "70 W Market St #20", - "state": "VIC", - "post": 3215, - "city": "Hamlyn Heights", - "phone1": "03-5716-1053", - "phone2": "0470-886-805", - "email": "nikita_novosel@novosel.net.au", - "web": "http://www.universalgranitemarbleinc.com.au" - }, - { - "first_name": "Jackie", - "last_name": "Borchelt", - "company_name": "Community Communication Servs", - "address": "80896 South Ave", - "state": "VIC", - "post": 3216, - "city": "Grovedale", - "phone1": "03-8055-8668", - "phone2": "0423-545-966", - "email": "jackie_borchelt@hotmail.com", - "web": "http://www.communitycommunicationservs.com.au" - }, - { - "first_name": "Breana", - "last_name": "Cassi", - "company_name": "Gormley Lore Murphy", - "address": "405 W Lee St", - "state": "VIC", - "post": 3221, - "city": "Stonehaven", - "phone1": "03-2305-8627", - "phone2": "0495-644-883", - "email": "breana@yahoo.com", - "web": "http://www.gormleyloremurphy.com.au" - }, - { - "first_name": "Kathrine", - "last_name": "Francoise", - "company_name": "Jackson, Brian C", - "address": "30691 Poplar Ave #4", - "state": "VIC", - "post": 3223, - "city": "Indented Head", - "phone1": "03-8791-9436", - "phone2": "0449-461-650", - "email": "kathrine@yahoo.com", - "web": "http://www.jacksonbrianc.com.au" - }, - { - "first_name": "Ming", - "last_name": "Thaxton", - "company_name": "Chem Aqua", - "address": "8 N Town East Blvd", - "state": "VIC", - "post": 3236, - "city": "Forrest", - "phone1": "03-4010-1900", - "phone2": "0486-557-304", - "email": "mthaxton@gmail.com", - "web": "http://www.chemaqua.com.au" - }, - { - "first_name": "Iraida", - "last_name": "Sionesini", - "company_name": "Arc Of Montgomery County Inc", - "address": "94 S Jefferson Rd", - "state": "VIC", - "post": 3240, - "city": "Modewarre", - "phone1": "03-4812-5654", - "phone2": "0490-625-307", - "email": "iraida.sionesini@yahoo.com", - "web": "http://www.arcofmontgomerycountyinc.com.au" - }, - { - "first_name": "Lettie", - "last_name": "Hessenthaler", - "company_name": "Sullivan, John M Esq", - "address": "76542 W Bijou St", - "state": "VIC", - "post": 3241, - "city": "Wurdiboluc", - "phone1": "03-5855-5156", - "phone2": "0454-956-810", - "email": "lettie_hessenthaler@hessenthaler.net.au", - "web": "http://www.sullivanjohnmesq.com.au" - }, - { - "first_name": "Gwen", - "last_name": "Julye", - "company_name": "Alphagraphics Printshops", - "address": "8 Old County Rd #3", - "state": "VIC", - "post": 3249, - "city": "Alvie", - "phone1": "03-7063-6734", - "phone2": "0465-547-766", - "email": "gjulye@hotmail.com", - "web": "http://www.alphagraphicsprintshops.com.au" - }, - { - "first_name": "Omega", - "last_name": "Mangino", - "company_name": "Kajo 1270 Am Radio", - "address": "495 Distribution Dr #996", - "state": "VIC", - "post": 3260, - "city": "Gnotuk", - "phone1": "03-6623-5501", - "phone2": "0422-968-757", - "email": "omega.mangino@hotmail.com", - "web": "http://www.kajoamradio.com.au" - }, - { - "first_name": "Jospeh", - "last_name": "Couzens", - "company_name": "M & M Quality Printing", - "address": "2749 Van Nuys Blvd", - "state": "VIC", - "post": 3265, - "city": "Panmure", - "phone1": "03-8451-7537", - "phone2": "0452-605-630", - "email": "jospeh.couzens@couzens.com.au", - "web": "http://www.mmqualityprinting.com.au" - }, - { - "first_name": "Dahlia", - "last_name": "Tummons", - "company_name": "Bare Bones", - "address": "6508 Adams St #32", - "state": "VIC", - "post": 3284, - "city": "Port Fairy", - "phone1": "03-8216-8640", - "phone2": "0430-768-907", - "email": "dahlia.tummons@gmail.com", - "web": "http://www.barebones.com.au" - }, - { - "first_name": "Lynelle", - "last_name": "Koury", - "company_name": "Jean Barbara Ltd", - "address": "7696 Carey Ave", - "state": "VIC", - "post": 3309, - "city": "Digby", - "phone1": "03-5213-8219", - "phone2": "0462-987-152", - "email": "lynelle.koury@koury.net.au", - "web": "http://www.jeanbarbaraltd.com.au" - }, - { - "first_name": "Delsie", - "last_name": "Ducos", - "company_name": "F H Overseas Export Inc", - "address": "17 Kamehameha Hwy", - "state": "VIC", - "post": 3314, - "city": "Cavendish", - "phone1": "03-1361-8465", - "phone2": "0458-548-827", - "email": "dducos@hotmail.com", - "web": "http://www.fhoverseasexportinc.com.au" - }, - { - "first_name": "Jeniffer", - "last_name": "Jezek", - "company_name": "Sheraton Inn Atlanta Northwest", - "address": "1089 Pacific Coast Hwy", - "state": "VIC", - "post": 3341, - "city": "Myrniong", - "phone1": "03-3268-5102", - "phone2": "0493-644-827", - "email": "jeniffer@gmail.com", - "web": "http://www.sheratoninnatlantanorthwest.com.au" - }, - { - "first_name": "Millie", - "last_name": "Pirkl", - "company_name": "Mann, Charles E Esq", - "address": "31 Schuyler Ave", - "state": "VIC", - "post": 3350, - "city": "Sovereign Hill", - "phone1": "03-6023-2680", - "phone2": "0410-688-713", - "email": "millie_pirkl@gmail.com", - "web": "http://www.manncharleseesq.com.au" - }, - { - "first_name": "Shaun", - "last_name": "Rael", - "company_name": "House Of Ing", - "address": "14304 Old Alexandria Ferry Rd", - "state": "VIC", - "post": 3357, - "city": "Buninyong", - "phone1": "03-8998-5485", - "phone2": "0498-627-281", - "email": "shaun.rael@rael.com.au", - "web": "http://www.houseofing.com.au" - }, - { - "first_name": "Juan", - "last_name": "Knudtson", - "company_name": "Newton Clerk", - "address": "466 Lincoln Blvd", - "state": "VIC", - "post": 3370, - "city": "Clunes", - "phone1": "03-9173-6140", - "phone2": "0474-730-764", - "email": "juan@gmail.com", - "web": "http://www.newtonclerk.com.au" - }, - { - "first_name": "Silvana", - "last_name": "Whelpley", - "company_name": "Stamp House", - "address": "548 Charmonie Ln", - "state": "VIC", - "post": 3392, - "city": "Minyip", - "phone1": "03-5175-6193", - "phone2": "0489-343-254", - "email": "swhelpley@yahoo.com", - "web": "http://www.stamphouse.com.au" - }, - { - "first_name": "Ora", - "last_name": "Handrick", - "company_name": "Fennessey Buick Inc", - "address": "466 Hillsdale Ave", - "state": "VIC", - "post": 3401, - "city": "Rocklands", - "phone1": "03-8357-4617", - "phone2": "0411-111-689", - "email": "ora.handrick@gmail.com", - "web": "http://www.fennesseybuickinc.com.au" - }, - { - "first_name": "Tien", - "last_name": "Kinney", - "company_name": "Orco State Empl Fed Crdt Un", - "address": "9 9th St #4", - "state": "VIC", - "post": 3420, - "city": "Lillimur", - "phone1": "03-7767-6169", - "phone2": "0468-244-186", - "email": "tien_kinney@kinney.com.au", - "web": "http://www.orcostateemplfedcrdtun.com.au" - }, - { - "first_name": "Wai", - "last_name": "Raddle", - "company_name": "Dot Pitch Electronics", - "address": "2 Stirrup Dr #4907", - "state": "VIC", - "post": 3442, - "city": "Carlsruhe", - "phone1": "03-4811-3832", - "phone2": "0494-517-582", - "email": "wai.raddle@raddle.com.au", - "web": "http://www.dotpitchelectronics.com.au" - }, - { - "first_name": "Clement", - "last_name": "Chee", - "company_name": "Bark Eater Inn", - "address": "5159 Saint Ann St", - "state": "VIC", - "post": 3451, - "city": "Golden Point", - "phone1": "03-2775-4083", - "phone2": "0485-660-179", - "email": "clement@hotmail.com", - "web": "http://www.barkeaterinn.com.au" - }, - { - "first_name": "Dean", - "last_name": "Vollstedt", - "company_name": "Ship It Packaging Inc", - "address": "4 Grand St", - "state": "VIC", - "post": 3462, - "city": "Muckleford South", - "phone1": "03-6776-1146", - "phone2": "0492-559-630", - "email": "dvollstedt@vollstedt.com.au", - "web": "http://www.shipitpackaginginc.com.au" - }, - { - "first_name": "Chara", - "last_name": "Leveston", - "company_name": "Arthur Andersen & Co", - "address": "72 N Buckeye Ave", - "state": "VIC", - "post": 3465, - "city": "Daisy Hill", - "phone1": "03-2574-8915", - "phone2": "0415-341-310", - "email": "cleveston@gmail.com", - "web": "http://www.arthurandersenco.com.au" - }, - { - "first_name": "Lashonda", - "last_name": "Langanke", - "company_name": "Krausert, Diane D Esq", - "address": "667 S Highland Dr #4", - "state": "VIC", - "post": 3465, - "city": "Simson", - "phone1": "03-9838-7533", - "phone2": "0491-793-730", - "email": "lashonda@langanke.net.au", - "web": "http://www.krausertdianedesq.com.au" - }, - { - "first_name": "Isaiah", - "last_name": "Kueter", - "company_name": "Jordan, Mark D Esq", - "address": "8 W Virginia St", - "state": "VIC", - "post": 3468, - "city": "Amphitheatre", - "phone1": "03-3725-6290", - "phone2": "0494-282-122", - "email": "ikueter@kueter.com.au", - "web": "http://www.jordanmarkdesq.com.au" - }, - { - "first_name": "Andrew", - "last_name": "Keks", - "company_name": "Anthonys", - "address": "51 Bridge Ave", - "state": "VIC", - "post": 3494, - "city": "Carwarp", - "phone1": "03-5251-3153", - "phone2": "0499-155-325", - "email": "andrew@gmail.com", - "web": "http://www.anthonys.com.au" - }, - { - "first_name": "Irving", - "last_name": "Plocica", - "company_name": "Johnston, George M Esq", - "address": "65 Clayton Rd", - "state": "VIC", - "post": 3496, - "city": "Cullulleraine", - "phone1": "03-9050-2741", - "phone2": "0465-434-187", - "email": "irving@hotmail.com", - "web": "http://www.johnstongeorgemesq.com.au" - }, - { - "first_name": "Lina", - "last_name": "Schwiebert", - "company_name": "Chemex Labs Ltd", - "address": "68538 N Bentz St #1451", - "state": "VIC", - "post": 3501, - "city": "Koorlong", - "phone1": "03-3608-5660", - "phone2": "0487-835-113", - "email": "lina@yahoo.com", - "web": "http://www.chemexlabsltd.com.au" - }, - { - "first_name": "Pansy", - "last_name": "Todesco", - "company_name": "Schmidt, Charles E Jr", - "address": "684 William St", - "state": "VIC", - "post": 3551, - "city": "Tarnagulla", - "phone1": "03-3233-4255", - "phone2": "0467-468-894", - "email": "pansy_todesco@gmail.com", - "web": "http://www.schmidtcharlesejr.com.au" - }, - { - "first_name": "Aleta", - "last_name": "Poarch", - "company_name": "Barrett Burke Wilson Castl", - "address": "5 Liberty Ave", - "state": "VIC", - "post": 3557, - "city": "Fosterville", - "phone1": "03-2691-1298", - "phone2": "0419-138-629", - "email": "apoarch@gmail.com", - "web": "http://www.barrettburkewilsoncastl.com.au" - }, - { - "first_name": "Brigette", - "last_name": "Breckenstein", - "company_name": "Blewett, Yvonne S", - "address": "971 Northwest Blvd", - "state": "VIC", - "post": 3630, - "city": "Caniambo", - "phone1": "03-5722-3451", - "phone2": "0462-308-800", - "email": "brigette@breckenstein.com.au", - "web": "http://www.blewettyvonnes.com.au" - }, - { - "first_name": "Eleonore", - "last_name": "Everline", - "company_name": "Psychotherapy Associates", - "address": "1 Us Highway 206", - "state": "VIC", - "post": 3631, - "city": "Kialla East", - "phone1": "03-5355-5505", - "phone2": "0497-442-813", - "email": "eeverline@hotmail.com", - "web": "http://www.psychotherapyassociates.com.au" - }, - { - "first_name": "Geraldine", - "last_name": "Neisius", - "company_name": "Re/max Realty Services", - "address": "96 Armitage Ave", - "state": "VIC", - "post": 3640, - "city": "Katunga", - "phone1": "03-8243-2999", - "phone2": "0440-707-817", - "email": "geraldine@gmail.com", - "web": "http://www.remaxrealtyservices.com.au" - }, - { - "first_name": "Felix", - "last_name": "Bumby", - "company_name": "Epsilon Products Company", - "address": "82 Tremont St #4", - "state": "VIC", - "post": 3670, - "city": "Baddaginnie", - "phone1": "03-1431-3996", - "phone2": "0485-718-212", - "email": "felix.bumby@bumby.com.au", - "web": "http://www.epsilonproductscompany.com.au" - }, - { - "first_name": "Gracie", - "last_name": "Vicente", - "company_name": "Central Nebraska Home Care", - "address": "4 W 18th St", - "state": "VIC", - "post": 3678, - "city": "Oxley", - "phone1": "03-2444-8291", - "phone2": "0420-776-847", - "email": "gracie.vicente@hotmail.com", - "web": "http://www.centralnebraskahomecare.com.au" - }, - { - "first_name": "Skye", - "last_name": "Culcasi", - "company_name": "Sullivan & Associates Ltd", - "address": "82655 Shawnee Mission Pky #5798", - "state": "VIC", - "post": 3688, - "city": "Barnawartha", - "phone1": "03-9075-3104", - "phone2": "0451-601-420", - "email": "skye_culcasi@hotmail.com", - "web": "http://www.sullivanassociatesltd.com.au" - }, - { - "first_name": "Henriette", - "last_name": "Gish", - "company_name": "Parker Bush & Lane Pc", - "address": "43 E Main St", - "state": "VIC", - "post": 3691, - "city": "Baranduda", - "phone1": "03-9935-5135", - "phone2": "0413-952-396", - "email": "henriette.gish@gish.net.au", - "web": "http://www.parkerbushlanepc.com.au" - }, - { - "first_name": "Inocencia", - "last_name": "Angeron", - "company_name": "South Adams Savings Bank", - "address": "13386 Tamarco Dr #20", - "state": "VIC", - "post": 3697, - "city": "Tawonga", - "phone1": "03-6268-2647", - "phone2": "0482-712-669", - "email": "inocencia.angeron@angeron.net.au", - "web": "http://www.southadamssavingsbank.com.au" - }, - { - "first_name": "Marilynn", - "last_name": "Herrera", - "company_name": "Brown, Alan Esq", - "address": "717 Midway Pl", - "state": "VIC", - "post": 3697, - "city": "Tawonga", - "phone1": "03-1447-7041", - "phone2": "0474-199-825", - "email": "marilynn.herrera@herrera.net.au", - "web": "http://www.brownalanesq.com.au" - }, - { - "first_name": "Carman", - "last_name": "Robasciotti", - "company_name": "Vaughan, James J Esq", - "address": "4 Spinning Wheel Ln", - "state": "VIC", - "post": 3701, - "city": "Granya", - "phone1": "03-1570-9956", - "phone2": "0420-704-683", - "email": "carman_robasciotti@hotmail.com", - "web": "http://www.vaughanjamesjesq.com.au" - }, - { - "first_name": "Delbert", - "last_name": "Houben", - "company_name": "Hermann Assocs Inc Safe Mart", - "address": "59 Murray Hill Pky", - "state": "VIC", - "post": 3701, - "city": "Mitta Mitta", - "phone1": "03-1560-6800", - "phone2": "0417-833-905", - "email": "delbert.houben@hotmail.com", - "web": "http://www.hermannassocsincsafemart.com.au" - }, - { - "first_name": "Carylon", - "last_name": "Bayot", - "company_name": "Wzyx 1440 Am", - "address": "5905 S 32nd St", - "state": "VIC", - "post": 3714, - "city": "Alexandra", - "phone1": "03-8858-7088", - "phone2": "0475-926-458", - "email": "carylon@gmail.com", - "web": "http://www.wzyxam.com.au" - }, - { - "first_name": "Glynda", - "last_name": "Sanzenbacher", - "company_name": "Hinkson Cooper Weaver Inc", - "address": "80 Monroe St", - "state": "VIC", - "post": 3757, - "city": "Kinglake West", - "phone1": "03-1051-7865", - "phone2": "0451-639-283", - "email": "glynda@sanzenbacher.com.au", - "web": "http://www.hinksoncooperweaverinc.com.au" - }, - { - "first_name": "Haley", - "last_name": "Vaughn", - "company_name": "Martin Nighswander & Mitchell", - "address": "29 Nottingham Way #926", - "state": "VIC", - "post": 3765, - "city": "Montrose", - "phone1": "03-7035-6484", - "phone2": "0430-736-276", - "email": "haley_vaughn@vaughn.net.au", - "web": "http://www.martinnighswandermitchell.com.au" - }, - { - "first_name": "Georgeanna", - "last_name": "Silverstone", - "company_name": "Emess Professional Svces", - "address": "185 W Guadalupe Rd", - "state": "VIC", - "post": 3775, - "city": "Steels Creek", - "phone1": "03-7416-6750", - "phone2": "0436-793-916", - "email": "georgeanna@silverstone.net.au", - "web": "http://www.emessprofessionalsvces.com.au" - }, - { - "first_name": "Felicitas", - "last_name": "Orlinski", - "company_name": "Jen E Distributing Co", - "address": "9 Beverly Rd #5", - "state": "VIC", - "post": 3782, - "city": "Emerald", - "phone1": "03-2451-1896", - "phone2": "0444-326-506", - "email": "felicitas_orlinski@orlinski.com.au", - "web": "http://www.jenedistributingco.com.au" - }, - { - "first_name": "Marcos", - "last_name": "Seniff", - "company_name": "Arizona Equipment Trnsprt Inc", - "address": "228 S Tyler St", - "state": "VIC", - "post": 3782, - "city": "Emerald", - "phone1": "03-6340-5010", - "phone2": "0464-786-310", - "email": "marcos_seniff@gmail.com", - "web": "http://www.arizonaequipmenttrnsprtinc.com.au" - }, - { - "first_name": "Lore", - "last_name": "Brothers", - "company_name": "American General Finance", - "address": "70086 Division St #3", - "state": "VIC", - "post": 3791, - "city": "Kallista", - "phone1": "03-8780-3473", - "phone2": "0449-337-116", - "email": "lore@hotmail.com", - "web": "http://www.americangeneralfinance.com.au" - }, - { - "first_name": "Malcom", - "last_name": "Leja", - "company_name": "Johnsen, Robert U Esq", - "address": "56232 Hohman Ave", - "state": "VIC", - "post": 3809, - "city": "Officer", - "phone1": "03-2477-9133", - "phone2": "0412-417-394", - "email": "malcom@leja.com.au", - "web": "http://www.johnsenrobertuesq.com.au" - }, - { - "first_name": "Pa", - "last_name": "Badgero", - "company_name": "Korolishin, Michael Esq", - "address": "20 Meadow Ln", - "state": "VIC", - "post": 3810, - "city": "Pakenham Upper", - "phone1": "03-1861-5074", - "phone2": "0480-433-145", - "email": "pa_badgero@badgero.com.au", - "web": "http://www.korolishinmichaelesq.com.au" - }, - { - "first_name": "Artie", - "last_name": "Saine", - "company_name": "Dixon, Eric D Esq", - "address": "41 Washington Blvd", - "state": "VIC", - "post": 3814, - "city": "Cora Lynn", - "phone1": "03-3457-2524", - "phone2": "0433-550-202", - "email": "artie_saine@yahoo.com", - "web": "http://www.dixonericdesq.com.au" - }, - { - "first_name": "Jesus", - "last_name": "Merkt", - "company_name": "Unr Rohn", - "address": "1554 Bracken Crk", - "state": "VIC", - "post": 3858, - "city": "Licola", - "phone1": "03-9341-9757", - "phone2": "0492-739-675", - "email": "jesus_merkt@merkt.net.au", - "web": "http://www.unrrohn.com.au" - }, - { - "first_name": "Reta", - "last_name": "Qazi", - "company_name": "American Pie Co Inc", - "address": "1351 Simpson St", - "state": "VIC", - "post": 3860, - "city": "Maffra", - "phone1": "03-1974-9948", - "phone2": "0446-105-779", - "email": "reta.qazi@yahoo.com", - "web": "http://www.americanpiecoinc.com.au" - }, - { - "first_name": "Gianna", - "last_name": "Eilers", - "company_name": "Cochnower Pest Control", - "address": "7 Valley Blvd", - "state": "VIC", - "post": 3885, - "city": "Buchan", - "phone1": "03-4328-5253", - "phone2": "0418-994-884", - "email": "gianna@yahoo.com", - "web": "http://www.cochnowerpestcontrol.com.au" - }, - { - "first_name": "Alonzo", - "last_name": "Polek", - "company_name": "Braid Electric Co", - "address": "8 S Plaza Dr", - "state": "VIC", - "post": 3888, - "city": "Tubbut", - "phone1": "03-2403-7167", - "phone2": "0419-100-429", - "email": "alonzo_polek@polek.net.au", - "web": "http://www.braidelectricco.com.au" - }, - { - "first_name": "Hector", - "last_name": "Barras", - "company_name": "Vernon Manor Hotel", - "address": "62 J St #450", - "state": "VIC", - "post": 3889, - "city": "Combienbar", - "phone1": "03-3017-8394", - "phone2": "0438-431-666", - "email": "hector.barras@barras.com.au", - "web": "http://www.vernonmanorhotel.com.au" - }, - { - "first_name": "Gabriele", - "last_name": "Frabotta", - "company_name": "Stewart Levine & Davis", - "address": "6 Abbott Rd", - "state": "VIC", - "post": 3895, - "city": "Ensay", - "phone1": "03-2689-6049", - "phone2": "0460-834-526", - "email": "gabriele_frabotta@gmail.com", - "web": "http://www.stewartlevinedavis.com.au" - }, - { - "first_name": "Tamala", - "last_name": "Hickie", - "company_name": "Mister Bagel", - "address": "351 Crooks Rd", - "state": "VIC", - "post": 3900, - "city": "Benambra", - "phone1": "03-3695-2399", - "phone2": "0432-182-830", - "email": "tamala_hickie@yahoo.com", - "web": "http://www.misterbagel.com.au" - }, - { - "first_name": "Kristin", - "last_name": "Shiflet", - "company_name": "Jones, Peter B Esq", - "address": "503 Fulford Ave", - "state": "VIC", - "post": 3927, - "city": "Somers", - "phone1": "03-4529-7210", - "phone2": "0488-223-788", - "email": "kristin@hotmail.com", - "web": "http://www.jonespeterbesq.com.au" - }, - { - "first_name": "Frederic", - "last_name": "Schimke", - "company_name": "Curtis & Curtis Inc", - "address": "705 Stanwix St", - "state": "VIC", - "post": 3934, - "city": "Mount Martha", - "phone1": "03-4829-5695", - "phone2": "0435-982-307", - "email": "fschimke@schimke.com.au", - "web": "http://www.curtiscurtisinc.com.au" - }, - { - "first_name": "Barrie", - "last_name": "Nicley", - "company_name": "Paragon Cable Tv", - "address": "4129 Abbott Dr", - "state": "VIC", - "post": 3959, - "city": "Fish Creek", - "phone1": "03-6443-2786", - "phone2": "0455-270-505", - "email": "bnicley@nicley.com.au", - "web": "http://www.paragoncabletv.com.au" - }, - { - "first_name": "Lynda", - "last_name": "Lazzaro", - "company_name": "Funding Equity Corp", - "address": "20214 W Main St", - "state": "VIC", - "post": 3971, - "city": "Macks Creek", - "phone1": "03-4933-4205", - "phone2": "0472-315-303", - "email": "lynda.lazzaro@gmail.com", - "web": "http://www.fundingequitycorp.com.au" - }, - { - "first_name": "Sabrina", - "last_name": "Rabena", - "company_name": "Joyces Submarine Sandwiches", - "address": "327 Ward Pky", - "state": "VIC", - "post": 3981, - "city": "Bayles", - "phone1": "03-5662-3542", - "phone2": "0486-768-529", - "email": "sabrina_rabena@hotmail.com", - "web": "http://www.joycessubmarinesandwiches.com.au" - }, - { - "first_name": "Dexter", - "last_name": "Prosienski", - "company_name": "Communication Buildings Amer", - "address": "490 Court St", - "state": "VIC", - "post": 3987, - "city": "Nyora", - "phone1": "03-2454-6523", - "phone2": "0472-707-132", - "email": "dexter@prosienski.net.au", - "web": "http://www.communicationbuildingsamer.com.au" - }, - { - "first_name": "Lawana", - "last_name": "Yuasa", - "company_name": "Viking Lodge", - "address": "77818 Prince Drew Rd", - "state": "VIC", - "post": 3995, - "city": "Cape Paterson", - "phone1": "03-2324-3472", - "phone2": "0456-330-756", - "email": "lawana_yuasa@yuasa.net.au", - "web": "http://www.vikinglodge.com.au" - }, - { - "first_name": "Selma", - "last_name": "Elm", - "company_name": "Preston, Anne M Esq", - "address": "6787 Emerson St", - "state": "VIC", - "post": 3995, - "city": "Woolamai", - "phone1": "03-9183-9493", - "phone2": "0418-581-770", - "email": "selm@elm.net.au", - "web": "http://www.prestonannemesq.com.au" - }, - { - "first_name": "Sharan", - "last_name": "Wodicka", - "company_name": "Usa Asbestos Co", - "address": "8454 6 17 M At Bradleys", - "state": "WA", - "post": 6008, - "city": "Shenton Park", - "phone1": "08-4712-2157", - "phone2": "0413-129-424", - "email": "sharan@wodicka.net.au", - "web": "http://www.usaasbestosco.com.au" - }, - { - "first_name": "Grover", - "last_name": "Reynolds", - "company_name": "Okon Inc", - "address": "2867 Industrial Way", - "state": "WA", - "post": 6018, - "city": "Innaloo", - "phone1": "08-7785-3040", - "phone2": "0447-228-633", - "email": "grover.reynolds@gmail.com", - "web": "http://www.okoninc.com.au" - }, - { - "first_name": "Curtis", - "last_name": "Ware", - "company_name": "American Inst Muscl Studies", - "address": "51 Greenwood Ave", - "state": "WA", - "post": 6030, - "city": "Ridgewood", - "phone1": "08-6278-9532", - "phone2": "0484-331-585", - "email": "curtis@ware.net.au", - "web": "http://www.americaninstmusclstudies.com.au" - }, - { - "first_name": "Thomasena", - "last_name": "Graziosi", - "company_name": "Hutchinson Inc", - "address": "5 Jackson St", - "state": "WA", - "post": 6031, - "city": "Neerabup", - "phone1": "08-4849-4417", - "phone2": "0434-497-618", - "email": "thomasena@gmail.com", - "web": "http://www.hutchinsoninc.com.au" - }, - { - "first_name": "Leatha", - "last_name": "Block", - "company_name": "Chadds Ford Winery", - "address": "6926 Orange Ave", - "state": "WA", - "post": 6037, - "city": "Two Rocks", - "phone1": "08-7635-8350", - "phone2": "0445-211-162", - "email": "leatha_block@gmail.com", - "web": "http://www.chaddsfordwinery.com.au" - }, - { - "first_name": "Wilburn", - "last_name": "Lary", - "company_name": "Padrick, Comer W Jr", - "address": "72 Park Ave", - "state": "WA", - "post": 6041, - "city": "Gabbadah", - "phone1": "08-1042-4275", - "phone2": "0431-743-155", - "email": "wlary@lary.net.au", - "web": "http://www.padrickcomerwjr.com.au" - }, - { - "first_name": "Marci", - "last_name": "Aveline", - "company_name": "Richards, Don R Esq", - "address": "58 State St #998", - "state": "WA", - "post": 6056, - "city": "Boya", - "phone1": "08-3342-3889", - "phone2": "0447-443-927", - "email": "marci.aveline@hotmail.com", - "web": "http://www.richardsdonresq.com.au" - }, - { - "first_name": "Virgilio", - "last_name": "Phay", - "company_name": "Reef Encrustaceans", - "address": "8494 E 57th St", - "state": "WA", - "post": 6056, - "city": "Stratton", - "phone1": "08-8147-9584", - "phone2": "0460-368-567", - "email": "vphay@phay.com.au", - "web": "http://www.reefencrustaceans.com.au" - }, - { - "first_name": "Lorita", - "last_name": "Roches", - "company_name": "Village Meadows", - "address": "32 E Poythress St", - "state": "WA", - "post": 6061, - "city": "Westminster", - "phone1": "08-2358-3115", - "phone2": "0436-530-773", - "email": "lorita_roches@roches.net.au", - "web": "http://www.villagemeadows.com.au" - }, - { - "first_name": "Johana", - "last_name": "Conquest", - "company_name": "Henri D Kahn Insurance", - "address": "19 Court St", - "state": "WA", - "post": 6076, - "city": "Paulls Valley", - "phone1": "08-6579-7569", - "phone2": "0442-561-392", - "email": "johana@conquest.net.au", - "web": "http://www.henridkahninsurance.com.au" - }, - { - "first_name": "Alva", - "last_name": "Shoulders", - "company_name": "Warren Leadership", - "address": "461 S Fannin Ave", - "state": "WA", - "post": 6106, - "city": "Welshpool", - "phone1": "08-8329-4211", - "phone2": "0471-940-163", - "email": "alva@gmail.com", - "web": "http://www.warrenleadership.com.au" - }, - { - "first_name": "Daisy", - "last_name": "Kearsey", - "company_name": "Faber Castell Corporation", - "address": "556 Bernardo Cent", - "state": "WA", - "post": 6112, - "city": "Mount Nasura", - "phone1": "08-2127-5977", - "phone2": "0455-503-406", - "email": "dkearsey@yahoo.com", - "web": "http://www.fabercastellcorporation.com.au" - }, - { - "first_name": "Corrina", - "last_name": "Lindblom", - "company_name": "Progressive Machine Co", - "address": "1 Westpark Dr", - "state": "WA", - "post": 6152, - "city": "Salter Point", - "phone1": "08-7915-5110", - "phone2": "0463-118-373", - "email": "clindblom@gmail.com", - "web": "http://www.progressivemachineco.com.au" - }, - { - "first_name": "Yolande", - "last_name": "Scrimsher", - "company_name": "Spclty Fastening Systems Inc", - "address": "71089 Queens Blvd", - "state": "WA", - "post": 6155, - "city": "Canning Vale", - "phone1": "08-2136-2433", - "phone2": "0472-691-355", - "email": "yolande@yahoo.com", - "web": "http://www.spcltyfasteningsystemsinc.com.au" - }, - { - "first_name": "Lauran", - "last_name": "Huntsberger", - "company_name": "Triangle Engineering Inc", - "address": "41 E Jackson St", - "state": "WA", - "post": 6155, - "city": "Willetton", - "phone1": "08-2704-3706", - "phone2": "0476-605-889", - "email": "lhuntsberger@huntsberger.net.au", - "web": "http://www.triangleengineeringinc.com.au" - }, - { - "first_name": "Tammi", - "last_name": "Schiavi", - "company_name": "Crew, Robert B Esq", - "address": "78 Sw Beaverton Hillsdale H", - "state": "WA", - "post": 6155, - "city": "Willetton", - "phone1": "08-9707-2679", - "phone2": "0425-809-254", - "email": "tammi.schiavi@hotmail.com", - "web": "http://www.crewrobertbesq.com.au" - }, - { - "first_name": "Coletta", - "last_name": "Thro", - "company_name": "Hoffman, Carl Esq", - "address": "64865 Main St", - "state": "WA", - "post": 6159, - "city": "North Fremantle", - "phone1": "08-1991-6947", - "phone2": "0444-915-799", - "email": "coletta.thro@thro.net.au", - "web": "http://www.hoffmancarlesq.com.au" - }, - { - "first_name": "Chaya", - "last_name": "Muhlbauer", - "company_name": "Henry D Lederman", - "address": "44009 W 63rd #269", - "state": "WA", - "post": 6207, - "city": "North Dandalup", - "phone1": "08-5943-4352", - "phone2": "0469-609-289", - "email": "chaya_muhlbauer@muhlbauer.net.au", - "web": "http://www.henrydlederman.com.au" - }, - { - "first_name": "Juliann", - "last_name": "Dammeyer", - "company_name": "Wilheim, Kari A Esq", - "address": "6 De Belier Rue", - "state": "WA", - "post": 6210, - "city": "Bouvard", - "phone1": "08-3562-8644", - "phone2": "0492-961-209", - "email": "juliann@gmail.com", - "web": "http://www.wilheimkariaesq.com.au" - }, - { - "first_name": "Clare", - "last_name": "Bortignon", - "company_name": "Sparta Home Center", - "address": "73 Dennison St #70", - "state": "WA", - "post": 6210, - "city": "Herron", - "phone1": "08-9256-6135", - "phone2": "0423-874-910", - "email": "clare_bortignon@hotmail.com", - "web": "http://www.spartahomecenter.com.au" - }, - { - "first_name": "Ettie", - "last_name": "Luckenbach", - "company_name": "S E M A", - "address": "2902 Edison Dr #278", - "state": "WA", - "post": 6210, - "city": "Mandurah East", - "phone1": "08-9378-7021", - "phone2": "0424-568-217", - "email": "ettie@yahoo.com", - "web": "http://www.sema.com.au" - }, - { - "first_name": "Mariko", - "last_name": "Stayer", - "company_name": "Inabinet, Macre Esq", - "address": "534 Schoenborn St #51", - "state": "WA", - "post": 6215, - "city": "Hamel", - "phone1": "08-5558-9019", - "phone2": "0427-885-282", - "email": "mariko_stayer@hotmail.com", - "web": "http://www.inabinetmacreesq.com.au" - }, - { - "first_name": "King", - "last_name": "Picton", - "company_name": "U S Rentals", - "address": "3 W Pioneer Dr", - "state": "WA", - "post": 6215, - "city": "Preston Beach", - "phone1": "08-7605-2080", - "phone2": "0468-322-703", - "email": "king@hotmail.com", - "web": "http://www.usrentals.com.au" - }, - { - "first_name": "Naomi", - "last_name": "Tuamoheloa", - "company_name": "Dayer Real Estate Group", - "address": "85 S Washington Ave", - "state": "WA", - "post": 6225, - "city": "Muja", - "phone1": "08-6137-1726", - "phone2": "0430-962-223", - "email": "naomi@yahoo.com", - "web": "http://www.dayerrealestategroup.com.au" - }, - { - "first_name": "Yuette", - "last_name": "Metevelis", - "company_name": "American Speedy Printing Ctrs", - "address": "8219 Roswell Rd Ne", - "state": "WA", - "post": 6237, - "city": "North Boyanup", - "phone1": "08-4700-8894", - "phone2": "0483-854-984", - "email": "yuette.metevelis@metevelis.net.au", - "web": "http://www.americanspeedyprintingctrs.com.au" - }, - { - "first_name": "Aileen", - "last_name": "Menez", - "company_name": "Cuzzo, Michael J Esq", - "address": "8 S Main St", - "state": "WA", - "post": 6258, - "city": "Manjimup", - "phone1": "08-1196-2822", - "phone2": "0495-852-298", - "email": "aileen_menez@menez.net.au", - "web": "http://www.cuzzomichaeljesq.com.au" - }, - { - "first_name": "Sherill", - "last_name": "Klar", - "company_name": "Midway Hotel", - "address": "87 Sylvan Ave", - "state": "WA", - "post": 6258, - "city": "Nyamup", - "phone1": "08-6522-8931", - "phone2": "0427-991-688", - "email": "sklar@hotmail.com", - "web": "http://www.midwayhotel.com.au" - }, - { - "first_name": "Tamra", - "last_name": "Kenfield", - "company_name": "Mackraft Signs", - "address": "481 925n N #959", - "state": "WA", - "post": 6280, - "city": "Kealy", - "phone1": "08-5614-9153", - "phone2": "0438-378-139", - "email": "tkenfield@kenfield.com.au", - "web": "http://www.mackraftsigns.com.au" - }, - { - "first_name": "Cassie", - "last_name": "Soros", - "company_name": "A B C Tank Co", - "address": "67765 W 11th St", - "state": "WA", - "post": 6280, - "city": "Yelverton", - "phone1": "08-2666-6390", - "phone2": "0423-281-356", - "email": "csoros@gmail.com", - "web": "http://www.abctankco.com.au" - }, - { - "first_name": "Charlena", - "last_name": "Decamp", - "company_name": "Stanco Metal Products Inc", - "address": "8 Allied Dr", - "state": "WA", - "post": 6285, - "city": "Burnside", - "phone1": "08-7615-2416", - "phone2": "0469-445-592", - "email": "charlena@gmail.com", - "web": "http://www.stancometalproductsinc.com.au" - }, - { - "first_name": "Delila", - "last_name": "Buchman", - "company_name": "Frasier Karen L Kolligs", - "address": "361 Via Colinas", - "state": "WA", - "post": 6286, - "city": "Redgate", - "phone1": "08-1791-7668", - "phone2": "0454-544-286", - "email": "delila.buchman@hotmail.com", - "web": "http://www.frasierkarenlkolligs.com.au" - }, - { - "first_name": "Lashawna", - "last_name": "Filan", - "company_name": "South Carolina State Housing F", - "address": "8 Lincoln Way W #6698", - "state": "WA", - "post": 6302, - "city": "Greenhills", - "phone1": "08-6937-4366", - "phone2": "0488-276-458", - "email": "lashawna.filan@filan.net.au", - "web": "http://www.southcarolinastatehousingf.com.au" - }, - { - "first_name": "Rachael", - "last_name": "Crawley", - "company_name": "Stamell Tabacco & Schager", - "address": "82 Hopkins Plz", - "state": "WA", - "post": 6302, - "city": "Inkpen", - "phone1": "08-2089-8553", - "phone2": "0459-738-842", - "email": "rachael@gmail.com", - "web": "http://www.stamelltabaccoschager.com.au" - }, - { - "first_name": "Pearly", - "last_name": "Hedstrom", - "company_name": "G Whitfield Richards Co", - "address": "62296 S Elliott Rd #2", - "state": "WA", - "post": 6308, - "city": "Wandering", - "phone1": "08-3412-6699", - "phone2": "0460-335-582", - "email": "pearly@gmail.com", - "web": "http://www.gwhitfieldrichardsco.com.au" - }, - { - "first_name": "Elenora", - "last_name": "Handler", - "company_name": "A & A Custom Rubber Stamps", - "address": "8 Middletown Blvd #708", - "state": "WA", - "post": 6311, - "city": "Wardering", - "phone1": "08-5671-3318", - "phone2": "0481-367-908", - "email": "ehandler@yahoo.com", - "web": "http://www.aacustomrubberstamps.com.au" - }, - { - "first_name": "Idella", - "last_name": "Scotland", - "company_name": "Artesian Ice & Cold Storage Co", - "address": "373 Lafayette St", - "state": "WA", - "post": 6316, - "city": "Cartmeticup", - "phone1": "08-7868-1355", - "phone2": "0451-966-921", - "email": "idella@hotmail.com", - "web": "http://www.artesianicecoldstorageco.com.au" - }, - { - "first_name": "Tamie", - "last_name": "Hollimon", - "company_name": "Credit Union Of The Rockies", - "address": "3 Cherokee St", - "state": "WA", - "post": 6320, - "city": "Bobalong", - "phone1": "08-7046-5484", - "phone2": "0423-870-900", - "email": "tamie@hollimon.com.au", - "web": "http://www.creditunionoftherockies.com.au" - }, - { - "first_name": "Myrtie", - "last_name": "Korba", - "company_name": "United Mortgage", - "address": "82 W Market St", - "state": "WA", - "post": 6320, - "city": "Dartnall", - "phone1": "08-3174-2706", - "phone2": "0412-679-832", - "email": "mkorba@hotmail.com", - "web": "http://www.unitedmortgage.com.au" - }, - { - "first_name": "Jessenia", - "last_name": "Sarp", - "company_name": "Skyline Lodge & Restaurant", - "address": "5775 Mechanic St #517", - "state": "WA", - "post": 6320, - "city": "Wansbrough", - "phone1": "08-8878-5994", - "phone2": "0422-775-760", - "email": "jsarp@hotmail.com", - "web": "http://www.skylinelodgerestaurant.com.au" - }, - { - "first_name": "Iola", - "last_name": "Baird", - "company_name": "Xandex Inc", - "address": "48 General George Patton Dr #8611", - "state": "WA", - "post": 6330, - "city": "Goode Beach", - "phone1": "08-2325-5905", - "phone2": "0482-635-206", - "email": "ibaird@baird.net.au", - "web": "http://www.xandexinc.com.au" - }, - { - "first_name": "Na", - "last_name": "Hodges", - "company_name": "Automatic Feed Co", - "address": "5 Aquarium Pl #1", - "state": "WA", - "post": 6336, - "city": "Ongerup", - "phone1": "08-8215-1588", - "phone2": "0444-777-459", - "email": "na_hodges@hotmail.com", - "web": "http://www.automaticfeedco.com.au" - }, - { - "first_name": "Alona", - "last_name": "Driesenga", - "company_name": "Redington, Thomas P Esq", - "address": "8961 S Central Expy", - "state": "WA", - "post": 6338, - "city": "Stirling Range National Park", - "phone1": "08-6777-4159", - "phone2": "0428-176-191", - "email": "alona_driesenga@hotmail.com", - "web": "http://www.redingtonthomaspesq.com.au" - }, - { - "first_name": "Nadine", - "last_name": "Okojie", - "company_name": "Hirsch, Walter W Esq", - "address": "56 Tank Farm Rd", - "state": "WA", - "post": 6352, - "city": "Kukerin", - "phone1": "08-9746-2341", - "phone2": "0424-801-736", - "email": "nadine.okojie@okojie.com.au", - "web": "http://www.hirschwalterwesq.com.au" - }, - { - "first_name": "Jarvis", - "last_name": "Nicols", - "company_name": "Thudium Mail Advg Company", - "address": "5656 N Fiesta Blvd", - "state": "WA", - "post": 6355, - "city": "East Newdegate", - "phone1": "08-2117-5217", - "phone2": "0436-246-951", - "email": "jarvis@gmail.com", - "web": "http://www.thudiummailadvgcompany.com.au" - }, - { - "first_name": "Yuonne", - "last_name": "Carabajal", - "company_name": "Hub Manufacturing Company Inc", - "address": "2714 Beach Blvd", - "state": "WA", - "post": 6394, - "city": "Changerup", - "phone1": "08-7432-4632", - "phone2": "0470-345-731", - "email": "ycarabajal@carabajal.com.au", - "web": "http://www.hubmanufacturingcompanyinc.com.au" - }, - { - "first_name": "Francesco", - "last_name": "Kloos", - "company_name": "Borough Clerk", - "address": "82136 Post Rd", - "state": "WA", - "post": 6397, - "city": "Rocky Gully", - "phone1": "08-1687-4873", - "phone2": "0420-185-206", - "email": "fkloos@kloos.com.au", - "web": "http://www.boroughclerk.com.au" - }, - { - "first_name": "Mary", - "last_name": "Irene", - "company_name": "Superior Trading Co", - "address": "3 N Michigan Ave", - "state": "WA", - "post": 6405, - "city": "Warding East", - "phone1": "08-8012-6469", - "phone2": "0411-620-740", - "email": "mirene@gmail.com", - "web": "http://www.superiortradingco.com.au" - }, - { - "first_name": "Armando", - "last_name": "Barkley", - "company_name": "Oregon Handling Equip Co", - "address": "70680 S Rider Trl", - "state": "WA", - "post": 6407, - "city": "Watercarrin", - "phone1": "08-8161-8201", - "phone2": "0465-254-471", - "email": "armando.barkley@yahoo.com", - "web": "http://www.oregonhandlingequipco.com.au" - }, - { - "first_name": "Ernestine", - "last_name": "Paavola", - "company_name": "Northbros Co Divsn Natl Svc", - "address": "6 E Gloria Switch Rd #96", - "state": "WA", - "post": 6409, - "city": "Yorkrakine", - "phone1": "08-1140-6357", - "phone2": "0414-354-955", - "email": "ernestine.paavola@paavola.com.au", - "web": "http://www.northbroscodivsnnatlsvc.com.au" - }, - { - "first_name": "Maryann", - "last_name": "Tates", - "company_name": "Dalbec Agency Inc", - "address": "75700 Academy Rd", - "state": "WA", - "post": 6420, - "city": "Cramphorne", - "phone1": "08-1520-4093", - "phone2": "0479-474-917", - "email": "mtates@yahoo.com", - "web": "http://www.dalbecagencyinc.com.au" - }, - { - "first_name": "Christiane", - "last_name": "Osmanski", - "company_name": "Bennett, Matthew T Esq", - "address": "85 Nw Frontage Rd", - "state": "WA", - "post": 6430, - "city": "Williamstown", - "phone1": "08-9693-9052", - "phone2": "0418-813-310", - "email": "christiane@gmail.com", - "web": "http://www.bennettmatthewtesq.com.au" - }, - { - "first_name": "Cherry", - "last_name": "Roh", - "company_name": "Ulrich, Lawrence M Esq", - "address": "75 Blackington Ave", - "state": "WA", - "post": 6445, - "city": "North Cascade", - "phone1": "08-5175-3585", - "phone2": "0476-917-926", - "email": "cherry_roh@yahoo.com", - "web": "http://www.ulrichlawrencemesq.com.au" - }, - { - "first_name": "Micah", - "last_name": "Shear", - "company_name": "United Water Resources Inc", - "address": "324 Shawnee Mission Pky", - "state": "WA", - "post": 6447, - "city": "Scaddan", - "phone1": "08-6270-6829", - "phone2": "0432-703-516", - "email": "mshear@hotmail.com", - "web": "http://www.unitedwaterresourcesinc.com.au" - }, - { - "first_name": "Edelmira", - "last_name": "Pedregon", - "company_name": "Independence Marine Corp", - "address": "50638 Northwest Blvd", - "state": "WA", - "post": 6450, - "city": "Bandy Creek", - "phone1": "08-8484-3223", - "phone2": "0454-458-365", - "email": "edelmira_pedregon@hotmail.com", - "web": "http://www.independencemarinecorp.com.au" - }, - { - "first_name": "Noelia", - "last_name": "Brackett", - "company_name": "Rodriguez, Joseph A Esq", - "address": "403 Conn Valley Rd", - "state": "WA", - "post": 6450, - "city": "Castletown", - "phone1": "08-3773-3770", - "phone2": "0454-135-614", - "email": "noelia@brackett.net.au", - "web": "http://www.rodriguezjosephaesq.com.au" - }, - { - "first_name": "Richelle", - "last_name": "Remillard", - "company_name": "Terri, Teresa Hutchens Esq", - "address": "2495 Beach Blvd #557", - "state": "WA", - "post": 6452, - "city": "Buraminya", - "phone1": "08-6831-6370", - "phone2": "0416-611-806", - "email": "richelle.remillard@remillard.net.au", - "web": "http://www.territeresahutchensesq.com.au" - }, - { - "first_name": "Brandee", - "last_name": "Svoboda", - "company_name": "Cath Lea For Relig & Cvl Rgts", - "address": "7 10th St W", - "state": "WA", - "post": 6460, - "city": "Walyormouring", - "phone1": "08-3614-5966", - "phone2": "0419-644-936", - "email": "brandee_svoboda@svoboda.net.au", - "web": "http://www.cathleaforreligcvlrgts.com.au" - }, - { - "first_name": "Lisbeth", - "last_name": "Agney", - "company_name": "Dynetics", - "address": "1 El Camino Real #603", - "state": "WA", - "post": 6462, - "city": "Hindmarsh", - "phone1": "08-1184-4145", - "phone2": "0449-675-754", - "email": "lisbeth.agney@agney.net.au", - "web": "http://www.dynetics.com.au" - }, - { - "first_name": "Delfina", - "last_name": "Binnie", - "company_name": "Motel 6", - "address": "8 Austin Bluffs Pky", - "state": "WA", - "post": 6472, - "city": "Bimbijy", - "phone1": "08-3692-5784", - "phone2": "0460-951-322", - "email": "delfina_binnie@binnie.net.au", - "web": "http://www.motel.com.au" - }, - { - "first_name": "Yuriko", - "last_name": "Kazarian", - "company_name": "Doane Products Company", - "address": "3 Davis Blvd", - "state": "WA", - "post": 6472, - "city": "Mouroubra", - "phone1": "08-1109-5346", - "phone2": "0476-877-991", - "email": "yuriko_kazarian@gmail.com", - "web": "http://www.doaneproductscompany.com.au" - }, - { - "first_name": "Kizzy", - "last_name": "Stangle", - "company_name": "Rogers, Clay M Esq", - "address": "8 W Lake St #1", - "state": "WA", - "post": 6477, - "city": "Welbungin", - "phone1": "08-1937-3980", - "phone2": "0474-218-755", - "email": "kizzy.stangle@yahoo.com", - "web": "http://www.rogersclaymesq.com.au" - }, - { - "first_name": "Lamonica", - "last_name": "Princiotta", - "company_name": "Grossman Tuchman & Shah", - "address": "29133 Hammond Dr #1", - "state": "WA", - "post": 6503, - "city": "Beermullah", - "phone1": "08-5227-2620", - "phone2": "0425-628-359", - "email": "lamonica@hotmail.com", - "web": "http://www.grossmantuchmanshah.com.au" - }, - { - "first_name": "Rocco", - "last_name": "Bergstrom", - "company_name": "Postlewaite, Jack A Esq", - "address": "850 Warwick Blvd #58", - "state": "WA", - "post": 6514, - "city": "Leeman", - "phone1": "08-3987-7521", - "phone2": "0457-212-114", - "email": "rocco@yahoo.com", - "web": "http://www.postlewaitejackaesq.com.au" - }, - { - "first_name": "Corazon", - "last_name": "Grafenstein", - "company_name": "Spieker Properties", - "address": "3492 88th St", - "state": "WA", - "post": 6521, - "city": "Hill River", - "phone1": "08-1624-7236", - "phone2": "0481-500-964", - "email": "cgrafenstein@gmail.com", - "web": "http://www.spiekerproperties.com.au" - }, - { - "first_name": "Omer", - "last_name": "Radel", - "company_name": "Phoenix Marketing Rep Inc", - "address": "678 S Main St", - "state": "WA", - "post": 6521, - "city": "Hill River", - "phone1": "08-9919-9540", - "phone2": "0439-808-753", - "email": "omer_radel@radel.net.au", - "web": "http://www.phoenixmarketingrepinc.com.au" - }, - { - "first_name": "Serita", - "last_name": "Barthlow", - "company_name": "Machine Design Service Inc", - "address": "190 34th St #8", - "state": "WA", - "post": 6522, - "city": "Nangetty", - "phone1": "08-2941-7378", - "phone2": "0493-703-129", - "email": "serita_barthlow@gmail.com", - "web": "http://www.machinedesignserviceinc.com.au" - }, - { - "first_name": "Stanford", - "last_name": "Waganer", - "company_name": "Ciba Geigy Corp", - "address": "98021 Harwin Dr", - "state": "WA", - "post": 6532, - "city": "East Nabawa", - "phone1": "08-3200-1670", - "phone2": "0479-127-500", - "email": "stanford_waganer@waganer.net.au", - "web": "http://www.cibageigycorp.com.au" - }, - { - "first_name": "Carri", - "last_name": "Palaspas", - "company_name": "Alexander, David T Esq", - "address": "51255 Tea Town Rd #9", - "state": "WA", - "post": 6532, - "city": "Minnenooka", - "phone1": "08-6069-1579", - "phone2": "0499-165-889", - "email": "carri_palaspas@palaspas.net.au", - "web": "http://www.alexanderdavidtesq.com.au" - }, - { - "first_name": "Bettyann", - "last_name": "Fernades", - "company_name": "Lsr Pokorny Schwartz Friedman", - "address": "54648 Hylan Blvd #883", - "state": "WA", - "post": 6532, - "city": "Tibradden", - "phone1": "08-2901-3421", - "phone2": "0427-971-504", - "email": "bettyann@fernades.com.au", - "web": "http://www.lsrpokornyschwartzfriedman.com.au" - }, - { - "first_name": "Kathryn", - "last_name": "Bonalumi", - "company_name": "State Library", - "address": "86 Worth St #272", - "state": "WA", - "post": 6532, - "city": "Tibradden", - "phone1": "08-3071-2258", - "phone2": "0455-699-311", - "email": "kathryn.bonalumi@yahoo.com", - "web": "http://www.statelibrary.com.au" - }, - { - "first_name": "Desiree", - "last_name": "Englund", - "company_name": "Wrrr Fm", - "address": "9495 Central Hwy #66", - "state": "WA", - "post": 6535, - "city": "East Bowes", - "phone1": "08-5289-4594", - "phone2": "0414-731-630", - "email": "denglund@gmail.com", - "web": "http://www.wrrrfm.com.au" - }, - { - "first_name": "Odelia", - "last_name": "Hutchin", - "company_name": "Mccaffreys Supermarket", - "address": "374 Sunrise Ave", - "state": "WA", - "post": 6556, - "city": "Gorrie", - "phone1": "08-9895-1954", - "phone2": "0472-399-247", - "email": "odelia.hutchin@hutchin.com.au", - "web": "http://www.mccaffreyssupermarket.com.au" - }, - { - "first_name": "Ethan", - "last_name": "Quintero", - "company_name": "Regent Consultants Corp", - "address": "2 Ellis Rd", - "state": "WA", - "post": 6608, - "city": "East Damboring", - "phone1": "08-8280-9492", - "phone2": "0488-425-192", - "email": "ethan_quintero@quintero.com.au", - "web": "http://www.regentconsultantscorp.com.au" - }, - { - "first_name": "Tricia", - "last_name": "Peressini", - "company_name": "Aviation Design", - "address": "3 Industrial Blvd", - "state": "WA", - "post": 6623, - "city": "Pintharuka", - "phone1": "08-4326-1560", - "phone2": "0484-192-990", - "email": "tperessini@yahoo.com", - "web": "http://www.aviationdesign.com.au" - }, - { - "first_name": "Gerry", - "last_name": "Mohrmann", - "company_name": "Howard Winig Realty Assocs Inc", - "address": "8 Glenn Way #3", - "state": "WA", - "post": 6701, - "city": "Brockman", - "phone1": "08-1399-2471", - "phone2": "0490-947-955", - "email": "gerry_mohrmann@mohrmann.net.au", - "web": "http://www.howardwinigrealtyassocsinc.com.au" - }, - { - "first_name": "Jean", - "last_name": "Cecchinato", - "company_name": "Cox, J Thomas Jr", - "address": "7 Hugh Wallis Rd", - "state": "WA", - "post": 6733, - "city": "Koolan Island", - "phone1": "08-5263-2786", - "phone2": "0448-530-536", - "email": "jean.cecchinato@gmail.com", - "web": "http://www.coxjthomasjr.com.au" - }, - { - "first_name": "Laurene", - "last_name": "Bennett", - "company_name": "Elbin Internatl Baskets", - "address": "5 Richmond Ct", - "state": "WA", - "post": 6906, - "city": "North Perth", - "phone1": "08-2969-2908", - "phone2": "0468-234-875", - "email": "laurene_bennett@gmail.com", - "web": "http://www.elbininternatlbaskets.com.au" - }, - { - "first_name": "Emelda", - "last_name": "Geffers", - "company_name": "D L Downing General Contr Inc", - "address": "95431 34th Ave #62", - "state": "WA", - "post": 6909, - "city": "Nedlands", - "phone1": "08-7097-3947", - "phone2": "0454-643-433", - "email": "emelda.geffers@gmail.com", - "web": "http://www.dldowninggeneralcontrinc.com.au" - }, - { - "first_name": "Paulina", - "last_name": "Maker", - "company_name": "Swanson Peterson Fnrl Home Inc", - "address": "6 S Hanover Ave", - "state": "WA", - "post": 6931, - "city": "Maylands", - "phone1": "08-8344-8929", - "phone2": "0420-123-282", - "email": "paulina_maker@maker.net.au", - "web": "http://www.swansonpetersonfnrlhomeinc.com.au" - }, - { - "first_name": "Mertie", - "last_name": "Kazeck", - "company_name": "Electra Gear Divsn Regal", - "address": "35662 S University Blvd", - "state": "WA", - "post": 6935, - "city": "Guildford", - "phone1": "08-5475-6162", - "phone2": "0446-422-535", - "email": "mertie.kazeck@kazeck.com.au", - "web": "http://www.electrageardivsnregal.com.au" - }, - { - "first_name": "Rosendo", - "last_name": "Jelsma", - "company_name": "Dileo, Lucille A Esq", - "address": "94 I 55s S", - "state": "WA", - "post": 6953, - "city": "Applecross", - "phone1": "08-7712-4785", - "phone2": "0477-239-199", - "email": "rosendo_jelsma@hotmail.com", - "web": "http://www.dileolucilleaesq.com.au" - }, - { - "first_name": "Reiko", - "last_name": "Dejarme", - "company_name": "Gilardis Frozen Food", - "address": "57869 Alemany Blvd", - "state": "WA", - "post": 6983, - "city": "Bentley Dc", - "phone1": "08-3733-5261", - "phone2": "0414-715-583", - "email": "rdejarme@dejarme.net.au", - "web": "http://www.gilardisfrozenfood.com.au" - } -] diff --git a/docs/public/favicon.ico b/docs/public/favicon.ico deleted file mode 100644 index 5c125de5d8..0000000000 Binary files a/docs/public/favicon.ico and /dev/null differ diff --git a/docs/public/index.html b/docs/public/index.html deleted file mode 100644 index 8f091cd05a..0000000000 --- a/docs/public/index.html +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - - - React Table - A lightweight, fast and extendable datagrid built for React - - -
- - - diff --git a/docs/reference/@tanstack/namespaces/filterFn_arrIncludes/functions/autoRemove.md b/docs/reference/@tanstack/namespaces/filterFn_arrIncludes/functions/autoRemove.md new file mode 100644 index 0000000000..e2b8ab07c2 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_arrIncludes/functions/autoRemove.md @@ -0,0 +1,22 @@ +--- +id: autoRemove +title: autoRemove +--- + +# Function: autoRemove() + +```ts +function autoRemove(val): boolean; +``` + +Defined in: [fns/filterFns.ts:316](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L316) + +## Parameters + +### val + +`any` + +## Returns + +`boolean` diff --git a/docs/reference/@tanstack/namespaces/filterFn_arrIncludes/index.md b/docs/reference/@tanstack/namespaces/filterFn_arrIncludes/index.md new file mode 100644 index 0000000000..39dbc36047 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_arrIncludes/index.md @@ -0,0 +1,12 @@ +--- +id: filterFn_arrIncludes +title: filterFn_arrIncludes +--- + +# filterFn\_arrIncludes + +Filter function for checking if an array includes a given value. + +## Functions + +- [autoRemove](functions/autoRemove.md) diff --git a/docs/reference/@tanstack/namespaces/filterFn_arrIncludesAll/functions/autoRemove.md b/docs/reference/@tanstack/namespaces/filterFn_arrIncludesAll/functions/autoRemove.md new file mode 100644 index 0000000000..6749ac0134 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_arrIncludesAll/functions/autoRemove.md @@ -0,0 +1,22 @@ +--- +id: autoRemove +title: autoRemove +--- + +# Function: autoRemove() + +```ts +function autoRemove(val): boolean; +``` + +Defined in: [fns/filterFns.ts:334](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L334) + +## Parameters + +### val + +`any` + +## Returns + +`boolean` diff --git a/docs/reference/@tanstack/namespaces/filterFn_arrIncludesAll/index.md b/docs/reference/@tanstack/namespaces/filterFn_arrIncludesAll/index.md new file mode 100644 index 0000000000..ee2ffb6838 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_arrIncludesAll/index.md @@ -0,0 +1,12 @@ +--- +id: filterFn_arrIncludesAll +title: filterFn_arrIncludesAll +--- + +# filterFn\_arrIncludesAll + +Filter function for checking if an array includes all of the given values. + +## Functions + +- [autoRemove](functions/autoRemove.md) diff --git a/docs/reference/@tanstack/namespaces/filterFn_arrIncludesSome/functions/autoRemove.md b/docs/reference/@tanstack/namespaces/filterFn_arrIncludesSome/functions/autoRemove.md new file mode 100644 index 0000000000..5c8129fd1a --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_arrIncludesSome/functions/autoRemove.md @@ -0,0 +1,22 @@ +--- +id: autoRemove +title: autoRemove +--- + +# Function: autoRemove() + +```ts +function autoRemove(val): boolean; +``` + +Defined in: [fns/filterFns.ts:353](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L353) + +## Parameters + +### val + +`any` + +## Returns + +`boolean` diff --git a/docs/reference/@tanstack/namespaces/filterFn_arrIncludesSome/index.md b/docs/reference/@tanstack/namespaces/filterFn_arrIncludesSome/index.md new file mode 100644 index 0000000000..6e7440d236 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_arrIncludesSome/index.md @@ -0,0 +1,12 @@ +--- +id: filterFn_arrIncludesSome +title: filterFn_arrIncludesSome +--- + +# filterFn\_arrIncludesSome + +Filter function for checking if an array includes any of the given values. + +## Functions + +- [autoRemove](functions/autoRemove.md) diff --git a/docs/reference/@tanstack/namespaces/filterFn_equals/functions/autoRemove.md b/docs/reference/@tanstack/namespaces/filterFn_equals/functions/autoRemove.md new file mode 100644 index 0000000000..4215c8844e --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_equals/functions/autoRemove.md @@ -0,0 +1,22 @@ +--- +id: autoRemove +title: autoRemove +--- + +# Function: autoRemove() + +```ts +function autoRemove(val): boolean; +``` + +Defined in: [fns/filterFns.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L22) + +## Parameters + +### val + +`any` + +## Returns + +`boolean` diff --git a/docs/reference/@tanstack/namespaces/filterFn_equals/index.md b/docs/reference/@tanstack/namespaces/filterFn_equals/index.md new file mode 100644 index 0000000000..a84b3749fa --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_equals/index.md @@ -0,0 +1,12 @@ +--- +id: filterFn_equals +title: filterFn_equals +--- + +# filterFn\_equals + +Filter function for checking if a value is exactly equal to a given value. (JS === comparison) + +## Functions + +- [autoRemove](functions/autoRemove.md) diff --git a/docs/reference/@tanstack/namespaces/filterFn_equalsString/functions/autoRemove.md b/docs/reference/@tanstack/namespaces/filterFn_equalsString/functions/autoRemove.md new file mode 100644 index 0000000000..3007b1e7db --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_equalsString/functions/autoRemove.md @@ -0,0 +1,22 @@ +--- +id: autoRemove +title: autoRemove +--- + +# Function: autoRemove() + +```ts +function autoRemove(val): boolean; +``` + +Defined in: [fns/filterFns.ts:99](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L99) + +## Parameters + +### val + +`any` + +## Returns + +`boolean` diff --git a/docs/reference/@tanstack/namespaces/filterFn_equalsString/index.md b/docs/reference/@tanstack/namespaces/filterFn_equalsString/index.md new file mode 100644 index 0000000000..f1b1984393 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_equalsString/index.md @@ -0,0 +1,12 @@ +--- +id: filterFn_equalsString +title: filterFn_equalsString +--- + +# filterFn\_equalsString + +Filter function for checking if a string is exactly equal to a given string. (Non-case-sensitive) + +## Functions + +- [autoRemove](functions/autoRemove.md) diff --git a/docs/reference/@tanstack/namespaces/filterFn_equalsStringSensitive/functions/autoRemove.md b/docs/reference/@tanstack/namespaces/filterFn_equalsStringSensitive/functions/autoRemove.md new file mode 100644 index 0000000000..8700832f1e --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_equalsStringSensitive/functions/autoRemove.md @@ -0,0 +1,22 @@ +--- +id: autoRemove +title: autoRemove +--- + +# Function: autoRemove() + +```ts +function autoRemove(val): boolean; +``` + +Defined in: [fns/filterFns.ts:115](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L115) + +## Parameters + +### val + +`any` + +## Returns + +`boolean` diff --git a/docs/reference/@tanstack/namespaces/filterFn_equalsStringSensitive/index.md b/docs/reference/@tanstack/namespaces/filterFn_equalsStringSensitive/index.md new file mode 100644 index 0000000000..bf99c06b65 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_equalsStringSensitive/index.md @@ -0,0 +1,12 @@ +--- +id: filterFn_equalsStringSensitive +title: filterFn_equalsStringSensitive +--- + +# filterFn\_equalsStringSensitive + +Filter function for checking if a string is exactly equal to a given string. (Case-sensitive) + +## Functions + +- [autoRemove](functions/autoRemove.md) diff --git a/docs/reference/@tanstack/namespaces/filterFn_greaterThan/functions/resolveFilterValue.md b/docs/reference/@tanstack/namespaces/filterFn_greaterThan/functions/resolveFilterValue.md new file mode 100644 index 0000000000..e54f30b5cc --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_greaterThan/functions/resolveFilterValue.md @@ -0,0 +1,22 @@ +--- +id: resolveFilterValue +title: resolveFilterValue +--- + +# Function: resolveFilterValue() + +```ts +function resolveFilterValue(val): boolean; +``` + +Defined in: [fns/filterFns.ts:144](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L144) + +## Parameters + +### val + +`any` + +## Returns + +`boolean` diff --git a/docs/reference/@tanstack/namespaces/filterFn_greaterThan/index.md b/docs/reference/@tanstack/namespaces/filterFn_greaterThan/index.md new file mode 100644 index 0000000000..12ec8a7afa --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_greaterThan/index.md @@ -0,0 +1,12 @@ +--- +id: filterFn_greaterThan +title: filterFn_greaterThan +--- + +# filterFn\_greaterThan + +Filter function for checking if a number is greater than a given number. + +## Functions + +- [resolveFilterValue](functions/resolveFilterValue.md) diff --git a/docs/reference/@tanstack/namespaces/filterFn_greaterThanOrEqualTo/functions/resolveFilterValue.md b/docs/reference/@tanstack/namespaces/filterFn_greaterThanOrEqualTo/functions/resolveFilterValue.md new file mode 100644 index 0000000000..26c4350672 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_greaterThanOrEqualTo/functions/resolveFilterValue.md @@ -0,0 +1,22 @@ +--- +id: resolveFilterValue +title: resolveFilterValue +--- + +# Function: resolveFilterValue() + +```ts +function resolveFilterValue(val): boolean; +``` + +Defined in: [fns/filterFns.ts:163](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L163) + +## Parameters + +### val + +`any` + +## Returns + +`boolean` diff --git a/docs/reference/@tanstack/namespaces/filterFn_greaterThanOrEqualTo/index.md b/docs/reference/@tanstack/namespaces/filterFn_greaterThanOrEqualTo/index.md new file mode 100644 index 0000000000..333b43fbda --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_greaterThanOrEqualTo/index.md @@ -0,0 +1,12 @@ +--- +id: filterFn_greaterThanOrEqualTo +title: filterFn_greaterThanOrEqualTo +--- + +# filterFn\_greaterThanOrEqualTo + +Filter function for checking if a number is greater than or equal to a given number. + +## Functions + +- [resolveFilterValue](functions/resolveFilterValue.md) diff --git a/docs/reference/@tanstack/namespaces/filterFn_inNumberRange/functions/autoRemove.md b/docs/reference/@tanstack/namespaces/filterFn_inNumberRange/functions/autoRemove.md new file mode 100644 index 0000000000..326e90605f --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_inNumberRange/functions/autoRemove.md @@ -0,0 +1,22 @@ +--- +id: autoRemove +title: autoRemove +--- + +# Function: autoRemove() + +```ts +function autoRemove(val): boolean; +``` + +Defined in: [fns/filterFns.ts:279](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L279) + +## Parameters + +### val + +`any` + +## Returns + +`boolean` diff --git a/docs/reference/@tanstack/namespaces/filterFn_inNumberRange/functions/resolveFilterValue.md b/docs/reference/@tanstack/namespaces/filterFn_inNumberRange/functions/resolveFilterValue.md new file mode 100644 index 0000000000..24e9ffb513 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_inNumberRange/functions/resolveFilterValue.md @@ -0,0 +1,22 @@ +--- +id: resolveFilterValue +title: resolveFilterValue +--- + +# Function: resolveFilterValue() + +```ts +function resolveFilterValue(val): readonly [number, number]; +``` + +Defined in: [fns/filterFns.ts:258](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L258) + +## Parameters + +### val + +\[`any`, `any`\] + +## Returns + +readonly \[`number`, `number`\] diff --git a/docs/reference/@tanstack/namespaces/filterFn_inNumberRange/index.md b/docs/reference/@tanstack/namespaces/filterFn_inNumberRange/index.md new file mode 100644 index 0000000000..0336d66395 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_inNumberRange/index.md @@ -0,0 +1,13 @@ +--- +id: filterFn_inNumberRange +title: filterFn_inNumberRange +--- + +# filterFn\_inNumberRange + +Filter function for checking if a number is within a given range. + +## Functions + +- [autoRemove](functions/autoRemove.md) +- [resolveFilterValue](functions/resolveFilterValue.md) diff --git a/docs/reference/@tanstack/namespaces/filterFn_includesString/functions/autoRemove.md b/docs/reference/@tanstack/namespaces/filterFn_includesString/functions/autoRemove.md new file mode 100644 index 0000000000..40bcbd6dd1 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_includesString/functions/autoRemove.md @@ -0,0 +1,22 @@ +--- +id: autoRemove +title: autoRemove +--- + +# Function: autoRemove() + +```ts +function autoRemove(val): boolean; +``` + +Defined in: [fns/filterFns.ts:80](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L80) + +## Parameters + +### val + +`any` + +## Returns + +`boolean` diff --git a/docs/reference/@tanstack/namespaces/filterFn_includesString/index.md b/docs/reference/@tanstack/namespaces/filterFn_includesString/index.md new file mode 100644 index 0000000000..04612a30bb --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_includesString/index.md @@ -0,0 +1,12 @@ +--- +id: filterFn_includesString +title: filterFn_includesString +--- + +# filterFn\_includesString + +Filter function for checking if a string includes a given substring. (Non-case-sensitive) + +## Functions + +- [autoRemove](functions/autoRemove.md) diff --git a/docs/reference/@tanstack/namespaces/filterFn_includesStringSensitive/functions/autoRemove.md b/docs/reference/@tanstack/namespaces/filterFn_includesStringSensitive/functions/autoRemove.md new file mode 100644 index 0000000000..2a3cce59e9 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_includesStringSensitive/functions/autoRemove.md @@ -0,0 +1,22 @@ +--- +id: autoRemove +title: autoRemove +--- + +# Function: autoRemove() + +```ts +function autoRemove(val): boolean; +``` + +Defined in: [fns/filterFns.ts:58](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L58) + +## Parameters + +### val + +`any` + +## Returns + +`boolean` diff --git a/docs/reference/@tanstack/namespaces/filterFn_includesStringSensitive/index.md b/docs/reference/@tanstack/namespaces/filterFn_includesStringSensitive/index.md new file mode 100644 index 0000000000..93c0e855a3 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_includesStringSensitive/index.md @@ -0,0 +1,12 @@ +--- +id: filterFn_includesStringSensitive +title: filterFn_includesStringSensitive +--- + +# filterFn\_includesStringSensitive + +Filter function for checking if a string includes a given substring. (Case-sensitive) + +## Functions + +- [autoRemove](functions/autoRemove.md) diff --git a/docs/reference/@tanstack/namespaces/filterFn_lessThan/functions/resolveFilterValue.md b/docs/reference/@tanstack/namespaces/filterFn_lessThan/functions/resolveFilterValue.md new file mode 100644 index 0000000000..d06754949d --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_lessThan/functions/resolveFilterValue.md @@ -0,0 +1,22 @@ +--- +id: resolveFilterValue +title: resolveFilterValue +--- + +# Function: resolveFilterValue() + +```ts +function resolveFilterValue(val): boolean; +``` + +Defined in: [fns/filterFns.ts:179](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L179) + +## Parameters + +### val + +`any` + +## Returns + +`boolean` diff --git a/docs/reference/@tanstack/namespaces/filterFn_lessThan/index.md b/docs/reference/@tanstack/namespaces/filterFn_lessThan/index.md new file mode 100644 index 0000000000..764110d19a --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_lessThan/index.md @@ -0,0 +1,12 @@ +--- +id: filterFn_lessThan +title: filterFn_lessThan +--- + +# filterFn\_lessThan + +Filter function for checking if a number is less than a given number. + +## Functions + +- [resolveFilterValue](functions/resolveFilterValue.md) diff --git a/docs/reference/@tanstack/namespaces/filterFn_lessThanOrEqualTo/functions/resolveFilterValue.md b/docs/reference/@tanstack/namespaces/filterFn_lessThanOrEqualTo/functions/resolveFilterValue.md new file mode 100644 index 0000000000..c603b9a79a --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_lessThanOrEqualTo/functions/resolveFilterValue.md @@ -0,0 +1,22 @@ +--- +id: resolveFilterValue +title: resolveFilterValue +--- + +# Function: resolveFilterValue() + +```ts +function resolveFilterValue(val): boolean; +``` + +Defined in: [fns/filterFns.ts:195](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L195) + +## Parameters + +### val + +`any` + +## Returns + +`boolean` diff --git a/docs/reference/@tanstack/namespaces/filterFn_lessThanOrEqualTo/index.md b/docs/reference/@tanstack/namespaces/filterFn_lessThanOrEqualTo/index.md new file mode 100644 index 0000000000..ffa6e3e500 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_lessThanOrEqualTo/index.md @@ -0,0 +1,12 @@ +--- +id: filterFn_lessThanOrEqualTo +title: filterFn_lessThanOrEqualTo +--- + +# filterFn\_lessThanOrEqualTo + +Filter function for checking if a number is less than or equal to a given number. + +## Functions + +- [resolveFilterValue](functions/resolveFilterValue.md) diff --git a/docs/reference/@tanstack/namespaces/filterFn_weakEquals/functions/autoRemove.md b/docs/reference/@tanstack/namespaces/filterFn_weakEquals/functions/autoRemove.md new file mode 100644 index 0000000000..dfd81b6bc8 --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_weakEquals/functions/autoRemove.md @@ -0,0 +1,22 @@ +--- +id: autoRemove +title: autoRemove +--- + +# Function: autoRemove() + +```ts +function autoRemove(val): boolean; +``` + +Defined in: [fns/filterFns.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L38) + +## Parameters + +### val + +`any` + +## Returns + +`boolean` diff --git a/docs/reference/@tanstack/namespaces/filterFn_weakEquals/index.md b/docs/reference/@tanstack/namespaces/filterFn_weakEquals/index.md new file mode 100644 index 0000000000..658aea77bf --- /dev/null +++ b/docs/reference/@tanstack/namespaces/filterFn_weakEquals/index.md @@ -0,0 +1,12 @@ +--- +id: filterFn_weakEquals +title: filterFn_weakEquals +--- + +# filterFn\_weakEquals + +Filter function for checking if a value is weakly equal to a given value. (JS == comparison) + +## Functions + +- [autoRemove](functions/autoRemove.md) diff --git a/docs/reference/functions/assignPrototypeAPIs.md b/docs/reference/functions/assignPrototypeAPIs.md new file mode 100644 index 0000000000..2676b92797 --- /dev/null +++ b/docs/reference/functions/assignPrototypeAPIs.md @@ -0,0 +1,62 @@ +--- +id: assignPrototypeAPIs +title: assignPrototypeAPIs +--- + +# Function: assignPrototypeAPIs() + +```ts +function assignPrototypeAPIs( + feature, + prototype, + table, + apis): void; +``` + +Defined in: [utils.ts:339](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L339) + +Assigns API methods to a prototype object for memory-efficient method sharing. +All instances created with this prototype will share the same method references. + +For memoized methods, the memo state is lazily created and stored on each instance. +This provides the best of both worlds: shared method code + per-instance caching. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TDeps + +`TDeps` *extends* readonly `any`[] + +### TDepArgs + +`TDepArgs` + +## Parameters + +### feature + +keyof `TFeatures` & `string` + +### prototype + +`Record`\<`string`, `any`\> + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### apis + +[`PrototypeAPIObject`](../type-aliases/PrototypeAPIObject.md)\<`TDeps`, [`NoInfer`](../type-aliases/NoInfer.md)\<`TDepArgs`\>\> + +## Returns + +`void` diff --git a/docs/reference/functions/assignTableAPIs.md b/docs/reference/functions/assignTableAPIs.md new file mode 100644 index 0000000000..cca846b169 --- /dev/null +++ b/docs/reference/functions/assignTableAPIs.md @@ -0,0 +1,54 @@ +--- +id: assignTableAPIs +title: assignTableAPIs +--- + +# Function: assignTableAPIs() + +```ts +function assignTableAPIs( + feature, + table, + apis): void; +``` + +Defined in: [utils.ts:297](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L297) + +Assigns Table API methods directly to the table instance. +Unlike row/cell/column/header, the table is a singleton so methods are assigned directly. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TDeps + +`TDeps` *extends* readonly `any`[] + +### TDepArgs + +`TDepArgs` + +## Parameters + +### feature + +keyof `TFeatures` & `string` + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### apis + +[`APIObject`](../type-aliases/APIObject.md)\<`TDeps`, [`NoInfer`](../type-aliases/NoInfer.md)\<`TDepArgs`\>\> + +## Returns + +`void` diff --git a/docs/reference/functions/buildHeaderGroups.md b/docs/reference/functions/buildHeaderGroups.md new file mode 100644 index 0000000000..fd8e1f000f --- /dev/null +++ b/docs/reference/functions/buildHeaderGroups.md @@ -0,0 +1,52 @@ +--- +id: buildHeaderGroups +title: buildHeaderGroups +--- + +# Function: buildHeaderGroups() + +```ts +function buildHeaderGroups( + allColumns, + columnsToGroup, + table, + headerFamily?): HeaderGroup[]; +``` + +Defined in: [core/headers/buildHeaderGroups.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/buildHeaderGroups.ts#L11) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### allColumns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\>[] + +### columnsToGroup + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\>[] + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### headerFamily? + +`"left"` | `"right"` | `"center"` + +## Returns + +[`HeaderGroup`](../type-aliases/HeaderGroup.md)\<`TFeatures`, `TData`\>[] diff --git a/docs/reference/functions/callMemoOrStaticFn.md b/docs/reference/functions/callMemoOrStaticFn.md new file mode 100644 index 0000000000..88a7716149 --- /dev/null +++ b/docs/reference/functions/callMemoOrStaticFn.md @@ -0,0 +1,50 @@ +--- +id: callMemoOrStaticFn +title: callMemoOrStaticFn +--- + +# Function: callMemoOrStaticFn() + +```ts +function callMemoOrStaticFn( + obj, + fnKey, + staticFn, ... +args): ReturnType; +``` + +Defined in: [utils.ts:387](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L387) + +Looks to run the memoized function with the builder pattern on the object if it exists, otherwise fallback to the static method passed in. + +## Type Parameters + +### TObject + +`TObject` *extends* `Record`\<`string`, `any`\> + +### TStaticFn + +`TStaticFn` *extends* `AnyFunction` + +## Parameters + +### obj + +`TObject` + +### fnKey + +`string` + +### staticFn + +`TStaticFn` + +### args + +...`Parameters`\<`TStaticFn`\> *extends* \[`any`, `...Rest[]`\] ? `Rest` : `never` + +## Returns + +`ReturnType`\<`TStaticFn`\> diff --git a/docs/reference/functions/cell_getContext.md b/docs/reference/functions/cell_getContext.md new file mode 100644 index 0000000000..9a3c3f1594 --- /dev/null +++ b/docs/reference/functions/cell_getContext.md @@ -0,0 +1,80 @@ +--- +id: cell_getContext +title: cell_getContext +--- + +# Function: cell\_getContext() + +```ts +function cell_getContext(cell): object; +``` + +Defined in: [core/cells/coreCellsFeature.utils.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.utils.ts#L21) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### cell + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`object` + +### cell + +```ts +cell: Cell; +``` + +### column + +```ts +column: Column = cell.column; +``` + +### getValue() + +```ts +getValue: () => NoInfer; +``` + +#### Returns + +[`NoInfer`](../type-aliases/NoInfer.md)\<`TValue`\> + +### renderValue() + +```ts +renderValue: () => NoInfer; +``` + +#### Returns + +[`NoInfer`](../type-aliases/NoInfer.md)\<`TValue` \| `null`\> + +### row + +```ts +row: Row = cell.row; +``` + +### table + +```ts +table: Table_Internal = cell.table; +``` diff --git a/docs/reference/functions/cell_getIsAggregated.md b/docs/reference/functions/cell_getIsAggregated.md new file mode 100644 index 0000000000..b1c0cb9dfa --- /dev/null +++ b/docs/reference/functions/cell_getIsAggregated.md @@ -0,0 +1,36 @@ +--- +id: cell_getIsAggregated +title: cell_getIsAggregated +--- + +# Function: cell\_getIsAggregated() + +```ts +function cell_getIsAggregated(cell): boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:182](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L182) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### cell + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/cell_getIsGrouped.md b/docs/reference/functions/cell_getIsGrouped.md new file mode 100644 index 0000000000..206ec1acbd --- /dev/null +++ b/docs/reference/functions/cell_getIsGrouped.md @@ -0,0 +1,36 @@ +--- +id: cell_getIsGrouped +title: cell_getIsGrouped +--- + +# Function: cell\_getIsGrouped() + +```ts +function cell_getIsGrouped(cell): boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:163](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L163) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### cell + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/cell_getIsPlaceholder.md b/docs/reference/functions/cell_getIsPlaceholder.md new file mode 100644 index 0000000000..6932090db9 --- /dev/null +++ b/docs/reference/functions/cell_getIsPlaceholder.md @@ -0,0 +1,36 @@ +--- +id: cell_getIsPlaceholder +title: cell_getIsPlaceholder +--- + +# Function: cell\_getIsPlaceholder() + +```ts +function cell_getIsPlaceholder(cell): boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:174](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L174) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### cell + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/cell_getValue.md b/docs/reference/functions/cell_getValue.md new file mode 100644 index 0000000000..21951dad30 --- /dev/null +++ b/docs/reference/functions/cell_getValue.md @@ -0,0 +1,36 @@ +--- +id: cell_getValue +title: cell_getValue +--- + +# Function: cell\_getValue() + +```ts +function cell_getValue(cell): TValue; +``` + +Defined in: [core/cells/coreCellsFeature.utils.ts:5](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.utils.ts#L5) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### cell + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`TValue` diff --git a/docs/reference/functions/cell_renderValue.md b/docs/reference/functions/cell_renderValue.md new file mode 100644 index 0000000000..00771496dd --- /dev/null +++ b/docs/reference/functions/cell_renderValue.md @@ -0,0 +1,36 @@ +--- +id: cell_renderValue +title: cell_renderValue +--- + +# Function: cell\_renderValue() + +```ts +function cell_renderValue(cell): any; +``` + +Defined in: [core/cells/coreCellsFeature.utils.ts:13](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.utils.ts#L13) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### cell + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`any` diff --git a/docs/reference/functions/column_clearSorting.md b/docs/reference/functions/column_clearSorting.md new file mode 100644 index 0000000000..c9e1147818 --- /dev/null +++ b/docs/reference/functions/column_clearSorting.md @@ -0,0 +1,36 @@ +--- +id: column_clearSorting +title: column_clearSorting +--- + +# Function: column\_clearSorting() + +```ts +function column_clearSorting(column): void; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:290](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L290) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`void` diff --git a/docs/reference/functions/column_getAfter.md b/docs/reference/functions/column_getAfter.md new file mode 100644 index 0000000000..7113e1b6ef --- /dev/null +++ b/docs/reference/functions/column_getAfter.md @@ -0,0 +1,40 @@ +--- +id: column_getAfter +title: column_getAfter +--- + +# Function: column\_getAfter() + +```ts +function column_getAfter(column, position): number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.utils.ts:66](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.utils.ts#L66) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +### position + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) | `"center"` + +## Returns + +`number` diff --git a/docs/reference/functions/column_getAggregationFn.md b/docs/reference/functions/column_getAggregationFn.md new file mode 100644 index 0000000000..fe15ad30f0 --- /dev/null +++ b/docs/reference/functions/column_getAggregationFn.md @@ -0,0 +1,39 @@ +--- +id: column_getAggregationFn +title: column_getAggregationFn +--- + +# Function: column\_getAggregationFn() + +```ts +function column_getAggregationFn(column): + | AggregationFn + | undefined; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:97](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L97) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + + \| [`AggregationFn`](../type-aliases/AggregationFn.md)\<`TFeatures`, `TData`\> + \| `undefined` diff --git a/docs/reference/functions/column_getAutoAggregationFn.md b/docs/reference/functions/column_getAutoAggregationFn.md new file mode 100644 index 0000000000..2e87a647f3 --- /dev/null +++ b/docs/reference/functions/column_getAutoAggregationFn.md @@ -0,0 +1,39 @@ +--- +id: column_getAutoAggregationFn +title: column_getAutoAggregationFn +--- + +# Function: column\_getAutoAggregationFn() + +```ts +function column_getAutoAggregationFn(column): + | AggregationFn + | undefined; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:75](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L75) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + + \| [`AggregationFn`](../type-aliases/AggregationFn.md)\<`TFeatures`, `TData`\> + \| `undefined` diff --git a/docs/reference/functions/column_getAutoFilterFn.md b/docs/reference/functions/column_getAutoFilterFn.md new file mode 100644 index 0000000000..d0e91aca07 --- /dev/null +++ b/docs/reference/functions/column_getAutoFilterFn.md @@ -0,0 +1,39 @@ +--- +id: column_getAutoFilterFn +title: column_getAutoFilterFn +--- + +# Function: column\_getAutoFilterFn() + +```ts +function column_getAutoFilterFn(column): + | FilterFn + | undefined; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.utils.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.utils.ts#L15) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + + \| [`FilterFn`](../interfaces/FilterFn.md)\<`TFeatures`, `TData`\> + \| `undefined` diff --git a/docs/reference/functions/column_getAutoSortDir.md b/docs/reference/functions/column_getAutoSortDir.md new file mode 100644 index 0000000000..aa1a74d370 --- /dev/null +++ b/docs/reference/functions/column_getAutoSortDir.md @@ -0,0 +1,36 @@ +--- +id: column_getAutoSortDir +title: column_getAutoSortDir +--- + +# Function: column\_getAutoSortDir() + +```ts +function column_getAutoSortDir(column): "asc" | "desc"; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:76](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L76) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`"asc"` \| `"desc"` diff --git a/docs/reference/functions/column_getAutoSortFn.md b/docs/reference/functions/column_getAutoSortFn.md new file mode 100644 index 0000000000..526f4bf412 --- /dev/null +++ b/docs/reference/functions/column_getAutoSortFn.md @@ -0,0 +1,36 @@ +--- +id: column_getAutoSortFn +title: column_getAutoSortFn +--- + +# Function: column\_getAutoSortFn() + +```ts +function column_getAutoSortFn(column): SortFn; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L38) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +[`SortFn`](../interfaces/SortFn.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/column_getCanFilter.md b/docs/reference/functions/column_getCanFilter.md new file mode 100644 index 0000000000..60fd8ee0cb --- /dev/null +++ b/docs/reference/functions/column_getCanFilter.md @@ -0,0 +1,36 @@ +--- +id: column_getCanFilter +title: column_getCanFilter +--- + +# Function: column\_getCanFilter() + +```ts +function column_getCanFilter(column): boolean; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.utils.ts:77](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.utils.ts#L77) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/column_getCanGlobalFilter.md b/docs/reference/functions/column_getCanGlobalFilter.md new file mode 100644 index 0000000000..2b7becd5c5 --- /dev/null +++ b/docs/reference/functions/column_getCanGlobalFilter.md @@ -0,0 +1,36 @@ +--- +id: column_getCanGlobalFilter +title: column_getCanGlobalFilter +--- + +# Function: column\_getCanGlobalFilter() + +```ts +function column_getCanGlobalFilter(column): boolean; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.utils.ts:9](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.utils.ts#L9) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/column_getCanGroup.md b/docs/reference/functions/column_getCanGroup.md new file mode 100644 index 0000000000..4e9522305f --- /dev/null +++ b/docs/reference/functions/column_getCanGroup.md @@ -0,0 +1,36 @@ +--- +id: column_getCanGroup +title: column_getCanGroup +--- + +# Function: column\_getCanGroup() + +```ts +function column_getCanGroup(column): boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L34) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/column_getCanHide.md b/docs/reference/functions/column_getCanHide.md new file mode 100644 index 0000000000..8225ced472 --- /dev/null +++ b/docs/reference/functions/column_getCanHide.md @@ -0,0 +1,36 @@ +--- +id: column_getCanHide +title: column_getCanHide +--- + +# Function: column\_getCanHide() + +```ts +function column_getCanHide(column): boolean; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:44](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L44) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/column_getCanMultiSort.md b/docs/reference/functions/column_getCanMultiSort.md new file mode 100644 index 0000000000..0aa5fb4b53 --- /dev/null +++ b/docs/reference/functions/column_getCanMultiSort.md @@ -0,0 +1,36 @@ +--- +id: column_getCanMultiSort +title: column_getCanMultiSort +--- + +# Function: column\_getCanMultiSort() + +```ts +function column_getCanMultiSort(column): boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:257](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L257) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/column_getCanPin.md b/docs/reference/functions/column_getCanPin.md new file mode 100644 index 0000000000..119086322e --- /dev/null +++ b/docs/reference/functions/column_getCanPin.md @@ -0,0 +1,36 @@ +--- +id: column_getCanPin +title: column_getCanPin +--- + +# Function: column\_getCanPin() + +```ts +function column_getCanPin(column): boolean; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:69](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L69) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/column_getCanResize.md b/docs/reference/functions/column_getCanResize.md new file mode 100644 index 0000000000..0f4216e4b4 --- /dev/null +++ b/docs/reference/functions/column_getCanResize.md @@ -0,0 +1,36 @@ +--- +id: column_getCanResize +title: column_getCanResize +--- + +# Function: column\_getCanResize() + +```ts +function column_getCanResize(column): boolean; +``` + +Defined in: [features/column-resizing/columnResizingFeature.utils.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.utils.ts#L26) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/column_getCanSort.md b/docs/reference/functions/column_getCanSort.md new file mode 100644 index 0000000000..3757e5b19e --- /dev/null +++ b/docs/reference/functions/column_getCanSort.md @@ -0,0 +1,36 @@ +--- +id: column_getCanSort +title: column_getCanSort +--- + +# Function: column\_getCanSort() + +```ts +function column_getCanSort(column): boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:245](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L245) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/column_getFacetedMinMaxValues.md b/docs/reference/functions/column_getFacetedMinMaxValues.md new file mode 100644 index 0000000000..b48e87a990 --- /dev/null +++ b/docs/reference/functions/column_getFacetedMinMaxValues.md @@ -0,0 +1,40 @@ +--- +id: column_getFacetedMinMaxValues +title: column_getFacetedMinMaxValues +--- + +# Function: column\_getFacetedMinMaxValues() + +```ts +function column_getFacetedMinMaxValues(column, table): [number, number] | undefined; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.utils.ts:7](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.utils.ts#L7) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +\[`number`, `number`\] \| `undefined` diff --git a/docs/reference/functions/column_getFacetedRowModel.md b/docs/reference/functions/column_getFacetedRowModel.md new file mode 100644 index 0000000000..850244c3a6 --- /dev/null +++ b/docs/reference/functions/column_getFacetedRowModel.md @@ -0,0 +1,40 @@ +--- +id: column_getFacetedRowModel +title: column_getFacetedRowModel +--- + +# Function: column\_getFacetedRowModel() + +```ts +function column_getFacetedRowModel(column, table): RowModel; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.utils.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.utils.ts#L21) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> | `undefined` + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/column_getFacetedUniqueValues.md b/docs/reference/functions/column_getFacetedUniqueValues.md new file mode 100644 index 0000000000..60a3e97389 --- /dev/null +++ b/docs/reference/functions/column_getFacetedUniqueValues.md @@ -0,0 +1,40 @@ +--- +id: column_getFacetedUniqueValues +title: column_getFacetedUniqueValues +--- + +# Function: column\_getFacetedUniqueValues() + +```ts +function column_getFacetedUniqueValues(column, table): Map; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.utils.ts:35](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.utils.ts#L35) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`Map`\<`any`, `number`\> diff --git a/docs/reference/functions/column_getFilterFn.md b/docs/reference/functions/column_getFilterFn.md new file mode 100644 index 0000000000..f44c1bedfc --- /dev/null +++ b/docs/reference/functions/column_getFilterFn.md @@ -0,0 +1,39 @@ +--- +id: column_getFilterFn +title: column_getFilterFn +--- + +# Function: column\_getFilterFn() + +```ts +function column_getFilterFn(column): + | FilterFn + | undefined; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.utils.ts:51](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.utils.ts#L51) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + + \| [`FilterFn`](../interfaces/FilterFn.md)\<`TFeatures`, `TData`\> + \| `undefined` diff --git a/docs/reference/functions/column_getFilterIndex.md b/docs/reference/functions/column_getFilterIndex.md new file mode 100644 index 0000000000..838a6a1630 --- /dev/null +++ b/docs/reference/functions/column_getFilterIndex.md @@ -0,0 +1,36 @@ +--- +id: column_getFilterIndex +title: column_getFilterIndex +--- + +# Function: column\_getFilterIndex() + +```ts +function column_getFilterIndex(column): number; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.utils.ts:107](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.utils.ts#L107) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`number` diff --git a/docs/reference/functions/column_getFilterValue.md b/docs/reference/functions/column_getFilterValue.md new file mode 100644 index 0000000000..a9725f7900 --- /dev/null +++ b/docs/reference/functions/column_getFilterValue.md @@ -0,0 +1,36 @@ +--- +id: column_getFilterValue +title: column_getFilterValue +--- + +# Function: column\_getFilterValue() + +```ts +function column_getFilterValue(column): unknown; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.utils.ts:98](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.utils.ts#L98) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`unknown` diff --git a/docs/reference/functions/column_getFirstSortDir.md b/docs/reference/functions/column_getFirstSortDir.md new file mode 100644 index 0000000000..f99169329b --- /dev/null +++ b/docs/reference/functions/column_getFirstSortDir.md @@ -0,0 +1,36 @@ +--- +id: column_getFirstSortDir +title: column_getFirstSortDir +--- + +# Function: column\_getFirstSortDir() + +```ts +function column_getFirstSortDir(column): "asc" | "desc"; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:211](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L211) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`"asc"` \| `"desc"` diff --git a/docs/reference/functions/column_getFlatColumns.md b/docs/reference/functions/column_getFlatColumns.md new file mode 100644 index 0000000000..36bf4e8720 --- /dev/null +++ b/docs/reference/functions/column_getFlatColumns.md @@ -0,0 +1,36 @@ +--- +id: column_getFlatColumns +title: column_getFlatColumns +--- + +# Function: column\_getFlatColumns() + +```ts +function column_getFlatColumns(column): Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.utils.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.utils.ts#L14) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\>[] diff --git a/docs/reference/functions/column_getGroupedIndex.md b/docs/reference/functions/column_getGroupedIndex.md new file mode 100644 index 0000000000..8e4305ce24 --- /dev/null +++ b/docs/reference/functions/column_getGroupedIndex.md @@ -0,0 +1,36 @@ +--- +id: column_getGroupedIndex +title: column_getGroupedIndex +--- + +# Function: column\_getGroupedIndex() + +```ts +function column_getGroupedIndex(column): number; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:54](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L54) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`number` diff --git a/docs/reference/functions/column_getIndex.md b/docs/reference/functions/column_getIndex.md new file mode 100644 index 0000000000..7d62bfcf53 --- /dev/null +++ b/docs/reference/functions/column_getIndex.md @@ -0,0 +1,40 @@ +--- +id: column_getIndex +title: column_getIndex +--- + +# Function: column\_getIndex() + +```ts +function column_getIndex(column, position?): number; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.utils.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.utils.ts#L14) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +### position? + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) | `"center"` + +## Returns + +`number` diff --git a/docs/reference/functions/column_getIsFiltered.md b/docs/reference/functions/column_getIsFiltered.md new file mode 100644 index 0000000000..b683e226e0 --- /dev/null +++ b/docs/reference/functions/column_getIsFiltered.md @@ -0,0 +1,36 @@ +--- +id: column_getIsFiltered +title: column_getIsFiltered +--- + +# Function: column\_getIsFiltered() + +```ts +function column_getIsFiltered(column): boolean; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.utils.ts:90](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.utils.ts#L90) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/column_getIsFirstColumn.md b/docs/reference/functions/column_getIsFirstColumn.md new file mode 100644 index 0000000000..e3930acb51 --- /dev/null +++ b/docs/reference/functions/column_getIsFirstColumn.md @@ -0,0 +1,40 @@ +--- +id: column_getIsFirstColumn +title: column_getIsFirstColumn +--- + +# Function: column\_getIsFirstColumn() + +```ts +function column_getIsFirstColumn(column, position?): boolean; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.utils.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.utils.ts#L26) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +### position? + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) | `"center"` + +## Returns + +`boolean` diff --git a/docs/reference/functions/column_getIsGrouped.md b/docs/reference/functions/column_getIsGrouped.md new file mode 100644 index 0000000000..4a504e4840 --- /dev/null +++ b/docs/reference/functions/column_getIsGrouped.md @@ -0,0 +1,36 @@ +--- +id: column_getIsGrouped +title: column_getIsGrouped +--- + +# Function: column\_getIsGrouped() + +```ts +function column_getIsGrouped(column): boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:46](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L46) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/column_getIsLastColumn.md b/docs/reference/functions/column_getIsLastColumn.md new file mode 100644 index 0000000000..94c37f255f --- /dev/null +++ b/docs/reference/functions/column_getIsLastColumn.md @@ -0,0 +1,40 @@ +--- +id: column_getIsLastColumn +title: column_getIsLastColumn +--- + +# Function: column\_getIsLastColumn() + +```ts +function column_getIsLastColumn(column, position?): boolean; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.utils.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.utils.ts#L38) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +### position? + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) | `"center"` + +## Returns + +`boolean` diff --git a/docs/reference/functions/column_getIsPinned.md b/docs/reference/functions/column_getIsPinned.md new file mode 100644 index 0000000000..f53c19455c --- /dev/null +++ b/docs/reference/functions/column_getIsPinned.md @@ -0,0 +1,36 @@ +--- +id: column_getIsPinned +title: column_getIsPinned +--- + +# Function: column\_getIsPinned() + +```ts +function column_getIsPinned(column): ColumnPinningPosition; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:85](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L85) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) diff --git a/docs/reference/functions/column_getIsResizing.md b/docs/reference/functions/column_getIsResizing.md new file mode 100644 index 0000000000..b4492cd782 --- /dev/null +++ b/docs/reference/functions/column_getIsResizing.md @@ -0,0 +1,36 @@ +--- +id: column_getIsResizing +title: column_getIsResizing +--- + +# Function: column\_getIsResizing() + +```ts +function column_getIsResizing(column): boolean; +``` + +Defined in: [features/column-resizing/columnResizingFeature.utils.ts:37](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.utils.ts#L37) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/column_getIsSorted.md b/docs/reference/functions/column_getIsSorted.md new file mode 100644 index 0000000000..db76a9a73c --- /dev/null +++ b/docs/reference/functions/column_getIsSorted.md @@ -0,0 +1,36 @@ +--- +id: column_getIsSorted +title: column_getIsSorted +--- + +# Function: column\_getIsSorted() + +```ts +function column_getIsSorted(column): false | SortDirection; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:269](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L269) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`false` \| [`SortDirection`](../type-aliases/SortDirection.md) diff --git a/docs/reference/functions/column_getIsVisible.md b/docs/reference/functions/column_getIsVisible.md new file mode 100644 index 0000000000..499c9b2b1c --- /dev/null +++ b/docs/reference/functions/column_getIsVisible.md @@ -0,0 +1,36 @@ +--- +id: column_getIsVisible +title: column_getIsVisible +--- + +# Function: column\_getIsVisible() + +```ts +function column_getIsVisible(column): boolean; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L29) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/column_getLeafColumns.md b/docs/reference/functions/column_getLeafColumns.md new file mode 100644 index 0000000000..6e4c0d4785 --- /dev/null +++ b/docs/reference/functions/column_getLeafColumns.md @@ -0,0 +1,36 @@ +--- +id: column_getLeafColumns +title: column_getLeafColumns +--- + +# Function: column\_getLeafColumns() + +```ts +function column_getLeafColumns(column): Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.utils.ts:24](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.utils.ts#L24) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\>[] diff --git a/docs/reference/functions/column_getNextSortingOrder.md b/docs/reference/functions/column_getNextSortingOrder.md new file mode 100644 index 0000000000..984bf4b472 --- /dev/null +++ b/docs/reference/functions/column_getNextSortingOrder.md @@ -0,0 +1,40 @@ +--- +id: column_getNextSortingOrder +title: column_getNextSortingOrder +--- + +# Function: column\_getNextSortingOrder() + +```ts +function column_getNextSortingOrder(column, multi?): false | "asc" | "desc"; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:223](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L223) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +### multi? + +`boolean` + +## Returns + +`false` \| `"asc"` \| `"desc"` diff --git a/docs/reference/functions/column_getPinnedIndex.md b/docs/reference/functions/column_getPinnedIndex.md new file mode 100644 index 0000000000..4be1704553 --- /dev/null +++ b/docs/reference/functions/column_getPinnedIndex.md @@ -0,0 +1,36 @@ +--- +id: column_getPinnedIndex +title: column_getPinnedIndex +--- + +# Function: column\_getPinnedIndex() + +```ts +function column_getPinnedIndex(column): number; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:103](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L103) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`number` diff --git a/docs/reference/functions/column_getSize.md b/docs/reference/functions/column_getSize.md new file mode 100644 index 0000000000..4dd6ab902e --- /dev/null +++ b/docs/reference/functions/column_getSize.md @@ -0,0 +1,36 @@ +--- +id: column_getSize +title: column_getSize +--- + +# Function: column\_getSize() + +```ts +function column_getSize(column): number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.utils.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.utils.ts#L29) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`number` diff --git a/docs/reference/functions/column_getSortFn.md b/docs/reference/functions/column_getSortFn.md new file mode 100644 index 0000000000..2ad1198852 --- /dev/null +++ b/docs/reference/functions/column_getSortFn.md @@ -0,0 +1,36 @@ +--- +id: column_getSortFn +title: column_getSortFn +--- + +# Function: column\_getSortFn() + +```ts +function column_getSortFn(column): SortFn; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:92](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L92) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +[`SortFn`](../interfaces/SortFn.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/column_getSortIndex.md b/docs/reference/functions/column_getSortIndex.md new file mode 100644 index 0000000000..c7c8807971 --- /dev/null +++ b/docs/reference/functions/column_getSortIndex.md @@ -0,0 +1,36 @@ +--- +id: column_getSortIndex +title: column_getSortIndex +--- + +# Function: column\_getSortIndex() + +```ts +function column_getSortIndex(column): number; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:280](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L280) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`number` diff --git a/docs/reference/functions/column_getStart.md b/docs/reference/functions/column_getStart.md new file mode 100644 index 0000000000..591c0cb885 --- /dev/null +++ b/docs/reference/functions/column_getStart.md @@ -0,0 +1,40 @@ +--- +id: column_getStart +title: column_getStart +--- + +# Function: column\_getStart() + +```ts +function column_getStart(column, position): number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.utils.ts:46](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.utils.ts#L46) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +### position + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) | `"center"` + +## Returns + +`number` diff --git a/docs/reference/functions/column_getToggleGroupingHandler.md b/docs/reference/functions/column_getToggleGroupingHandler.md new file mode 100644 index 0000000000..d3da4ab9ec --- /dev/null +++ b/docs/reference/functions/column_getToggleGroupingHandler.md @@ -0,0 +1,42 @@ +--- +id: column_getToggleGroupingHandler +title: column_getToggleGroupingHandler +--- + +# Function: column\_getToggleGroupingHandler() + +```ts +function column_getToggleGroupingHandler(column): () => void; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:62](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L62) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +```ts +(): void; +``` + +### Returns + +`void` diff --git a/docs/reference/functions/column_getToggleSortingHandler.md b/docs/reference/functions/column_getToggleSortingHandler.md new file mode 100644 index 0000000000..96319ac168 --- /dev/null +++ b/docs/reference/functions/column_getToggleSortingHandler.md @@ -0,0 +1,48 @@ +--- +id: column_getToggleSortingHandler +title: column_getToggleSortingHandler +--- + +# Function: column\_getToggleSortingHandler() + +```ts +function column_getToggleSortingHandler(column): (e) => void; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:301](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L301) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +```ts +(e): void; +``` + +### Parameters + +#### e + +`unknown` + +### Returns + +`void` diff --git a/docs/reference/functions/column_getToggleVisibilityHandler.md b/docs/reference/functions/column_getToggleVisibilityHandler.md new file mode 100644 index 0000000000..e1e4e2d134 --- /dev/null +++ b/docs/reference/functions/column_getToggleVisibilityHandler.md @@ -0,0 +1,48 @@ +--- +id: column_getToggleVisibilityHandler +title: column_getToggleVisibilityHandler +--- + +# Function: column\_getToggleVisibilityHandler() + +```ts +function column_getToggleVisibilityHandler(column): (e) => void; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:55](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L55) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +```ts +(e): void; +``` + +### Parameters + +#### e + +`unknown` + +### Returns + +`void` diff --git a/docs/reference/functions/column_pin.md b/docs/reference/functions/column_pin.md new file mode 100644 index 0000000000..e3842b67be --- /dev/null +++ b/docs/reference/functions/column_pin.md @@ -0,0 +1,40 @@ +--- +id: column_pin +title: column_pin +--- + +# Function: column\_pin() + +```ts +function column_pin(column, position): void; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:31](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L31) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +### position + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) + +## Returns + +`void` diff --git a/docs/reference/functions/column_resetSize.md b/docs/reference/functions/column_resetSize.md new file mode 100644 index 0000000000..0ef587d646 --- /dev/null +++ b/docs/reference/functions/column_resetSize.md @@ -0,0 +1,36 @@ +--- +id: column_resetSize +title: column_resetSize +--- + +# Function: column\_resetSize() + +```ts +function column_resetSize(column): void; +``` + +Defined in: [features/column-sizing/columnSizingFeature.utils.ts:88](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.utils.ts#L88) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`void` diff --git a/docs/reference/functions/column_setFilterValue.md b/docs/reference/functions/column_setFilterValue.md new file mode 100644 index 0000000000..b5bdc46725 --- /dev/null +++ b/docs/reference/functions/column_setFilterValue.md @@ -0,0 +1,40 @@ +--- +id: column_setFilterValue +title: column_setFilterValue +--- + +# Function: column\_setFilterValue() + +```ts +function column_setFilterValue(column, value): void; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.utils.ts:119](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.utils.ts#L119) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +### value + +`any` + +## Returns + +`void` diff --git a/docs/reference/functions/column_toggleGrouping.md b/docs/reference/functions/column_toggleGrouping.md new file mode 100644 index 0000000000..1dfad1a5d9 --- /dev/null +++ b/docs/reference/functions/column_toggleGrouping.md @@ -0,0 +1,36 @@ +--- +id: column_toggleGrouping +title: column_toggleGrouping +--- + +# Function: column\_toggleGrouping() + +```ts +function column_toggleGrouping(column): void; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:19](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L19) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`void` diff --git a/docs/reference/functions/column_toggleSorting.md b/docs/reference/functions/column_toggleSorting.md new file mode 100644 index 0000000000..ca74d949b7 --- /dev/null +++ b/docs/reference/functions/column_toggleSorting.md @@ -0,0 +1,47 @@ +--- +id: column_toggleSorting +title: column_toggleSorting +--- + +# Function: column\_toggleSorting() + +```ts +function column_toggleSorting( + column, + desc?, + multi?): void; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:108](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L108) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +### desc? + +`boolean` + +### multi? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/column_toggleVisibility.md b/docs/reference/functions/column_toggleVisibility.md new file mode 100644 index 0000000000..fff5b680a6 --- /dev/null +++ b/docs/reference/functions/column_toggleVisibility.md @@ -0,0 +1,40 @@ +--- +id: column_toggleVisibility +title: column_toggleVisibility +--- + +# Function: column\_toggleVisibility() + +```ts +function column_toggleVisibility(column, visible?): void; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L14) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +### visible? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/constructCell.md b/docs/reference/functions/constructCell.md new file mode 100644 index 0000000000..60628d4945 --- /dev/null +++ b/docs/reference/functions/constructCell.md @@ -0,0 +1,47 @@ +--- +id: constructCell +title: constructCell +--- + +# Function: constructCell() + +```ts +function constructCell( + column, + row, +table): Cell; +``` + +Defined in: [core/cells/constructCell.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/constructCell.ts#L26) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### column + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\> + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `TValue`\> diff --git a/docs/reference/functions/constructColumn.md b/docs/reference/functions/constructColumn.md new file mode 100644 index 0000000000..800eb52ac1 --- /dev/null +++ b/docs/reference/functions/constructColumn.md @@ -0,0 +1,52 @@ +--- +id: constructColumn +title: constructColumn +--- + +# Function: constructColumn() + +```ts +function constructColumn( + table, + columnDef, + depth, +parent?): Column; +``` + +Defined in: [core/columns/constructColumn.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/constructColumn.ts#L30) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### columnDef + +[`ColumnDef`](../type-aliases/ColumnDef.md)\<`TFeatures`, `TData`, `TValue`\> + +### depth + +`number` + +### parent? + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\> diff --git a/docs/reference/functions/constructColumnFacetingFeature.md b/docs/reference/functions/constructColumnFacetingFeature.md new file mode 100644 index 0000000000..52fbfdfc7c --- /dev/null +++ b/docs/reference/functions/constructColumnFacetingFeature.md @@ -0,0 +1,26 @@ +--- +id: constructColumnFacetingFeature +title: constructColumnFacetingFeature +--- + +# Function: constructColumnFacetingFeature() + +```ts +function constructColumnFacetingFeature(): TableFeature>; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.ts:32](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.ts#L32) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`ColumnFacetingFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructColumnFilteringFeature.md b/docs/reference/functions/constructColumnFilteringFeature.md new file mode 100644 index 0000000000..6f9f9b40a1 --- /dev/null +++ b/docs/reference/functions/constructColumnFilteringFeature.md @@ -0,0 +1,26 @@ +--- +id: constructColumnFilteringFeature +title: constructColumnFilteringFeature +--- + +# Function: constructColumnFilteringFeature() + +```ts +function constructColumnFilteringFeature(): TableFeature>; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.ts:47](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.ts#L47) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`ColumnFilteringFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructColumnGroupingFeature.md b/docs/reference/functions/constructColumnGroupingFeature.md new file mode 100644 index 0000000000..1050cc7725 --- /dev/null +++ b/docs/reference/functions/constructColumnGroupingFeature.md @@ -0,0 +1,26 @@ +--- +id: constructColumnGroupingFeature +title: constructColumnGroupingFeature +--- + +# Function: constructColumnGroupingFeature() + +```ts +function constructColumnGroupingFeature(): TableFeature>; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.ts:54](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.ts#L54) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`ColumnGroupingFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructColumnOrderingFeature.md b/docs/reference/functions/constructColumnOrderingFeature.md new file mode 100644 index 0000000000..2c99523fc2 --- /dev/null +++ b/docs/reference/functions/constructColumnOrderingFeature.md @@ -0,0 +1,26 @@ +--- +id: constructColumnOrderingFeature +title: constructColumnOrderingFeature +--- + +# Function: constructColumnOrderingFeature() + +```ts +function constructColumnOrderingFeature(): TableFeature>; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.ts#L34) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`ColumnOrderingFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructColumnPinningFeature.md b/docs/reference/functions/constructColumnPinningFeature.md new file mode 100644 index 0000000000..4e9933c73f --- /dev/null +++ b/docs/reference/functions/constructColumnPinningFeature.md @@ -0,0 +1,26 @@ +--- +id: constructColumnPinningFeature +title: constructColumnPinningFeature +--- + +# Function: constructColumnPinningFeature() + +```ts +function constructColumnPinningFeature(): TableFeature>; +``` + +Defined in: [features/column-pinning/columnPinningFeature.ts:62](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.ts#L62) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`ColumnPinningFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructColumnResizingFeature.md b/docs/reference/functions/constructColumnResizingFeature.md new file mode 100644 index 0000000000..73df8670c2 --- /dev/null +++ b/docs/reference/functions/constructColumnResizingFeature.md @@ -0,0 +1,26 @@ +--- +id: constructColumnResizingFeature +title: constructColumnResizingFeature +--- + +# Function: constructColumnResizingFeature() + +```ts +function constructColumnResizingFeature(): TableFeature>; +``` + +Defined in: [features/column-resizing/columnResizingFeature.ts:35](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.ts#L35) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`ColumnResizingFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructColumnSizingFeature.md b/docs/reference/functions/constructColumnSizingFeature.md new file mode 100644 index 0000000000..2c8731bb9d --- /dev/null +++ b/docs/reference/functions/constructColumnSizingFeature.md @@ -0,0 +1,26 @@ +--- +id: constructColumnSizingFeature +title: constructColumnSizingFeature +--- + +# Function: constructColumnSizingFeature() + +```ts +function constructColumnSizingFeature(): TableFeature>; +``` + +Defined in: [features/column-sizing/columnSizingFeature.ts:47](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.ts#L47) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`ColumnSizingFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructColumnVisibilityFeature.md b/docs/reference/functions/constructColumnVisibilityFeature.md new file mode 100644 index 0000000000..032bd84e93 --- /dev/null +++ b/docs/reference/functions/constructColumnVisibilityFeature.md @@ -0,0 +1,26 @@ +--- +id: constructColumnVisibilityFeature +title: constructColumnVisibilityFeature +--- + +# Function: constructColumnVisibilityFeature() + +```ts +function constructColumnVisibilityFeature(): TableFeature>; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.ts:51](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.ts#L51) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`ColumnVisibilityFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructCoreCellsFeature.md b/docs/reference/functions/constructCoreCellsFeature.md new file mode 100644 index 0000000000..9f657586ca --- /dev/null +++ b/docs/reference/functions/constructCoreCellsFeature.md @@ -0,0 +1,26 @@ +--- +id: constructCoreCellsFeature +title: constructCoreCellsFeature +--- + +# Function: constructCoreCellsFeature() + +```ts +function constructCoreCellsFeature(): TableFeature>; +``` + +Defined in: [core/cells/coreCellsFeature.ts:19](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.ts#L19) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`CoreCellsFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructCoreColumnsFeature.md b/docs/reference/functions/constructCoreColumnsFeature.md new file mode 100644 index 0000000000..0d0d077608 --- /dev/null +++ b/docs/reference/functions/constructCoreColumnsFeature.md @@ -0,0 +1,26 @@ +--- +id: constructCoreColumnsFeature +title: constructCoreColumnsFeature +--- + +# Function: constructCoreColumnsFeature() + +```ts +function constructCoreColumnsFeature(): TableFeature>; +``` + +Defined in: [core/columns/coreColumnsFeature.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.ts#L29) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`CoreColumnsFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructCoreHeadersFeature.md b/docs/reference/functions/constructCoreHeadersFeature.md new file mode 100644 index 0000000000..d7ba8b8111 --- /dev/null +++ b/docs/reference/functions/constructCoreHeadersFeature.md @@ -0,0 +1,26 @@ +--- +id: constructCoreHeadersFeature +title: constructCoreHeadersFeature +--- + +# Function: constructCoreHeadersFeature() + +```ts +function constructCoreHeadersFeature(): TableFeature>; +``` + +Defined in: [core/headers/coreHeadersFeature.ts:31](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.ts#L31) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`CoreHeadersFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructCoreRowModelsFeature.md b/docs/reference/functions/constructCoreRowModelsFeature.md new file mode 100644 index 0000000000..e96423158b --- /dev/null +++ b/docs/reference/functions/constructCoreRowModelsFeature.md @@ -0,0 +1,26 @@ +--- +id: constructCoreRowModelsFeature +title: constructCoreRowModelsFeature +--- + +# Function: constructCoreRowModelsFeature() + +```ts +function constructCoreRowModelsFeature(): TableFeature>; +``` + +Defined in: [core/row-models/coreRowModelsFeature.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.ts#L27) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`CoreRowModelsFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructCoreRowsFeature.md b/docs/reference/functions/constructCoreRowsFeature.md new file mode 100644 index 0000000000..ca040f8af3 --- /dev/null +++ b/docs/reference/functions/constructCoreRowsFeature.md @@ -0,0 +1,26 @@ +--- +id: constructCoreRowsFeature +title: constructCoreRowsFeature +--- + +# Function: constructCoreRowsFeature() + +```ts +function constructCoreRowsFeature(): TableFeature>; +``` + +Defined in: [core/rows/coreRowsFeature.ts:31](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.ts#L31) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`CoreRowsFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructCoreTablesFeature.md b/docs/reference/functions/constructCoreTablesFeature.md new file mode 100644 index 0000000000..f7a88c141a --- /dev/null +++ b/docs/reference/functions/constructCoreTablesFeature.md @@ -0,0 +1,26 @@ +--- +id: constructCoreTablesFeature +title: constructCoreTablesFeature +--- + +# Function: constructCoreTablesFeature() + +```ts +function constructCoreTablesFeature(): TableFeature>; +``` + +Defined in: [core/table/coreTablesFeature.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.ts#L15) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`CoreTablesFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructGlobalFilteringFeature.md b/docs/reference/functions/constructGlobalFilteringFeature.md new file mode 100644 index 0000000000..7b1be3fbb2 --- /dev/null +++ b/docs/reference/functions/constructGlobalFilteringFeature.md @@ -0,0 +1,26 @@ +--- +id: constructGlobalFilteringFeature +title: constructGlobalFilteringFeature +--- + +# Function: constructGlobalFilteringFeature() + +```ts +function constructGlobalFilteringFeature(): TableFeature>; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.ts#L34) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`GlobalFilteringFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructHeader.md b/docs/reference/functions/constructHeader.md new file mode 100644 index 0000000000..939f2d8a5d --- /dev/null +++ b/docs/reference/functions/constructHeader.md @@ -0,0 +1,65 @@ +--- +id: constructHeader +title: constructHeader +--- + +# Function: constructHeader() + +```ts +function constructHeader( + table, + column, +options): Header; +``` + +Defined in: [core/headers/constructHeader.ts:25](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/constructHeader.ts#L25) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### column + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\> + +### options + +#### depth + +`number` + +#### id? + +`string` + +#### index + +`number` + +#### isPlaceholder? + +`boolean` + +#### placeholderId? + +`string` + +## Returns + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `TValue`\> diff --git a/docs/reference/functions/constructRow.md b/docs/reference/functions/constructRow.md new file mode 100644 index 0000000000..c15c5fb72e --- /dev/null +++ b/docs/reference/functions/constructRow.md @@ -0,0 +1,63 @@ +--- +id: constructRow +title: constructRow +--- + +# Function: constructRow() + +```ts +function constructRow( + table, + id, + original, + rowIndex, + depth, + subRows?, +parentId?): Row; +``` + +Defined in: [core/rows/constructRow.ts:24](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/constructRow.ts#L24) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### id + +`string` + +### original + +`TData` + +### rowIndex + +`number` + +### depth + +`number` + +### subRows? + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] + +### parentId? + +`string` + +## Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/constructRowExpandingFeature.md b/docs/reference/functions/constructRowExpandingFeature.md new file mode 100644 index 0000000000..f9469e1e9f --- /dev/null +++ b/docs/reference/functions/constructRowExpandingFeature.md @@ -0,0 +1,26 @@ +--- +id: constructRowExpandingFeature +title: constructRowExpandingFeature +--- + +# Function: constructRowExpandingFeature() + +```ts +function constructRowExpandingFeature(): TableFeature>; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.ts:46](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.ts#L46) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`RowExpandingFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructRowPaginationFeature.md b/docs/reference/functions/constructRowPaginationFeature.md new file mode 100644 index 0000000000..7f3c0cdf58 --- /dev/null +++ b/docs/reference/functions/constructRowPaginationFeature.md @@ -0,0 +1,26 @@ +--- +id: constructRowPaginationFeature +title: constructRowPaginationFeature +--- + +# Function: constructRowPaginationFeature() + +```ts +function constructRowPaginationFeature(): TableFeature>; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.ts#L42) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`RowPaginationFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructRowPinningFeature.md b/docs/reference/functions/constructRowPinningFeature.md new file mode 100644 index 0000000000..92353b8820 --- /dev/null +++ b/docs/reference/functions/constructRowPinningFeature.md @@ -0,0 +1,26 @@ +--- +id: constructRowPinningFeature +title: constructRowPinningFeature +--- + +# Function: constructRowPinningFeature() + +```ts +function constructRowPinningFeature(): TableFeature>; +``` + +Defined in: [features/row-pinning/rowPinningFeature.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.ts#L38) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`RowPinningFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructRowSelectionFeature.md b/docs/reference/functions/constructRowSelectionFeature.md new file mode 100644 index 0000000000..c03f98060d --- /dev/null +++ b/docs/reference/functions/constructRowSelectionFeature.md @@ -0,0 +1,26 @@ +--- +id: constructRowSelectionFeature +title: constructRowSelectionFeature +--- + +# Function: constructRowSelectionFeature() + +```ts +function constructRowSelectionFeature(): TableFeature>; +``` + +Defined in: [features/row-selection/rowSelectionFeature.ts:50](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.ts#L50) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`RowSelectionFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructRowSortingFeature.md b/docs/reference/functions/constructRowSortingFeature.md new file mode 100644 index 0000000000..dcbf834a85 --- /dev/null +++ b/docs/reference/functions/constructRowSortingFeature.md @@ -0,0 +1,26 @@ +--- +id: constructRowSortingFeature +title: constructRowSortingFeature +--- + +# Function: constructRowSortingFeature() + +```ts +function constructRowSortingFeature(): TableFeature>; +``` + +Defined in: [features/row-sorting/rowSortingFeature.ts:50](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.ts#L50) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`TableFeature`](../interfaces/TableFeature.md)\<`RowSortingFeatureConstructors`\<`TFeatures`, `TData`\>\> diff --git a/docs/reference/functions/constructTable.md b/docs/reference/functions/constructTable.md new file mode 100644 index 0000000000..3a16ec869b --- /dev/null +++ b/docs/reference/functions/constructTable.md @@ -0,0 +1,32 @@ +--- +id: constructTable +title: constructTable +--- + +# Function: constructTable() + +```ts +function constructTable(tableOptions): Table; +``` + +Defined in: [core/table/constructTable.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/constructTable.ts#L29) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### tableOptions + +[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/constructTableHelper.md b/docs/reference/functions/constructTableHelper.md new file mode 100644 index 0000000000..b2cb42e297 --- /dev/null +++ b/docs/reference/functions/constructTableHelper.md @@ -0,0 +1,34 @@ +--- +id: constructTableHelper +title: constructTableHelper +--- + +# Function: constructTableHelper() + +```ts +function constructTableHelper(tableCreator, tableHelperOptions): TableHelper_Core; +``` + +Defined in: [helpers/tableHelper.ts:44](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableHelper.ts#L44) + +Internal function to create a table helper that each adapter package will use to create their own table helper + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +## Parameters + +### tableCreator + +\<`TData`\>(`tableOptions`, `selector?`) => [`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +### tableHelperOptions + +[`TableHelperOptions`](../type-aliases/TableHelperOptions.md)\<`TFeatures`\> + +## Returns + +[`TableHelper_Core`](../type-aliases/TableHelper_Core.md)\<`TFeatures`\> diff --git a/docs/reference/functions/createColumnHelper.md b/docs/reference/functions/createColumnHelper.md new file mode 100644 index 0000000000..878ce28895 --- /dev/null +++ b/docs/reference/functions/createColumnHelper.md @@ -0,0 +1,41 @@ +--- +id: createColumnHelper +title: createColumnHelper +--- + +# Function: createColumnHelper() + +```ts +function createColumnHelper(): ColumnHelper; +``` + +Defined in: [helpers/columnHelper.ts:94](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/columnHelper.ts#L94) + +A helper utility for creating column definitions with slightly better type inference for each individual column. +The `TValue` generic is inferred based on the accessor key or function provided. +**Note:** From a JavaScript perspective, the functions in these helpers do not do anything. They are only used to help TypeScript infer the correct types for the column definitions. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +[`ColumnHelper`](../type-aliases/ColumnHelper.md)\<`TFeatures`, `TData`\> + +## Example + +```tsx +const helper = createColumnHelper() // _features is the result of `tableFeatures({})` helper +const columns = [ + helper.display({ id: 'actions', header: 'Actions' }), + helper.accessor('firstName', {}), + helper.accessor((row) => row.lastName, {} +] +``` diff --git a/docs/reference/functions/createCoreRowModel.md b/docs/reference/functions/createCoreRowModel.md new file mode 100644 index 0000000000..891142e85e --- /dev/null +++ b/docs/reference/functions/createCoreRowModel.md @@ -0,0 +1,44 @@ +--- +id: createCoreRowModel +title: createCoreRowModel +--- + +# Function: createCoreRowModel() + +```ts +function createCoreRowModel(): (table) => () => RowModel; +``` + +Defined in: [core/row-models/createCoreRowModel.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/createCoreRowModel.ts#L10) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Returns + +```ts +(table): () => RowModel; +``` + +### Parameters + +#### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +### Returns + +```ts +(): RowModel; +``` + +#### Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/createExpandedRowModel.md b/docs/reference/functions/createExpandedRowModel.md new file mode 100644 index 0000000000..b5499c25be --- /dev/null +++ b/docs/reference/functions/createExpandedRowModel.md @@ -0,0 +1,44 @@ +--- +id: createExpandedRowModel +title: createExpandedRowModel +--- + +# Function: createExpandedRowModel() + +```ts +function createExpandedRowModel(): (table) => () => RowModel; +``` + +Defined in: [features/row-expanding/createExpandedRowModel.ts:9](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/createExpandedRowModel.ts#L9) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +## Returns + +```ts +(table): () => RowModel; +``` + +### Parameters + +#### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +### Returns + +```ts +(): RowModel; +``` + +#### Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/createFacetedMinMaxValues.md b/docs/reference/functions/createFacetedMinMaxValues.md new file mode 100644 index 0000000000..26fa59f9b9 --- /dev/null +++ b/docs/reference/functions/createFacetedMinMaxValues.md @@ -0,0 +1,48 @@ +--- +id: createFacetedMinMaxValues +title: createFacetedMinMaxValues +--- + +# Function: createFacetedMinMaxValues() + +```ts +function createFacetedMinMaxValues(): (table, columnId) => () => [number, number] | undefined; +``` + +Defined in: [features/column-faceting/createFacetedMinMaxValues.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/createFacetedMinMaxValues.ts#L8) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +## Returns + +```ts +(table, columnId): () => [number, number] | undefined; +``` + +### Parameters + +#### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +#### columnId + +`string` + +### Returns + +```ts +(): [number, number] | undefined; +``` + +#### Returns + +\[`number`, `number`\] \| `undefined` diff --git a/docs/reference/functions/createFacetedRowModel.md b/docs/reference/functions/createFacetedRowModel.md new file mode 100644 index 0000000000..7844c294e0 --- /dev/null +++ b/docs/reference/functions/createFacetedRowModel.md @@ -0,0 +1,48 @@ +--- +id: createFacetedRowModel +title: createFacetedRowModel +--- + +# Function: createFacetedRowModel() + +```ts +function createFacetedRowModel(): (table, columnId) => () => RowModel; +``` + +Defined in: [features/column-faceting/createFacetedRowModel.ts:13](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/createFacetedRowModel.ts#L13) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +## Returns + +```ts +(table, columnId): () => RowModel; +``` + +### Parameters + +#### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +#### columnId + +`string` + +### Returns + +```ts +(): RowModel; +``` + +#### Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/createFacetedUniqueValues.md b/docs/reference/functions/createFacetedUniqueValues.md new file mode 100644 index 0000000000..231d9d81f6 --- /dev/null +++ b/docs/reference/functions/createFacetedUniqueValues.md @@ -0,0 +1,48 @@ +--- +id: createFacetedUniqueValues +title: createFacetedUniqueValues +--- + +# Function: createFacetedUniqueValues() + +```ts +function createFacetedUniqueValues(): (table, columnId) => () => Map; +``` + +Defined in: [features/column-faceting/createFacetedUniqueValues.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/createFacetedUniqueValues.ts#L8) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +## Returns + +```ts +(table, columnId): () => Map; +``` + +### Parameters + +#### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +#### columnId + +`string` + +### Returns + +```ts +(): Map; +``` + +#### Returns + +`Map`\<`any`, `number`\> diff --git a/docs/reference/functions/createFilteredRowModel.md b/docs/reference/functions/createFilteredRowModel.md new file mode 100644 index 0000000000..cc38905c6c --- /dev/null +++ b/docs/reference/functions/createFilteredRowModel.md @@ -0,0 +1,50 @@ +--- +id: createFilteredRowModel +title: createFilteredRowModel +--- + +# Function: createFilteredRowModel() + +```ts +function createFilteredRowModel(filterFns): (table) => () => RowModel; +``` + +Defined in: [features/column-filtering/createFilteredRowModel.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/createFilteredRowModel.ts#L22) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +## Parameters + +### filterFns + +`Record`\\> + +## Returns + +```ts +(table): () => RowModel; +``` + +### Parameters + +#### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +### Returns + +```ts +(): RowModel; +``` + +#### Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/createGroupedRowModel.md b/docs/reference/functions/createGroupedRowModel.md new file mode 100644 index 0000000000..ff97b03413 --- /dev/null +++ b/docs/reference/functions/createGroupedRowModel.md @@ -0,0 +1,50 @@ +--- +id: createGroupedRowModel +title: createGroupedRowModel +--- + +# Function: createGroupedRowModel() + +```ts +function createGroupedRowModel(aggregationFns): (table) => () => RowModel; +``` + +Defined in: [features/column-grouping/createGroupedRowModel.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/createGroupedRowModel.ts#L22) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +## Parameters + +### aggregationFns + +`Record`\\> + +## Returns + +```ts +(table): () => RowModel; +``` + +### Parameters + +#### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +### Returns + +```ts +(): RowModel; +``` + +#### Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/createPaginatedRowModel.md b/docs/reference/functions/createPaginatedRowModel.md new file mode 100644 index 0000000000..360310498e --- /dev/null +++ b/docs/reference/functions/createPaginatedRowModel.md @@ -0,0 +1,44 @@ +--- +id: createPaginatedRowModel +title: createPaginatedRowModel +--- + +# Function: createPaginatedRowModel() + +```ts +function createPaginatedRowModel(): (table) => () => RowModel; +``` + +Defined in: [features/row-pagination/createPaginatedRowModel.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/createPaginatedRowModel.ts#L10) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +## Returns + +```ts +(table): () => RowModel; +``` + +### Parameters + +#### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +### Returns + +```ts +(): RowModel; +``` + +#### Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/createSortedRowModel.md b/docs/reference/functions/createSortedRowModel.md new file mode 100644 index 0000000000..358d087e04 --- /dev/null +++ b/docs/reference/functions/createSortedRowModel.md @@ -0,0 +1,50 @@ +--- +id: createSortedRowModel +title: createSortedRowModel +--- + +# Function: createSortedRowModel() + +```ts +function createSortedRowModel(sortFns): (table) => () => RowModel; +``` + +Defined in: [features/row-sorting/createSortedRowModel.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/createSortedRowModel.ts#L12) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### sortFns + +`Record`\\> + +## Returns + +```ts +(table): () => RowModel; +``` + +### Parameters + +#### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +### Returns + +```ts +(): RowModel; +``` + +#### Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/createTableStore.md b/docs/reference/functions/createTableStore.md new file mode 100644 index 0000000000..28730f2a8c --- /dev/null +++ b/docs/reference/functions/createTableStore.md @@ -0,0 +1,32 @@ +--- +id: createTableStore +title: createTableStore +--- + +# Function: createTableStore() + +```ts +function createTableStore(features, initialState): Store>; +``` + +Defined in: [core/table/constructTable.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/constructTable.ts#L22) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +## Parameters + +### features + +`TFeatures` + +### initialState + +`Partial`\<[`TableState`](../type-aliases/TableState.md)\<`TFeatures`\>\> | `undefined` + +## Returns + +`Store`\<[`TableState`](../type-aliases/TableState.md)\<`TFeatures`\>\> diff --git a/docs/reference/functions/expandRows.md b/docs/reference/functions/expandRows.md new file mode 100644 index 0000000000..93217b8c35 --- /dev/null +++ b/docs/reference/functions/expandRows.md @@ -0,0 +1,32 @@ +--- +id: expandRows +title: expandRows +--- + +# Function: expandRows() + +```ts +function expandRows(rowModel): RowModel; +``` + +Defined in: [features/row-expanding/createExpandedRowModel.ts:51](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/createExpandedRowModel.ts#L51) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +## Parameters + +### rowModel + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/flattenBy.md b/docs/reference/functions/flattenBy.md new file mode 100644 index 0000000000..0478469106 --- /dev/null +++ b/docs/reference/functions/flattenBy.md @@ -0,0 +1,32 @@ +--- +id: flattenBy +title: flattenBy +--- + +# Function: flattenBy() + +```ts +function flattenBy(arr, getChildren): TNode[]; +``` + +Defined in: [utils.ts:40](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L40) + +## Type Parameters + +### TNode + +`TNode` + +## Parameters + +### arr + +`TNode`[] + +### getChildren + +(`item`) => `TNode`[] + +## Returns + +`TNode`[] diff --git a/docs/reference/functions/functionalUpdate.md b/docs/reference/functions/functionalUpdate.md new file mode 100644 index 0000000000..52e12cc8ac --- /dev/null +++ b/docs/reference/functions/functionalUpdate.md @@ -0,0 +1,32 @@ +--- +id: functionalUpdate +title: functionalUpdate +--- + +# Function: functionalUpdate() + +```ts +function functionalUpdate(updater, input): T; +``` + +Defined in: [utils.ts:6](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L6) + +## Type Parameters + +### T + +`T` + +## Parameters + +### updater + +[`Updater`](../type-aliases/Updater.md)\<`T`\> + +### input + +`T` + +## Returns + +`T` diff --git a/docs/reference/functions/getDefaultColumnFiltersState.md b/docs/reference/functions/getDefaultColumnFiltersState.md new file mode 100644 index 0000000000..01cd6bf425 --- /dev/null +++ b/docs/reference/functions/getDefaultColumnFiltersState.md @@ -0,0 +1,16 @@ +--- +id: getDefaultColumnFiltersState +title: getDefaultColumnFiltersState +--- + +# Function: getDefaultColumnFiltersState() + +```ts +function getDefaultColumnFiltersState(): ColumnFiltersState; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.utils.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.utils.ts#L11) + +## Returns + +[`ColumnFiltersState`](../type-aliases/ColumnFiltersState.md) diff --git a/docs/reference/functions/getDefaultColumnOrderState.md b/docs/reference/functions/getDefaultColumnOrderState.md new file mode 100644 index 0000000000..76b6641d97 --- /dev/null +++ b/docs/reference/functions/getDefaultColumnOrderState.md @@ -0,0 +1,16 @@ +--- +id: getDefaultColumnOrderState +title: getDefaultColumnOrderState +--- + +# Function: getDefaultColumnOrderState() + +```ts +function getDefaultColumnOrderState(): ColumnOrderState; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.utils.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.utils.ts#L10) + +## Returns + +[`ColumnOrderState`](../type-aliases/ColumnOrderState.md) diff --git a/docs/reference/functions/getDefaultColumnPinningState.md b/docs/reference/functions/getDefaultColumnPinningState.md new file mode 100644 index 0000000000..17dff16c53 --- /dev/null +++ b/docs/reference/functions/getDefaultColumnPinningState.md @@ -0,0 +1,16 @@ +--- +id: getDefaultColumnPinningState +title: getDefaultColumnPinningState +--- + +# Function: getDefaultColumnPinningState() + +```ts +function getDefaultColumnPinningState(): ColumnPinningState; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L22) + +## Returns + +[`ColumnPinningState`](../interfaces/ColumnPinningState.md) diff --git a/docs/reference/functions/getDefaultColumnResizingState.md b/docs/reference/functions/getDefaultColumnResizingState.md new file mode 100644 index 0000000000..aa88930a90 --- /dev/null +++ b/docs/reference/functions/getDefaultColumnResizingState.md @@ -0,0 +1,16 @@ +--- +id: getDefaultColumnResizingState +title: getDefaultColumnResizingState +--- + +# Function: getDefaultColumnResizingState() + +```ts +function getDefaultColumnResizingState(): columnResizingState; +``` + +Defined in: [features/column-resizing/columnResizingFeature.utils.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.utils.ts#L15) + +## Returns + +[`columnResizingState`](../interfaces/columnResizingState.md) diff --git a/docs/reference/functions/getDefaultColumnSizingColumnDef.md b/docs/reference/functions/getDefaultColumnSizingColumnDef.md new file mode 100644 index 0000000000..89daefd5e6 --- /dev/null +++ b/docs/reference/functions/getDefaultColumnSizingColumnDef.md @@ -0,0 +1,34 @@ +--- +id: getDefaultColumnSizingColumnDef +title: getDefaultColumnSizingColumnDef +--- + +# Function: getDefaultColumnSizingColumnDef() + +```ts +function getDefaultColumnSizingColumnDef(): object; +``` + +Defined in: [features/column-sizing/columnSizingFeature.utils.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.utils.ts#L21) + +## Returns + +`object` + +### maxSize + +```ts +maxSize: number = Number.MAX_SAFE_INTEGER; +``` + +### minSize + +```ts +minSize: number = 20; +``` + +### size + +```ts +size: number = 150; +``` diff --git a/docs/reference/functions/getDefaultColumnSizingState.md b/docs/reference/functions/getDefaultColumnSizingState.md new file mode 100644 index 0000000000..7ffe17d73d --- /dev/null +++ b/docs/reference/functions/getDefaultColumnSizingState.md @@ -0,0 +1,16 @@ +--- +id: getDefaultColumnSizingState +title: getDefaultColumnSizingState +--- + +# Function: getDefaultColumnSizingState() + +```ts +function getDefaultColumnSizingState(): ColumnSizingState; +``` + +Defined in: [features/column-sizing/columnSizingFeature.utils.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.utils.ts#L17) + +## Returns + +[`ColumnSizingState`](../type-aliases/ColumnSizingState.md) diff --git a/docs/reference/functions/getDefaultColumnVisibilityState.md b/docs/reference/functions/getDefaultColumnVisibilityState.md new file mode 100644 index 0000000000..dda4416fdc --- /dev/null +++ b/docs/reference/functions/getDefaultColumnVisibilityState.md @@ -0,0 +1,16 @@ +--- +id: getDefaultColumnVisibilityState +title: getDefaultColumnVisibilityState +--- + +# Function: getDefaultColumnVisibilityState() + +```ts +function getDefaultColumnVisibilityState(): ColumnVisibilityState; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L10) + +## Returns + +[`ColumnVisibilityState`](../type-aliases/ColumnVisibilityState.md) diff --git a/docs/reference/functions/getDefaultExpandedState.md b/docs/reference/functions/getDefaultExpandedState.md new file mode 100644 index 0000000000..3eb177b31d --- /dev/null +++ b/docs/reference/functions/getDefaultExpandedState.md @@ -0,0 +1,16 @@ +--- +id: getDefaultExpandedState +title: getDefaultExpandedState +--- + +# Function: getDefaultExpandedState() + +```ts +function getDefaultExpandedState(): ExpandedState; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L10) + +## Returns + +[`ExpandedState`](../type-aliases/ExpandedState.md) diff --git a/docs/reference/functions/getDefaultGroupingState.md b/docs/reference/functions/getDefaultGroupingState.md new file mode 100644 index 0000000000..213ac83cca --- /dev/null +++ b/docs/reference/functions/getDefaultGroupingState.md @@ -0,0 +1,16 @@ +--- +id: getDefaultGroupingState +title: getDefaultGroupingState +--- + +# Function: getDefaultGroupingState() + +```ts +function getDefaultGroupingState(): GroupingState; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L15) + +## Returns + +[`GroupingState`](../type-aliases/GroupingState.md) diff --git a/docs/reference/functions/getDefaultPaginationState.md b/docs/reference/functions/getDefaultPaginationState.md new file mode 100644 index 0000000000..8701d43269 --- /dev/null +++ b/docs/reference/functions/getDefaultPaginationState.md @@ -0,0 +1,16 @@ +--- +id: getDefaultPaginationState +title: getDefaultPaginationState +--- + +# Function: getDefaultPaginationState() + +```ts +function getDefaultPaginationState(): PaginationState; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L10) + +## Returns + +[`PaginationState`](../interfaces/PaginationState.md) diff --git a/docs/reference/functions/getDefaultRowPinningState.md b/docs/reference/functions/getDefaultRowPinningState.md new file mode 100644 index 0000000000..3470248367 --- /dev/null +++ b/docs/reference/functions/getDefaultRowPinningState.md @@ -0,0 +1,16 @@ +--- +id: getDefaultRowPinningState +title: getDefaultRowPinningState +--- + +# Function: getDefaultRowPinningState() + +```ts +function getDefaultRowPinningState(): RowPinningState; +``` + +Defined in: [features/row-pinning/rowPinningFeature.utils.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.utils.ts#L14) + +## Returns + +[`RowPinningState`](../interfaces/RowPinningState.md) diff --git a/docs/reference/functions/getDefaultRowSelectionState.md b/docs/reference/functions/getDefaultRowSelectionState.md new file mode 100644 index 0000000000..8e2dfaf0b7 --- /dev/null +++ b/docs/reference/functions/getDefaultRowSelectionState.md @@ -0,0 +1,16 @@ +--- +id: getDefaultRowSelectionState +title: getDefaultRowSelectionState +--- + +# Function: getDefaultRowSelectionState() + +```ts +function getDefaultRowSelectionState(): RowSelectionState; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L10) + +## Returns + +[`RowSelectionState`](../type-aliases/RowSelectionState.md) diff --git a/docs/reference/functions/getDefaultSortingState.md b/docs/reference/functions/getDefaultSortingState.md new file mode 100644 index 0000000000..cb57d4e9df --- /dev/null +++ b/docs/reference/functions/getDefaultSortingState.md @@ -0,0 +1,16 @@ +--- +id: getDefaultSortingState +title: getDefaultSortingState +--- + +# Function: getDefaultSortingState() + +```ts +function getDefaultSortingState(): SortingState; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L15) + +## Returns + +[`SortingState`](../type-aliases/SortingState.md) diff --git a/docs/reference/functions/getFunctionNameInfo.md b/docs/reference/functions/getFunctionNameInfo.md new file mode 100644 index 0000000000..86768a0ae6 --- /dev/null +++ b/docs/reference/functions/getFunctionNameInfo.md @@ -0,0 +1,46 @@ +--- +id: getFunctionNameInfo +title: getFunctionNameInfo +--- + +# Function: getFunctionNameInfo() + +```ts +function getFunctionNameInfo(staticFnName, splitBy): object; +``` + +Defined in: [utils.ts:280](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L280) + +Assumes that a function name is in the format of `parentName_fnKey` and returns the `fnKey` and `fnName` in the format of `parentName.fnKey`. + +## Parameters + +### staticFnName + +`string` + +### splitBy + +`"_"` | `"."` + +## Returns + +`object` + +### fnKey + +```ts +fnKey: string; +``` + +### fnName + +```ts +fnName: string; +``` + +### parentName + +```ts +parentName: string; +``` diff --git a/docs/reference/functions/getInitialTableState.md b/docs/reference/functions/getInitialTableState.md new file mode 100644 index 0000000000..62c995128e --- /dev/null +++ b/docs/reference/functions/getInitialTableState.md @@ -0,0 +1,32 @@ +--- +id: getInitialTableState +title: getInitialTableState +--- + +# Function: getInitialTableState() + +```ts +function getInitialTableState(features, initialState): TableState; +``` + +Defined in: [core/table/constructTable.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/constructTable.ts#L10) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +## Parameters + +### features + +`TFeatures` + +### initialState + +`Partial`\<[`TableState`](../type-aliases/TableState.md)\<`TFeatures`\>\> | `undefined` + +## Returns + +[`TableState`](../type-aliases/TableState.md)\<`TFeatures`\> diff --git a/docs/reference/functions/getMemoFnMeta.md b/docs/reference/functions/getMemoFnMeta.md new file mode 100644 index 0000000000..d8555afd30 --- /dev/null +++ b/docs/reference/functions/getMemoFnMeta.md @@ -0,0 +1,24 @@ +--- +id: getMemoFnMeta +title: getMemoFnMeta +--- + +# Function: getMemoFnMeta() + +```ts +function getMemoFnMeta(fn): MemoFnMeta | null; +``` + +Defined in: [utils.ts:74](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L74) + +**`Internal`** + +## Parameters + +### fn + +`any` + +## Returns + +[`MemoFnMeta`](../type-aliases/MemoFnMeta.md) \| `null` diff --git a/docs/reference/functions/header_getContext.md b/docs/reference/functions/header_getContext.md new file mode 100644 index 0000000000..3642011124 --- /dev/null +++ b/docs/reference/functions/header_getContext.md @@ -0,0 +1,54 @@ +--- +id: header_getContext +title: header_getContext +--- + +# Function: header\_getContext() + +```ts +function header_getContext(header): object; +``` + +Defined in: [core/headers/coreHeadersFeature.utils.ts:36](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.utils.ts#L36) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` + +## Parameters + +### header + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`object` + +### column + +```ts +column: Column = header.column; +``` + +### header + +```ts +header: Header; +``` + +### table + +```ts +table: Table_Internal = header.column.table; +``` diff --git a/docs/reference/functions/header_getLeafHeaders.md b/docs/reference/functions/header_getLeafHeaders.md new file mode 100644 index 0000000000..1ae9df99f7 --- /dev/null +++ b/docs/reference/functions/header_getLeafHeaders.md @@ -0,0 +1,36 @@ +--- +id: header_getLeafHeaders +title: header_getLeafHeaders +--- + +# Function: header\_getLeafHeaders() + +```ts +function header_getLeafHeaders(header): Header[]; +``` + +Defined in: [core/headers/coreHeadersFeature.utils.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.utils.ts#L17) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` + +## Parameters + +### header + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `TValue`\>[] diff --git a/docs/reference/functions/header_getResizeHandler.md b/docs/reference/functions/header_getResizeHandler.md new file mode 100644 index 0000000000..fd49eaf3e8 --- /dev/null +++ b/docs/reference/functions/header_getResizeHandler.md @@ -0,0 +1,52 @@ +--- +id: header_getResizeHandler +title: header_getResizeHandler +--- + +# Function: header\_getResizeHandler() + +```ts +function header_getResizeHandler(header, _contextDocument?): (event) => void; +``` + +Defined in: [features/column-resizing/columnResizingFeature.utils.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.utils.ts#L45) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### header + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `TValue`\> + +### \_contextDocument? + +`Document` + +## Returns + +```ts +(event): void; +``` + +### Parameters + +#### event + +`unknown` + +### Returns + +`void` diff --git a/docs/reference/functions/header_getSize.md b/docs/reference/functions/header_getSize.md new file mode 100644 index 0000000000..6cd56d16a2 --- /dev/null +++ b/docs/reference/functions/header_getSize.md @@ -0,0 +1,36 @@ +--- +id: header_getSize +title: header_getSize +--- + +# Function: header\_getSize() + +```ts +function header_getSize(header): number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.utils.ts:98](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.utils.ts#L98) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### header + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`number` diff --git a/docs/reference/functions/header_getStart.md b/docs/reference/functions/header_getStart.md new file mode 100644 index 0000000000..7ffb78b071 --- /dev/null +++ b/docs/reference/functions/header_getStart.md @@ -0,0 +1,36 @@ +--- +id: header_getStart +title: header_getStart +--- + +# Function: header\_getStart() + +```ts +function header_getStart(header): number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.utils.ts:118](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.utils.ts#L118) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### header + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`number` diff --git a/docs/reference/functions/isFunction.md b/docs/reference/functions/isFunction.md new file mode 100644 index 0000000000..2de56b4337 --- /dev/null +++ b/docs/reference/functions/isFunction.md @@ -0,0 +1,28 @@ +--- +id: isFunction +title: isFunction +--- + +# Function: isFunction() + +```ts +function isFunction(d): d is T; +``` + +Defined in: [utils.ts:32](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L32) + +## Type Parameters + +### T + +`T` *extends* `AnyFunction` + +## Parameters + +### d + +`any` + +## Returns + +`d is T` diff --git a/docs/reference/functions/isNumberArray.md b/docs/reference/functions/isNumberArray.md new file mode 100644 index 0000000000..c40d3d1d87 --- /dev/null +++ b/docs/reference/functions/isNumberArray.md @@ -0,0 +1,22 @@ +--- +id: isNumberArray +title: isNumberArray +--- + +# Function: isNumberArray() + +```ts +function isNumberArray(d): d is number[]; +``` + +Defined in: [utils.ts:36](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L36) + +## Parameters + +### d + +`any` + +## Returns + +`d is number[]` diff --git a/docs/reference/functions/isRowSelected.md b/docs/reference/functions/isRowSelected.md new file mode 100644 index 0000000000..f63371fdd5 --- /dev/null +++ b/docs/reference/functions/isRowSelected.md @@ -0,0 +1,32 @@ +--- +id: isRowSelected +title: isRowSelected +--- + +# Function: isRowSelected() + +```ts +function isRowSelected(row): boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:418](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L418) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/isSubRowSelected.md b/docs/reference/functions/isSubRowSelected.md new file mode 100644 index 0000000000..cd15f28eb9 --- /dev/null +++ b/docs/reference/functions/isSubRowSelected.md @@ -0,0 +1,32 @@ +--- +id: isSubRowSelected +title: isSubRowSelected +--- + +# Function: isSubRowSelected() + +```ts +function isSubRowSelected(row): boolean | "some" | "all"; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:425](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L425) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` \| `"some"` \| `"all"` diff --git a/docs/reference/functions/isTouchStartEvent.md b/docs/reference/functions/isTouchStartEvent.md new file mode 100644 index 0000000000..3147919b3e --- /dev/null +++ b/docs/reference/functions/isTouchStartEvent.md @@ -0,0 +1,22 @@ +--- +id: isTouchStartEvent +title: isTouchStartEvent +--- + +# Function: isTouchStartEvent() + +```ts +function isTouchStartEvent(e): e is TouchEvent; +``` + +Defined in: [features/column-resizing/columnResizingFeature.utils.ts:263](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.utils.ts#L263) + +## Parameters + +### e + +`unknown` + +## Returns + +`e is TouchEvent` diff --git a/docs/reference/functions/makeStateUpdater.md b/docs/reference/functions/makeStateUpdater.md new file mode 100644 index 0000000000..d5648007bd --- /dev/null +++ b/docs/reference/functions/makeStateUpdater.md @@ -0,0 +1,48 @@ +--- +id: makeStateUpdater +title: makeStateUpdater +--- + +# Function: makeStateUpdater() + +```ts +function makeStateUpdater(key, instance): (updater) => void; +``` + +Defined in: [utils.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L14) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### K + +`K` *extends* `string` \| `number` \| `symbol` \| `string` & `object` + +## Parameters + +### key + +`K` + +### instance + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `any`\> + +## Returns + +```ts +(updater): void; +``` + +### Parameters + +#### updater + +`any` + +### Returns + +`void` diff --git a/docs/reference/functions/memo.md b/docs/reference/functions/memo.md new file mode 100644 index 0000000000..4ec5151291 --- /dev/null +++ b/docs/reference/functions/memo.md @@ -0,0 +1,48 @@ +--- +id: memo +title: memo +--- + +# Function: memo() + +```ts +function memo(__namedParameters): (depArgs?) => TResult; +``` + +Defined in: [utils.ts:87](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L87) + +## Type Parameters + +### TDeps + +`TDeps` *extends* readonly `any`[] + +### TDepArgs + +`TDepArgs` + +### TResult + +`TResult` + +## Parameters + +### \_\_namedParameters + +`MemoOptions`\<`TDeps`, `TDepArgs`, `TResult`\> + +## Returns + +```ts +(depArgs?): TResult; +``` + +### Parameters + +#### depArgs? + +`TDepArgs` + +### Returns + +`TResult` diff --git a/docs/reference/functions/noop.md b/docs/reference/functions/noop.md new file mode 100644 index 0000000000..171dd12e09 --- /dev/null +++ b/docs/reference/functions/noop.md @@ -0,0 +1,16 @@ +--- +id: noop +title: noop +--- + +# Function: noop() + +```ts +function noop(): void; +``` + +Defined in: [utils.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L12) + +## Returns + +`void` diff --git a/docs/reference/functions/orderColumns.md b/docs/reference/functions/orderColumns.md new file mode 100644 index 0000000000..44184f7c07 --- /dev/null +++ b/docs/reference/functions/orderColumns.md @@ -0,0 +1,36 @@ +--- +id: orderColumns +title: orderColumns +--- + +# Function: orderColumns() + +```ts +function orderColumns(table, leafColumns): Column_Internal[]; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.utils.ts:106](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.utils.ts#L106) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### leafColumns + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `unknown`\>[] + +## Returns + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/passiveEventSupported.md b/docs/reference/functions/passiveEventSupported.md new file mode 100644 index 0000000000..ee83a24393 --- /dev/null +++ b/docs/reference/functions/passiveEventSupported.md @@ -0,0 +1,16 @@ +--- +id: passiveEventSupported +title: passiveEventSupported +--- + +# Function: passiveEventSupported() + +```ts +function passiveEventSupported(): boolean; +``` + +Defined in: [features/column-resizing/columnResizingFeature.utils.ts:238](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.utils.ts#L238) + +## Returns + +`boolean` diff --git a/docs/reference/functions/row_getAllCells.md b/docs/reference/functions/row_getAllCells.md new file mode 100644 index 0000000000..7261297c27 --- /dev/null +++ b/docs/reference/functions/row_getAllCells.md @@ -0,0 +1,32 @@ +--- +id: row_getAllCells +title: row_getAllCells +--- + +# Function: row\_getAllCells() + +```ts +function row_getAllCells(row): Cell[]; +``` + +Defined in: [core/rows/coreRowsFeature.utils.ts:92](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L92) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/row_getAllCellsByColumnId.md b/docs/reference/functions/row_getAllCellsByColumnId.md new file mode 100644 index 0000000000..55d8cf2532 --- /dev/null +++ b/docs/reference/functions/row_getAllCellsByColumnId.md @@ -0,0 +1,32 @@ +--- +id: row_getAllCellsByColumnId +title: row_getAllCellsByColumnId +--- + +# Function: row\_getAllCellsByColumnId() + +```ts +function row_getAllCellsByColumnId(row): Record>; +``` + +Defined in: [core/rows/coreRowsFeature.utils.ts:101](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L101) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`Record`\<`string`, [`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>\> diff --git a/docs/reference/functions/row_getAllVisibleCells.md b/docs/reference/functions/row_getAllVisibleCells.md new file mode 100644 index 0000000000..2bfb23159a --- /dev/null +++ b/docs/reference/functions/row_getAllVisibleCells.md @@ -0,0 +1,32 @@ +--- +id: row_getAllVisibleCells +title: row_getAllVisibleCells +--- + +# Function: row\_getAllVisibleCells() + +```ts +function row_getAllVisibleCells(row): Cell[]; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:68](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L68) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/row_getCanExpand.md b/docs/reference/functions/row_getCanExpand.md new file mode 100644 index 0000000000..3f3bc7f149 --- /dev/null +++ b/docs/reference/functions/row_getCanExpand.md @@ -0,0 +1,32 @@ +--- +id: row_getCanExpand +title: row_getCanExpand +--- + +# Function: row\_getCanExpand() + +```ts +function row_getCanExpand(row): boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:172](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L172) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/row_getCanMultiSelect.md b/docs/reference/functions/row_getCanMultiSelect.md new file mode 100644 index 0000000000..8c085c1655 --- /dev/null +++ b/docs/reference/functions/row_getCanMultiSelect.md @@ -0,0 +1,32 @@ +--- +id: row_getCanMultiSelect +title: row_getCanMultiSelect +--- + +# Function: row\_getCanMultiSelect() + +```ts +function row_getCanMultiSelect(row): boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:319](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L319) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/row_getCanPin.md b/docs/reference/functions/row_getCanPin.md new file mode 100644 index 0000000000..ca15bec473 --- /dev/null +++ b/docs/reference/functions/row_getCanPin.md @@ -0,0 +1,32 @@ +--- +id: row_getCanPin +title: row_getCanPin +--- + +# Function: row\_getCanPin() + +```ts +function row_getCanPin(row): boolean; +``` + +Defined in: [features/row-pinning/rowPinningFeature.utils.ts:119](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.utils.ts#L119) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/row_getCanSelect.md b/docs/reference/functions/row_getCanSelect.md new file mode 100644 index 0000000000..8abbd6f102 --- /dev/null +++ b/docs/reference/functions/row_getCanSelect.md @@ -0,0 +1,32 @@ +--- +id: row_getCanSelect +title: row_getCanSelect +--- + +# Function: row\_getCanSelect() + +```ts +function row_getCanSelect(row): boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:295](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L295) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/row_getCanSelectSubRows.md b/docs/reference/functions/row_getCanSelectSubRows.md new file mode 100644 index 0000000000..723f0fb9b5 --- /dev/null +++ b/docs/reference/functions/row_getCanSelectSubRows.md @@ -0,0 +1,32 @@ +--- +id: row_getCanSelectSubRows +title: row_getCanSelectSubRows +--- + +# Function: row\_getCanSelectSubRows() + +```ts +function row_getCanSelectSubRows(row): boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:307](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L307) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/row_getCenterVisibleCells.md b/docs/reference/functions/row_getCenterVisibleCells.md new file mode 100644 index 0000000000..1af5e97b28 --- /dev/null +++ b/docs/reference/functions/row_getCenterVisibleCells.md @@ -0,0 +1,32 @@ +--- +id: row_getCenterVisibleCells +title: row_getCenterVisibleCells +--- + +# Function: row\_getCenterVisibleCells() + +```ts +function row_getCenterVisibleCells(row): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:118](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L118) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`any`[] diff --git a/docs/reference/functions/row_getGroupingValue.md b/docs/reference/functions/row_getGroupingValue.md new file mode 100644 index 0000000000..f665b1d53b --- /dev/null +++ b/docs/reference/functions/row_getGroupingValue.md @@ -0,0 +1,43 @@ +--- +id: row_getGroupingValue +title: row_getGroupingValue +--- + +# Function: row\_getGroupingValue() + +```ts +function row_getGroupingValue(row, columnId): any; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:137](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L137) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row_Core`](../interfaces/Row_Core.md)\<`TFeatures`, `TData`\> & [`UnionToIntersection`](../type-aliases/UnionToIntersection.md)\< + \| `"columnFilteringFeature"` *extends* keyof `TFeatures` ? [`Row_ColumnFiltering`](../interfaces/Row_ColumnFiltering.md)\<`TFeatures`, `TData`\> : `never` + \| `"columnGroupingFeature"` *extends* keyof `TFeatures` ? [`Row_ColumnGrouping`](../interfaces/Row_ColumnGrouping.md) : `never` + \| `"columnPinningFeature"` *extends* keyof `TFeatures` ? [`Row_ColumnPinning`](../interfaces/Row_ColumnPinning.md)\<`TFeatures`, `TData`\> : `never` + \| `"columnVisibilityFeature"` *extends* keyof `TFeatures` ? [`Row_ColumnVisibility`](../interfaces/Row_ColumnVisibility.md)\<`TFeatures`, `TData`\> : `never` + \| `"rowExpandingFeature"` *extends* keyof `TFeatures` ? [`Row_RowExpanding`](../interfaces/Row_RowExpanding.md) : `never` + \| `"rowPinningFeature"` *extends* keyof `TFeatures` ? [`Row_RowPinning`](../interfaces/Row_RowPinning.md) : `never` + \| `"rowSelectionFeature"` *extends* keyof `TFeatures` ? [`Row_RowSelection`](../interfaces/Row_RowSelection.md) : `never`\> & [`UnionToIntersection`](../type-aliases/UnionToIntersection.md)\<\{ \[K in string \| number \| symbol\]: TFeatures\[K\] extends TableFeature\ ? "Row" extends keyof FeatureConstructorOptions ? FeatureConstructorOptions\[keyof FeatureConstructorOptions & "Row"\] : never : any \}\[keyof `TFeatures`\]\> & [`Row_Plugins`](../interfaces/Row_Plugins.md)\<`TFeatures`, `TData`\> & `Partial`\<[`Row_ColumnGrouping`](../interfaces/Row_ColumnGrouping.md)\> + +### columnId + +`string` + +## Returns + +`any` diff --git a/docs/reference/functions/row_getIsAllParentsExpanded.md b/docs/reference/functions/row_getIsAllParentsExpanded.md new file mode 100644 index 0000000000..d467263217 --- /dev/null +++ b/docs/reference/functions/row_getIsAllParentsExpanded.md @@ -0,0 +1,32 @@ +--- +id: row_getIsAllParentsExpanded +title: row_getIsAllParentsExpanded +--- + +# Function: row\_getIsAllParentsExpanded() + +```ts +function row_getIsAllParentsExpanded(row): boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:182](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L182) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/row_getIsAllSubRowsSelected.md b/docs/reference/functions/row_getIsAllSubRowsSelected.md new file mode 100644 index 0000000000..cedddf3b13 --- /dev/null +++ b/docs/reference/functions/row_getIsAllSubRowsSelected.md @@ -0,0 +1,32 @@ +--- +id: row_getIsAllSubRowsSelected +title: row_getIsAllSubRowsSelected +--- + +# Function: row\_getIsAllSubRowsSelected() + +```ts +function row_getIsAllSubRowsSelected(row): boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:288](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L288) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/row_getIsExpanded.md b/docs/reference/functions/row_getIsExpanded.md new file mode 100644 index 0000000000..7b2e324adb --- /dev/null +++ b/docs/reference/functions/row_getIsExpanded.md @@ -0,0 +1,32 @@ +--- +id: row_getIsExpanded +title: row_getIsExpanded +--- + +# Function: row\_getIsExpanded() + +```ts +function row_getIsExpanded(row): boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:160](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L160) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/row_getIsGrouped.md b/docs/reference/functions/row_getIsGrouped.md new file mode 100644 index 0000000000..b50ea63062 --- /dev/null +++ b/docs/reference/functions/row_getIsGrouped.md @@ -0,0 +1,39 @@ +--- +id: row_getIsGrouped +title: row_getIsGrouped +--- + +# Function: row\_getIsGrouped() + +```ts +function row_getIsGrouped(row): boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:130](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L130) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row_Core`](../interfaces/Row_Core.md)\<`TFeatures`, `TData`\> & [`UnionToIntersection`](../type-aliases/UnionToIntersection.md)\< + \| `"columnFilteringFeature"` *extends* keyof `TFeatures` ? [`Row_ColumnFiltering`](../interfaces/Row_ColumnFiltering.md)\<`TFeatures`, `TData`\> : `never` + \| `"columnGroupingFeature"` *extends* keyof `TFeatures` ? [`Row_ColumnGrouping`](../interfaces/Row_ColumnGrouping.md) : `never` + \| `"columnPinningFeature"` *extends* keyof `TFeatures` ? [`Row_ColumnPinning`](../interfaces/Row_ColumnPinning.md)\<`TFeatures`, `TData`\> : `never` + \| `"columnVisibilityFeature"` *extends* keyof `TFeatures` ? [`Row_ColumnVisibility`](../interfaces/Row_ColumnVisibility.md)\<`TFeatures`, `TData`\> : `never` + \| `"rowExpandingFeature"` *extends* keyof `TFeatures` ? [`Row_RowExpanding`](../interfaces/Row_RowExpanding.md) : `never` + \| `"rowPinningFeature"` *extends* keyof `TFeatures` ? [`Row_RowPinning`](../interfaces/Row_RowPinning.md) : `never` + \| `"rowSelectionFeature"` *extends* keyof `TFeatures` ? [`Row_RowSelection`](../interfaces/Row_RowSelection.md) : `never`\> & [`UnionToIntersection`](../type-aliases/UnionToIntersection.md)\<\{ \[K in string \| number \| symbol\]: TFeatures\[K\] extends TableFeature\ ? "Row" extends keyof FeatureConstructorOptions ? FeatureConstructorOptions\[keyof FeatureConstructorOptions & "Row"\] : never : any \}\[keyof `TFeatures`\]\> & [`Row_Plugins`](../interfaces/Row_Plugins.md)\<`TFeatures`, `TData`\> & `Partial`\<[`Row_ColumnGrouping`](../interfaces/Row_ColumnGrouping.md)\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/row_getIsPinned.md b/docs/reference/functions/row_getIsPinned.md new file mode 100644 index 0000000000..808317d1d4 --- /dev/null +++ b/docs/reference/functions/row_getIsPinned.md @@ -0,0 +1,32 @@ +--- +id: row_getIsPinned +title: row_getIsPinned +--- + +# Function: row\_getIsPinned() + +```ts +function row_getIsPinned(row): RowPinningPosition; +``` + +Defined in: [features/row-pinning/rowPinningFeature.utils.ts:130](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.utils.ts#L130) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowPinningPosition`](../type-aliases/RowPinningPosition.md) diff --git a/docs/reference/functions/row_getIsSelected.md b/docs/reference/functions/row_getIsSelected.md new file mode 100644 index 0000000000..365338394a --- /dev/null +++ b/docs/reference/functions/row_getIsSelected.md @@ -0,0 +1,32 @@ +--- +id: row_getIsSelected +title: row_getIsSelected +--- + +# Function: row\_getIsSelected() + +```ts +function row_getIsSelected(row): boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:274](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L274) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/row_getIsSomeSelected.md b/docs/reference/functions/row_getIsSomeSelected.md new file mode 100644 index 0000000000..44be8b91b7 --- /dev/null +++ b/docs/reference/functions/row_getIsSomeSelected.md @@ -0,0 +1,32 @@ +--- +id: row_getIsSomeSelected +title: row_getIsSomeSelected +--- + +# Function: row\_getIsSomeSelected() + +```ts +function row_getIsSomeSelected(row): boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:281](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L281) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/row_getLeafRows.md b/docs/reference/functions/row_getLeafRows.md new file mode 100644 index 0000000000..3f80aefab9 --- /dev/null +++ b/docs/reference/functions/row_getLeafRows.md @@ -0,0 +1,32 @@ +--- +id: row_getLeafRows +title: row_getLeafRows +--- + +# Function: row\_getLeafRows() + +```ts +function row_getLeafRows(row): Row[]; +``` + +Defined in: [core/rows/coreRowsFeature.utils.ts:62](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L62) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] diff --git a/docs/reference/functions/row_getLeftVisibleCells.md b/docs/reference/functions/row_getLeftVisibleCells.md new file mode 100644 index 0000000000..30cc8f5d60 --- /dev/null +++ b/docs/reference/functions/row_getLeftVisibleCells.md @@ -0,0 +1,32 @@ +--- +id: row_getLeftVisibleCells +title: row_getLeftVisibleCells +--- + +# Function: row\_getLeftVisibleCells() + +```ts +function row_getLeftVisibleCells(row): Cell[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:133](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L133) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/row_getParentRow.md b/docs/reference/functions/row_getParentRow.md new file mode 100644 index 0000000000..1a864d7127 --- /dev/null +++ b/docs/reference/functions/row_getParentRow.md @@ -0,0 +1,32 @@ +--- +id: row_getParentRow +title: row_getParentRow +--- + +# Function: row\_getParentRow() + +```ts +function row_getParentRow(row): Row | undefined; +``` + +Defined in: [core/rows/coreRowsFeature.utils.ts:69](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L69) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> \| `undefined` diff --git a/docs/reference/functions/row_getParentRows.md b/docs/reference/functions/row_getParentRows.md new file mode 100644 index 0000000000..04f0151e1d --- /dev/null +++ b/docs/reference/functions/row_getParentRows.md @@ -0,0 +1,32 @@ +--- +id: row_getParentRows +title: row_getParentRows +--- + +# Function: row\_getParentRows() + +```ts +function row_getParentRows(row): Row[]; +``` + +Defined in: [core/rows/coreRowsFeature.utils.ts:76](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L76) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] diff --git a/docs/reference/functions/row_getPinnedIndex.md b/docs/reference/functions/row_getPinnedIndex.md new file mode 100644 index 0000000000..8afb2f381f --- /dev/null +++ b/docs/reference/functions/row_getPinnedIndex.md @@ -0,0 +1,32 @@ +--- +id: row_getPinnedIndex +title: row_getPinnedIndex +--- + +# Function: row\_getPinnedIndex() + +```ts +function row_getPinnedIndex(row): number; +``` + +Defined in: [features/row-pinning/rowPinningFeature.utils.ts:144](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.utils.ts#L144) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`number` diff --git a/docs/reference/functions/row_getRightVisibleCells.md b/docs/reference/functions/row_getRightVisibleCells.md new file mode 100644 index 0000000000..8e76ff1cd0 --- /dev/null +++ b/docs/reference/functions/row_getRightVisibleCells.md @@ -0,0 +1,32 @@ +--- +id: row_getRightVisibleCells +title: row_getRightVisibleCells +--- + +# Function: row\_getRightVisibleCells() + +```ts +function row_getRightVisibleCells(row): any; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:154](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L154) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`any` diff --git a/docs/reference/functions/row_getToggleExpandedHandler.md b/docs/reference/functions/row_getToggleExpandedHandler.md new file mode 100644 index 0000000000..63f7a760e6 --- /dev/null +++ b/docs/reference/functions/row_getToggleExpandedHandler.md @@ -0,0 +1,38 @@ +--- +id: row_getToggleExpandedHandler +title: row_getToggleExpandedHandler +--- + +# Function: row\_getToggleExpandedHandler() + +```ts +function row_getToggleExpandedHandler(row): () => void; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:197](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L197) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +```ts +(): void; +``` + +### Returns + +`void` diff --git a/docs/reference/functions/row_getToggleSelectedHandler.md b/docs/reference/functions/row_getToggleSelectedHandler.md new file mode 100644 index 0000000000..40f35c4694 --- /dev/null +++ b/docs/reference/functions/row_getToggleSelectedHandler.md @@ -0,0 +1,44 @@ +--- +id: row_getToggleSelectedHandler +title: row_getToggleSelectedHandler +--- + +# Function: row\_getToggleSelectedHandler() + +```ts +function row_getToggleSelectedHandler(row): (e) => void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:331](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L331) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +```ts +(e): void; +``` + +### Parameters + +#### e + +`unknown` + +### Returns + +`void` diff --git a/docs/reference/functions/row_getUniqueValues.md b/docs/reference/functions/row_getUniqueValues.md new file mode 100644 index 0000000000..8a3798ef16 --- /dev/null +++ b/docs/reference/functions/row_getUniqueValues.md @@ -0,0 +1,36 @@ +--- +id: row_getUniqueValues +title: row_getUniqueValues +--- + +# Function: row\_getUniqueValues() + +```ts +function row_getUniqueValues(row, columnId): unknown; +``` + +Defined in: [core/rows/coreRowsFeature.utils.ts:28](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L28) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +### columnId + +`string` + +## Returns + +`unknown` diff --git a/docs/reference/functions/row_getValue.md b/docs/reference/functions/row_getValue.md new file mode 100644 index 0000000000..8b0b76acfb --- /dev/null +++ b/docs/reference/functions/row_getValue.md @@ -0,0 +1,36 @@ +--- +id: row_getValue +title: row_getValue +--- + +# Function: row\_getValue() + +```ts +function row_getValue(row, columnId): unknown; +``` + +Defined in: [core/rows/coreRowsFeature.utils.ts:9](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L9) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +### columnId + +`string` + +## Returns + +`unknown` diff --git a/docs/reference/functions/row_getVisibleCells.md b/docs/reference/functions/row_getVisibleCells.md new file mode 100644 index 0000000000..8db6cd77b3 --- /dev/null +++ b/docs/reference/functions/row_getVisibleCells.md @@ -0,0 +1,43 @@ +--- +id: row_getVisibleCells +title: row_getVisibleCells +--- + +# Function: row\_getVisibleCells() + +```ts +function row_getVisibleCells( + left, + center, + right): Cell[]; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:79](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L79) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### left + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>[] + +### center + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>[] + +### right + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>[] + +## Returns + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/row_pin.md b/docs/reference/functions/row_pin.md new file mode 100644 index 0000000000..5b692e2b2c --- /dev/null +++ b/docs/reference/functions/row_pin.md @@ -0,0 +1,48 @@ +--- +id: row_pin +title: row_pin +--- + +# Function: row\_pin() + +```ts +function row_pin( + row, + position, + includeLeafRows?, + includeParentRows?): void; +``` + +Defined in: [features/row-pinning/rowPinningFeature.utils.ts:160](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.utils.ts#L160) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +### position + +[`RowPinningPosition`](../type-aliases/RowPinningPosition.md) + +### includeLeafRows? + +`boolean` + +### includeParentRows? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/row_renderValue.md b/docs/reference/functions/row_renderValue.md new file mode 100644 index 0000000000..7f81dcf762 --- /dev/null +++ b/docs/reference/functions/row_renderValue.md @@ -0,0 +1,36 @@ +--- +id: row_renderValue +title: row_renderValue +--- + +# Function: row\_renderValue() + +```ts +function row_renderValue(row, columnId): any; +``` + +Defined in: [core/rows/coreRowsFeature.utils.ts:55](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L55) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +### columnId + +`string` + +## Returns + +`any` diff --git a/docs/reference/functions/row_toggleExpanded.md b/docs/reference/functions/row_toggleExpanded.md new file mode 100644 index 0000000000..82e29ac378 --- /dev/null +++ b/docs/reference/functions/row_toggleExpanded.md @@ -0,0 +1,36 @@ +--- +id: row_toggleExpanded +title: row_toggleExpanded +--- + +# Function: row\_toggleExpanded() + +```ts +function row_toggleExpanded(row, expanded?): void; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:125](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L125) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +### expanded? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/row_toggleSelected.md b/docs/reference/functions/row_toggleSelected.md new file mode 100644 index 0000000000..d812cae9a1 --- /dev/null +++ b/docs/reference/functions/row_toggleSelected.md @@ -0,0 +1,45 @@ +--- +id: row_toggleSelected +title: row_toggleSelected +--- + +# Function: row\_toggleSelected() + +```ts +function row_toggleSelected( + row, + value?, + opts?): void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:241](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L241) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +### value? + +`boolean` + +### opts? + +#### selectChildren? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/selectRowsFn.md b/docs/reference/functions/selectRowsFn.md new file mode 100644 index 0000000000..81c72ba780 --- /dev/null +++ b/docs/reference/functions/selectRowsFn.md @@ -0,0 +1,32 @@ +--- +id: selectRowsFn +title: selectRowsFn +--- + +# Function: selectRowsFn() + +```ts +function selectRowsFn(rowModel): RowModel; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:376](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L376) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### rowModel + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/shouldAutoRemoveFilter.md b/docs/reference/functions/shouldAutoRemoveFilter.md new file mode 100644 index 0000000000..06d3fd1d4e --- /dev/null +++ b/docs/reference/functions/shouldAutoRemoveFilter.md @@ -0,0 +1,47 @@ +--- +id: shouldAutoRemoveFilter +title: shouldAutoRemoveFilter +--- + +# Function: shouldAutoRemoveFilter() + +```ts +function shouldAutoRemoveFilter( + filterFn?, + value?, + column?): boolean; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.utils.ts:194](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.utils.ts#L194) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* `unknown` = `unknown` + +## Parameters + +### filterFn? + +[`FilterFn`](../interfaces/FilterFn.md)\<`TFeatures`, `TData`\> + +### value? + +`any` + +### column? + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/tableFeatures.md b/docs/reference/functions/tableFeatures.md new file mode 100644 index 0000000000..1b0a5c8cd1 --- /dev/null +++ b/docs/reference/functions/tableFeatures.md @@ -0,0 +1,40 @@ +--- +id: tableFeatures +title: tableFeatures +--- + +# Function: tableFeatures() + +```ts +function tableFeatures(features): TFeatures; +``` + +Defined in: [helpers/tableFeatures.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableFeatures.ts#L14) + +A helper function to help define the features that are to be imported and applied to a table instance. +Use this utility to make it easier to have the correct type inference for the features that are being imported. +**Note:** It is recommended to use this utility statically outside of a component. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +## Parameters + +### features + +`TFeatures` + +## Returns + +`TFeatures` + +## Example + +``` +import { tableFeatures, columnVisibilityFeature, rowPinningFeature } from '@tanstack/react-table' +const _features = tableFeatures({ columnVisibilityFeature, rowPinningFeature }); +const table = useTable({ _features, rowModels: {}, columns, data }); +``` diff --git a/docs/reference/functions/tableMemo.md b/docs/reference/functions/tableMemo.md new file mode 100644 index 0000000000..c84ceb09a7 --- /dev/null +++ b/docs/reference/functions/tableMemo.md @@ -0,0 +1,52 @@ +--- +id: tableMemo +title: tableMemo +--- + +# Function: tableMemo() + +```ts +function tableMemo(__namedParameters): (depArgs?) => TResult; +``` + +Defined in: [utils.ts:148](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L148) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TDeps + +`TDeps` *extends* readonly `any`[] + +### TDepArgs + +`TDepArgs` + +### TResult + +`TResult` + +## Parameters + +### \_\_namedParameters + +`TableMemoOptions`\<`TFeatures`, `TDeps`, `TDepArgs`, `TResult`\> + +## Returns + +```ts +(depArgs?): TResult; +``` + +### Parameters + +#### depArgs? + +`TDepArgs` + +### Returns + +`TResult` diff --git a/docs/reference/functions/tableOptions.md b/docs/reference/functions/tableOptions.md new file mode 100644 index 0000000000..46944ecc2d --- /dev/null +++ b/docs/reference/functions/tableOptions.md @@ -0,0 +1,230 @@ +--- +id: tableOptions +title: tableOptions +--- + +# Function: tableOptions() + +## Call Signature + +```ts +function tableOptions(options): Omit, "_features" | "columns"> & object; +``` + +Defined in: [helpers/tableOptions.ts:5](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableOptions.ts#L5) + +### Type Parameters + +#### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +#### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +### Parameters + +#### options + +`Omit`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>, `"columns"`\> & `object` + +### Returns + +`Omit`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>, `"_features"` \| `"columns"`\> & `object` + +## Call Signature + +```ts +function tableOptions(options): Omit, "_features" | "data"> & object; +``` + +Defined in: [helpers/tableOptions.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableOptions.ts#L16) + +### Type Parameters + +#### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +#### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +### Parameters + +#### options + +`Omit`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>, `"data"`\> & `object` + +### Returns + +`Omit`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>, `"_features"` \| `"data"`\> & `object` + +## Call Signature + +```ts +function tableOptions(options): Omit, "_features">; +``` + +Defined in: [helpers/tableOptions.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableOptions.ts#L27) + +### Type Parameters + +#### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +#### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +### Parameters + +#### options + +`Omit`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>, `"_features"`\> + +### Returns + +`Omit`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>, `"_features"`\> + +## Call Signature + +```ts +function tableOptions(options): Omit, "_features" | "data" | "columns"> & object; +``` + +Defined in: [helpers/tableOptions.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableOptions.ts#L34) + +### Type Parameters + +#### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +#### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +### Parameters + +#### options + +`Omit`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>, `"data"` \| `"columns"`\> & `object` + +### Returns + +`Omit`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>, `"_features"` \| `"data"` \| `"columns"`\> & `object` + +## Call Signature + +```ts +function tableOptions(options): Omit, "data" | "_features">; +``` + +Defined in: [helpers/tableOptions.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableOptions.ts#L45) + +### Type Parameters + +#### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +#### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +### Parameters + +#### options + +`Omit`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>, `"data"` \| `"_features"`\> + +### Returns + +`Omit`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>, `"data"` \| `"_features"`\> + +## Call Signature + +```ts +function tableOptions(options): Omit, "columns" | "_features">; +``` + +Defined in: [helpers/tableOptions.ts:52](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableOptions.ts#L52) + +### Type Parameters + +#### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +#### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +### Parameters + +#### options + +`Omit`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>, `"columns"` \| `"_features"`\> + +### Returns + +`Omit`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>, `"columns"` \| `"_features"`\> + +## Call Signature + +```ts +function tableOptions(options): Omit, "data" | "columns" | "_features">; +``` + +Defined in: [helpers/tableOptions.ts:59](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableOptions.ts#L59) + +### Type Parameters + +#### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +#### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +### Parameters + +#### options + +`Omit`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>, `"data"` \| `"columns"` \| `"_features"`\> + +### Returns + +`Omit`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>, `"data"` \| `"columns"` \| `"_features"`\> + +## Call Signature + +```ts +function tableOptions(options): TableOptions; +``` + +Defined in: [helpers/tableOptions.ts:69](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableOptions.ts#L69) + +### Type Parameters + +#### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +#### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) = `any` + +### Parameters + +#### options + +[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\> + +### Returns + +[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_autoResetExpanded.md b/docs/reference/functions/table_autoResetExpanded.md new file mode 100644 index 0000000000..dd6be0c731 --- /dev/null +++ b/docs/reference/functions/table_autoResetExpanded.md @@ -0,0 +1,32 @@ +--- +id: table_autoResetExpanded +title: table_autoResetExpanded +--- + +# Function: table\_autoResetExpanded() + +```ts +function table_autoResetExpanded(table): void; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L14) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_autoResetPageIndex.md b/docs/reference/functions/table_autoResetPageIndex.md new file mode 100644 index 0000000000..2fe5a61126 --- /dev/null +++ b/docs/reference/functions/table_autoResetPageIndex.md @@ -0,0 +1,32 @@ +--- +id: table_autoResetPageIndex +title: table_autoResetPageIndex +--- + +# Function: table\_autoResetPageIndex() + +```ts +function table_autoResetPageIndex(table): void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L17) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_firstPage.md b/docs/reference/functions/table_firstPage.md new file mode 100644 index 0000000000..c9c9edca1b --- /dev/null +++ b/docs/reference/functions/table_firstPage.md @@ -0,0 +1,32 @@ +--- +id: table_firstPage +title: table_firstPage +--- + +# Function: table\_firstPage() + +```ts +function table_firstPage(table): void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:172](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L172) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_getAllColumns.md b/docs/reference/functions/table_getAllColumns.md new file mode 100644 index 0000000000..3262d7014e --- /dev/null +++ b/docs/reference/functions/table_getAllColumns.md @@ -0,0 +1,32 @@ +--- +id: table_getAllColumns +title: table_getAllColumns +--- + +# Function: table\_getAllColumns() + +```ts +function table_getAllColumns(table): Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.utils.ts:75](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.utils.ts#L75) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/table_getAllFlatColumns.md b/docs/reference/functions/table_getAllFlatColumns.md new file mode 100644 index 0000000000..05f9b41efa --- /dev/null +++ b/docs/reference/functions/table_getAllFlatColumns.md @@ -0,0 +1,32 @@ +--- +id: table_getAllFlatColumns +title: table_getAllFlatColumns +--- + +# Function: table\_getAllFlatColumns() + +```ts +function table_getAllFlatColumns(table): Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.utils.ts:106](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.utils.ts#L106) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/table_getAllFlatColumnsById.md b/docs/reference/functions/table_getAllFlatColumnsById.md new file mode 100644 index 0000000000..f8824493cc --- /dev/null +++ b/docs/reference/functions/table_getAllFlatColumnsById.md @@ -0,0 +1,32 @@ +--- +id: table_getAllFlatColumnsById +title: table_getAllFlatColumnsById +--- + +# Function: table\_getAllFlatColumnsById() + +```ts +function table_getAllFlatColumnsById(table): Record>; +``` + +Defined in: [core/columns/coreColumnsFeature.utils.ts:115](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.utils.ts#L115) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`Record`\<`string`, [`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>\> diff --git a/docs/reference/functions/table_getAllLeafColumns.md b/docs/reference/functions/table_getAllLeafColumns.md new file mode 100644 index 0000000000..99da39c0b7 --- /dev/null +++ b/docs/reference/functions/table_getAllLeafColumns.md @@ -0,0 +1,32 @@ +--- +id: table_getAllLeafColumns +title: table_getAllLeafColumns +--- + +# Function: table\_getAllLeafColumns() + +```ts +function table_getAllLeafColumns(table): Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.utils.ts:130](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.utils.ts#L130) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/table_getBottomRows.md b/docs/reference/functions/table_getBottomRows.md new file mode 100644 index 0000000000..7aa3adfd74 --- /dev/null +++ b/docs/reference/functions/table_getBottomRows.md @@ -0,0 +1,32 @@ +--- +id: table_getBottomRows +title: table_getBottomRows +--- + +# Function: table\_getBottomRows() + +```ts +function table_getBottomRows(table): Row[]; +``` + +Defined in: [features/row-pinning/rowPinningFeature.utils.ts:98](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.utils.ts#L98) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] diff --git a/docs/reference/functions/table_getCanNextPage.md b/docs/reference/functions/table_getCanNextPage.md new file mode 100644 index 0000000000..c73e8f1e42 --- /dev/null +++ b/docs/reference/functions/table_getCanNextPage.md @@ -0,0 +1,32 @@ +--- +id: table_getCanNextPage +title: table_getCanNextPage +--- + +# Function: table\_getCanNextPage() + +```ts +function table_getCanNextPage(table): boolean; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:137](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L137) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/table_getCanPreviousPage.md b/docs/reference/functions/table_getCanPreviousPage.md new file mode 100644 index 0000000000..e54fcb4a1c --- /dev/null +++ b/docs/reference/functions/table_getCanPreviousPage.md @@ -0,0 +1,32 @@ +--- +id: table_getCanPreviousPage +title: table_getCanPreviousPage +--- + +# Function: table\_getCanPreviousPage() + +```ts +function table_getCanPreviousPage(table): boolean; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:130](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L130) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/table_getCanSomeRowsExpand.md b/docs/reference/functions/table_getCanSomeRowsExpand.md new file mode 100644 index 0000000000..490ba549a3 --- /dev/null +++ b/docs/reference/functions/table_getCanSomeRowsExpand.md @@ -0,0 +1,32 @@ +--- +id: table_getCanSomeRowsExpand +title: table_getCanSomeRowsExpand +--- + +# Function: table\_getCanSomeRowsExpand() + +```ts +function table_getCanSomeRowsExpand(table): boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:55](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L55) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/table_getCenterFlatHeaders.md b/docs/reference/functions/table_getCenterFlatHeaders.md new file mode 100644 index 0000000000..ce24cd11a3 --- /dev/null +++ b/docs/reference/functions/table_getCenterFlatHeaders.md @@ -0,0 +1,32 @@ +--- +id: table_getCenterFlatHeaders +title: table_getCenterFlatHeaders +--- + +# Function: table\_getCenterFlatHeaders() + +```ts +function table_getCenterFlatHeaders(table): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:347](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L347) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getCenterFooterGroups.md b/docs/reference/functions/table_getCenterFooterGroups.md new file mode 100644 index 0000000000..9cc6033926 --- /dev/null +++ b/docs/reference/functions/table_getCenterFooterGroups.md @@ -0,0 +1,32 @@ +--- +id: table_getCenterFooterGroups +title: table_getCenterFooterGroups +--- + +# Function: table\_getCenterFooterGroups() + +```ts +function table_getCenterFooterGroups(table): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:301](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L301) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getCenterHeaderGroups.md b/docs/reference/functions/table_getCenterHeaderGroups.md new file mode 100644 index 0000000000..7f0deb46c2 --- /dev/null +++ b/docs/reference/functions/table_getCenterHeaderGroups.md @@ -0,0 +1,32 @@ +--- +id: table_getCenterHeaderGroups +title: table_getCenterHeaderGroups +--- + +# Function: table\_getCenterHeaderGroups() + +```ts +function table_getCenterHeaderGroups(table): HeaderGroup[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:253](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L253) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`HeaderGroup`](../type-aliases/HeaderGroup.md)\<`TFeatures`, `TData`\>[] diff --git a/docs/reference/functions/table_getCenterLeafColumns.md b/docs/reference/functions/table_getCenterLeafColumns.md new file mode 100644 index 0000000000..7e9fde45b1 --- /dev/null +++ b/docs/reference/functions/table_getCenterLeafColumns.md @@ -0,0 +1,32 @@ +--- +id: table_getCenterLeafColumns +title: table_getCenterLeafColumns +--- + +# Function: table\_getCenterLeafColumns() + +```ts +function table_getCenterLeafColumns(table): Column[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:428](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L428) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/table_getCenterLeafHeaders.md b/docs/reference/functions/table_getCenterLeafHeaders.md new file mode 100644 index 0000000000..386bf7cc48 --- /dev/null +++ b/docs/reference/functions/table_getCenterLeafHeaders.md @@ -0,0 +1,32 @@ +--- +id: table_getCenterLeafHeaders +title: table_getCenterLeafHeaders +--- + +# Function: table\_getCenterLeafHeaders() + +```ts +function table_getCenterLeafHeaders(table): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:387](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L387) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getCenterRows.md b/docs/reference/functions/table_getCenterRows.md new file mode 100644 index 0000000000..e45da10c5a --- /dev/null +++ b/docs/reference/functions/table_getCenterRows.md @@ -0,0 +1,32 @@ +--- +id: table_getCenterRows +title: table_getCenterRows +--- + +# Function: table\_getCenterRows() + +```ts +function table_getCenterRows(table): Row[]; +``` + +Defined in: [features/row-pinning/rowPinningFeature.utils.ts:105](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.utils.ts#L105) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] diff --git a/docs/reference/functions/table_getCenterTotalSize.md b/docs/reference/functions/table_getCenterTotalSize.md new file mode 100644 index 0000000000..0c48b509cc --- /dev/null +++ b/docs/reference/functions/table_getCenterTotalSize.md @@ -0,0 +1,32 @@ +--- +id: table_getCenterTotalSize +title: table_getCenterTotalSize +--- + +# Function: table\_getCenterTotalSize() + +```ts +function table_getCenterTotalSize(table): any; +``` + +Defined in: [features/column-sizing/columnSizingFeature.utils.ts:183](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.utils.ts#L183) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any` diff --git a/docs/reference/functions/table_getCenterVisibleLeafColumns.md b/docs/reference/functions/table_getCenterVisibleLeafColumns.md new file mode 100644 index 0000000000..fdeeef1102 --- /dev/null +++ b/docs/reference/functions/table_getCenterVisibleLeafColumns.md @@ -0,0 +1,32 @@ +--- +id: table_getCenterVisibleLeafColumns +title: table_getCenterVisibleLeafColumns +--- + +# Function: table\_getCenterVisibleLeafColumns() + +```ts +function table_getCenterVisibleLeafColumns(table): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:494](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L494) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getColumn.md b/docs/reference/functions/table_getColumn.md new file mode 100644 index 0000000000..739efd2ccc --- /dev/null +++ b/docs/reference/functions/table_getColumn.md @@ -0,0 +1,39 @@ +--- +id: table_getColumn +title: table_getColumn +--- + +# Function: table\_getColumn() + +```ts +function table_getColumn(table, columnId): + | Column + | undefined; +``` + +Defined in: [core/columns/coreColumnsFeature.utils.ts:146](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.utils.ts#L146) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### columnId + +`string` + +## Returns + + \| [`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\> + \| `undefined` diff --git a/docs/reference/functions/table_getCoreRowModel.md b/docs/reference/functions/table_getCoreRowModel.md new file mode 100644 index 0000000000..012c6b3ace --- /dev/null +++ b/docs/reference/functions/table_getCoreRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getCoreRowModel +title: table_getCoreRowModel +--- + +# Function: table\_getCoreRowModel() + +```ts +function table_getCoreRowModel(table): RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.utils.ts:7](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.utils.ts#L7) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getDefaultColumnDef.md b/docs/reference/functions/table_getDefaultColumnDef.md new file mode 100644 index 0000000000..32760590af --- /dev/null +++ b/docs/reference/functions/table_getDefaultColumnDef.md @@ -0,0 +1,32 @@ +--- +id: table_getDefaultColumnDef +title: table_getDefaultColumnDef +--- + +# Function: table\_getDefaultColumnDef() + +```ts +function table_getDefaultColumnDef(table): Partial>; +``` + +Defined in: [core/columns/coreColumnsFeature.utils.ts:46](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.utils.ts#L46) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`Partial`\<[`ColumnDef`](../type-aliases/ColumnDef.md)\<`TFeatures`, `TData`, `unknown`\>\> diff --git a/docs/reference/functions/table_getExpandedDepth.md b/docs/reference/functions/table_getExpandedDepth.md new file mode 100644 index 0000000000..b91886b413 --- /dev/null +++ b/docs/reference/functions/table_getExpandedDepth.md @@ -0,0 +1,32 @@ +--- +id: table_getExpandedDepth +title: table_getExpandedDepth +--- + +# Function: table\_getExpandedDepth() + +```ts +function table_getExpandedDepth(table): number; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:106](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L106) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`number` diff --git a/docs/reference/functions/table_getExpandedRowModel.md b/docs/reference/functions/table_getExpandedRowModel.md new file mode 100644 index 0000000000..c6d0715b72 --- /dev/null +++ b/docs/reference/functions/table_getExpandedRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getExpandedRowModel +title: table_getExpandedRowModel +--- + +# Function: table\_getExpandedRowModel() + +```ts +function table_getExpandedRowModel(table): RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.utils.ts:96](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.utils.ts#L96) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getFilteredRowModel.md b/docs/reference/functions/table_getFilteredRowModel.md new file mode 100644 index 0000000000..82278c50a5 --- /dev/null +++ b/docs/reference/functions/table_getFilteredRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getFilteredRowModel +title: table_getFilteredRowModel +--- + +# Function: table\_getFilteredRowModel() + +```ts +function table_getFilteredRowModel(table): RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.utils.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.utils.ts#L27) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getFilteredSelectedRowModel.md b/docs/reference/functions/table_getFilteredSelectedRowModel.md new file mode 100644 index 0000000000..0b3bf2522e --- /dev/null +++ b/docs/reference/functions/table_getFilteredSelectedRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getFilteredSelectedRowModel +title: table_getFilteredSelectedRowModel +--- + +# Function: table\_getFilteredSelectedRowModel() + +```ts +function table_getFilteredSelectedRowModel(table): RowModel; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:111](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L111) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getFlatHeaders.md b/docs/reference/functions/table_getFlatHeaders.md new file mode 100644 index 0000000000..60cae4f60d --- /dev/null +++ b/docs/reference/functions/table_getFlatHeaders.md @@ -0,0 +1,32 @@ +--- +id: table_getFlatHeaders +title: table_getFlatHeaders +--- + +# Function: table\_getFlatHeaders() + +```ts +function table_getFlatHeaders(table): Header[]; +``` + +Defined in: [core/headers/coreHeadersFeature.utils.ts:90](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.utils.ts#L90) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/table_getFooterGroups.md b/docs/reference/functions/table_getFooterGroups.md new file mode 100644 index 0000000000..092f380e5f --- /dev/null +++ b/docs/reference/functions/table_getFooterGroups.md @@ -0,0 +1,32 @@ +--- +id: table_getFooterGroups +title: table_getFooterGroups +--- + +# Function: table\_getFooterGroups() + +```ts +function table_getFooterGroups(table): HeaderGroup[]; +``` + +Defined in: [core/headers/coreHeadersFeature.utils.ts:82](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.utils.ts#L82) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`HeaderGroup`](../type-aliases/HeaderGroup.md)\<`TFeatures`, `TData`\>[] diff --git a/docs/reference/functions/table_getGlobalAutoFilterFn.md b/docs/reference/functions/table_getGlobalAutoFilterFn.md new file mode 100644 index 0000000000..1cf7e7816e --- /dev/null +++ b/docs/reference/functions/table_getGlobalAutoFilterFn.md @@ -0,0 +1,16 @@ +--- +id: table_getGlobalAutoFilterFn +title: table_getGlobalAutoFilterFn +--- + +# Function: table\_getGlobalAutoFilterFn() + +```ts +function table_getGlobalAutoFilterFn(): FilterFn; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.utils.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.utils.ts#L23) + +## Returns + +[`FilterFn`](../interfaces/FilterFn.md)\<`any`, `any`\> diff --git a/docs/reference/functions/table_getGlobalFacetedMinMaxValues.md b/docs/reference/functions/table_getGlobalFacetedMinMaxValues.md new file mode 100644 index 0000000000..43b2434a92 --- /dev/null +++ b/docs/reference/functions/table_getGlobalFacetedMinMaxValues.md @@ -0,0 +1,32 @@ +--- +id: table_getGlobalFacetedMinMaxValues +title: table_getGlobalFacetedMinMaxValues +--- + +# Function: table\_getGlobalFacetedMinMaxValues() + +```ts +function table_getGlobalFacetedMinMaxValues(table): [number, number] | undefined; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.utils.ts:49](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.utils.ts#L49) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +\[`number`, `number`\] \| `undefined` diff --git a/docs/reference/functions/table_getGlobalFacetedRowModel.md b/docs/reference/functions/table_getGlobalFacetedRowModel.md new file mode 100644 index 0000000000..dbeaf848bf --- /dev/null +++ b/docs/reference/functions/table_getGlobalFacetedRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getGlobalFacetedRowModel +title: table_getGlobalFacetedRowModel +--- + +# Function: table\_getGlobalFacetedRowModel() + +```ts +function table_getGlobalFacetedRowModel(table): RowModel; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.utils.ts:59](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.utils.ts#L59) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getGlobalFacetedUniqueValues.md b/docs/reference/functions/table_getGlobalFacetedUniqueValues.md new file mode 100644 index 0000000000..ae3dc890cf --- /dev/null +++ b/docs/reference/functions/table_getGlobalFacetedUniqueValues.md @@ -0,0 +1,32 @@ +--- +id: table_getGlobalFacetedUniqueValues +title: table_getGlobalFacetedUniqueValues +--- + +# Function: table\_getGlobalFacetedUniqueValues() + +```ts +function table_getGlobalFacetedUniqueValues(table): Map; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.utils.ts:69](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.utils.ts#L69) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`Map`\<`any`, `number`\> diff --git a/docs/reference/functions/table_getGlobalFilterFn.md b/docs/reference/functions/table_getGlobalFilterFn.md new file mode 100644 index 0000000000..434caadec4 --- /dev/null +++ b/docs/reference/functions/table_getGlobalFilterFn.md @@ -0,0 +1,35 @@ +--- +id: table_getGlobalFilterFn +title: table_getGlobalFilterFn +--- + +# Function: table\_getGlobalFilterFn() + +```ts +function table_getGlobalFilterFn(table): + | FilterFn + | undefined; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.utils.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.utils.ts#L27) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + + \| [`FilterFn`](../interfaces/FilterFn.md)\<`TFeatures`, `TData`\> + \| `undefined` diff --git a/docs/reference/functions/table_getGroupedRowModel.md b/docs/reference/functions/table_getGroupedRowModel.md new file mode 100644 index 0000000000..d550ff834c --- /dev/null +++ b/docs/reference/functions/table_getGroupedRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getGroupedRowModel +title: table_getGroupedRowModel +--- + +# Function: table\_getGroupedRowModel() + +```ts +function table_getGroupedRowModel(table): RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.utils.ts:50](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.utils.ts#L50) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getGroupedSelectedRowModel.md b/docs/reference/functions/table_getGroupedSelectedRowModel.md new file mode 100644 index 0000000000..742ce51198 --- /dev/null +++ b/docs/reference/functions/table_getGroupedSelectedRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getGroupedSelectedRowModel +title: table_getGroupedSelectedRowModel +--- + +# Function: table\_getGroupedSelectedRowModel() + +```ts +function table_getGroupedSelectedRowModel(table): RowModel; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:128](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L128) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getHeaderGroups.md b/docs/reference/functions/table_getHeaderGroups.md new file mode 100644 index 0000000000..caa9b249bd --- /dev/null +++ b/docs/reference/functions/table_getHeaderGroups.md @@ -0,0 +1,32 @@ +--- +id: table_getHeaderGroups +title: table_getHeaderGroups +--- + +# Function: table\_getHeaderGroups() + +```ts +function table_getHeaderGroups(table): HeaderGroup[]; +``` + +Defined in: [core/headers/coreHeadersFeature.utils.ts:48](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.utils.ts#L48) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`HeaderGroup`](../type-aliases/HeaderGroup.md)\<`TFeatures`, `TData`\>[] diff --git a/docs/reference/functions/table_getIsAllColumnsVisible.md b/docs/reference/functions/table_getIsAllColumnsVisible.md new file mode 100644 index 0000000000..b8ebb3acfa --- /dev/null +++ b/docs/reference/functions/table_getIsAllColumnsVisible.md @@ -0,0 +1,32 @@ +--- +id: table_getIsAllColumnsVisible +title: table_getIsAllColumnsVisible +--- + +# Function: table\_getIsAllColumnsVisible() + +```ts +function table_getIsAllColumnsVisible(table): boolean; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:150](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L150) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/table_getIsAllPageRowsSelected.md b/docs/reference/functions/table_getIsAllPageRowsSelected.md new file mode 100644 index 0000000000..960f7cac98 --- /dev/null +++ b/docs/reference/functions/table_getIsAllPageRowsSelected.md @@ -0,0 +1,32 @@ +--- +id: table_getIsAllPageRowsSelected +title: table_getIsAllPageRowsSelected +--- + +# Function: table\_getIsAllPageRowsSelected() + +```ts +function table_getIsAllPageRowsSelected(table): boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:170](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L170) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/table_getIsAllRowsExpanded.md b/docs/reference/functions/table_getIsAllRowsExpanded.md new file mode 100644 index 0000000000..ffb10bf5ba --- /dev/null +++ b/docs/reference/functions/table_getIsAllRowsExpanded.md @@ -0,0 +1,32 @@ +--- +id: table_getIsAllRowsExpanded +title: table_getIsAllRowsExpanded +--- + +# Function: table\_getIsAllRowsExpanded() + +```ts +function table_getIsAllRowsExpanded(table): boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:82](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L82) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/table_getIsAllRowsSelected.md b/docs/reference/functions/table_getIsAllRowsSelected.md new file mode 100644 index 0000000000..3b93de246f --- /dev/null +++ b/docs/reference/functions/table_getIsAllRowsSelected.md @@ -0,0 +1,32 @@ +--- +id: table_getIsAllRowsSelected +title: table_getIsAllRowsSelected +--- + +# Function: table\_getIsAllRowsSelected() + +```ts +function table_getIsAllRowsSelected(table): boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:145](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L145) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/table_getIsSomeColumnsPinned.md b/docs/reference/functions/table_getIsSomeColumnsPinned.md new file mode 100644 index 0000000000..f7b1e38d84 --- /dev/null +++ b/docs/reference/functions/table_getIsSomeColumnsPinned.md @@ -0,0 +1,36 @@ +--- +id: table_getIsSomeColumnsPinned +title: table_getIsSomeColumnsPinned +--- + +# Function: table\_getIsSomeColumnsPinned() + +```ts +function table_getIsSomeColumnsPinned(table, position?): boolean; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:199](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L199) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### position? + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) + +## Returns + +`boolean` diff --git a/docs/reference/functions/table_getIsSomeColumnsVisible.md b/docs/reference/functions/table_getIsSomeColumnsVisible.md new file mode 100644 index 0000000000..7214c5c9a0 --- /dev/null +++ b/docs/reference/functions/table_getIsSomeColumnsVisible.md @@ -0,0 +1,32 @@ +--- +id: table_getIsSomeColumnsVisible +title: table_getIsSomeColumnsVisible +--- + +# Function: table\_getIsSomeColumnsVisible() + +```ts +function table_getIsSomeColumnsVisible(table): boolean; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:162](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L162) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/table_getIsSomePageRowsSelected.md b/docs/reference/functions/table_getIsSomePageRowsSelected.md new file mode 100644 index 0000000000..90e749b9ee --- /dev/null +++ b/docs/reference/functions/table_getIsSomePageRowsSelected.md @@ -0,0 +1,32 @@ +--- +id: table_getIsSomePageRowsSelected +title: table_getIsSomePageRowsSelected +--- + +# Function: table\_getIsSomePageRowsSelected() + +```ts +function table_getIsSomePageRowsSelected(table): boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:203](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L203) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/table_getIsSomeRowsExpanded.md b/docs/reference/functions/table_getIsSomeRowsExpanded.md new file mode 100644 index 0000000000..362fbcfded --- /dev/null +++ b/docs/reference/functions/table_getIsSomeRowsExpanded.md @@ -0,0 +1,32 @@ +--- +id: table_getIsSomeRowsExpanded +title: table_getIsSomeRowsExpanded +--- + +# Function: table\_getIsSomeRowsExpanded() + +```ts +function table_getIsSomeRowsExpanded(table): boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:74](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L74) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/table_getIsSomeRowsPinned.md b/docs/reference/functions/table_getIsSomeRowsPinned.md new file mode 100644 index 0000000000..e5bc89d81f --- /dev/null +++ b/docs/reference/functions/table_getIsSomeRowsPinned.md @@ -0,0 +1,36 @@ +--- +id: table_getIsSomeRowsPinned +title: table_getIsSomeRowsPinned +--- + +# Function: table\_getIsSomeRowsPinned() + +```ts +function table_getIsSomeRowsPinned(table, position?): boolean; +``` + +Defined in: [features/row-pinning/rowPinningFeature.utils.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.utils.ts#L45) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### position? + +[`RowPinningPosition`](../type-aliases/RowPinningPosition.md) + +## Returns + +`boolean` diff --git a/docs/reference/functions/table_getIsSomeRowsSelected.md b/docs/reference/functions/table_getIsSomeRowsSelected.md new file mode 100644 index 0000000000..46c1f5a1a3 --- /dev/null +++ b/docs/reference/functions/table_getIsSomeRowsSelected.md @@ -0,0 +1,32 @@ +--- +id: table_getIsSomeRowsSelected +title: table_getIsSomeRowsSelected +--- + +# Function: table\_getIsSomeRowsSelected() + +```ts +function table_getIsSomeRowsSelected(table): boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:192](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L192) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`boolean` diff --git a/docs/reference/functions/table_getLeafHeaders.md b/docs/reference/functions/table_getLeafHeaders.md new file mode 100644 index 0000000000..55bd14e658 --- /dev/null +++ b/docs/reference/functions/table_getLeafHeaders.md @@ -0,0 +1,32 @@ +--- +id: table_getLeafHeaders +title: table_getLeafHeaders +--- + +# Function: table\_getLeafHeaders() + +```ts +function table_getLeafHeaders(table): any[]; +``` + +Defined in: [core/headers/coreHeadersFeature.utils.ts:102](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.utils.ts#L102) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getLeftFlatHeaders.md b/docs/reference/functions/table_getLeftFlatHeaders.md new file mode 100644 index 0000000000..f364e5cc0d --- /dev/null +++ b/docs/reference/functions/table_getLeftFlatHeaders.md @@ -0,0 +1,32 @@ +--- +id: table_getLeftFlatHeaders +title: table_getLeftFlatHeaders +--- + +# Function: table\_getLeftFlatHeaders() + +```ts +function table_getLeftFlatHeaders(table): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:315](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L315) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getLeftFooterGroups.md b/docs/reference/functions/table_getLeftFooterGroups.md new file mode 100644 index 0000000000..109679e20e --- /dev/null +++ b/docs/reference/functions/table_getLeftFooterGroups.md @@ -0,0 +1,32 @@ +--- +id: table_getLeftFooterGroups +title: table_getLeftFooterGroups +--- + +# Function: table\_getLeftFooterGroups() + +```ts +function table_getLeftFooterGroups(table): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:277](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L277) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getLeftHeaderGroups.md b/docs/reference/functions/table_getLeftHeaderGroups.md new file mode 100644 index 0000000000..38b0d67c6e --- /dev/null +++ b/docs/reference/functions/table_getLeftHeaderGroups.md @@ -0,0 +1,32 @@ +--- +id: table_getLeftHeaderGroups +title: table_getLeftHeaderGroups +--- + +# Function: table\_getLeftHeaderGroups() + +```ts +function table_getLeftHeaderGroups(table): HeaderGroup[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:213](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L213) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`HeaderGroup`](../type-aliases/HeaderGroup.md)\<`TFeatures`, `TData`\>[] diff --git a/docs/reference/functions/table_getLeftLeafColumns.md b/docs/reference/functions/table_getLeftLeafColumns.md new file mode 100644 index 0000000000..e1949f20a6 --- /dev/null +++ b/docs/reference/functions/table_getLeftLeafColumns.md @@ -0,0 +1,32 @@ +--- +id: table_getLeftLeafColumns +title: table_getLeftLeafColumns +--- + +# Function: table\_getLeftLeafColumns() + +```ts +function table_getLeftLeafColumns(table): Column[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:400](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L400) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/table_getLeftLeafHeaders.md b/docs/reference/functions/table_getLeftLeafHeaders.md new file mode 100644 index 0000000000..6cfd443118 --- /dev/null +++ b/docs/reference/functions/table_getLeftLeafHeaders.md @@ -0,0 +1,32 @@ +--- +id: table_getLeftLeafHeaders +title: table_getLeftLeafHeaders +--- + +# Function: table\_getLeftLeafHeaders() + +```ts +function table_getLeftLeafHeaders(table): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:365](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L365) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getLeftTotalSize.md b/docs/reference/functions/table_getLeftTotalSize.md new file mode 100644 index 0000000000..d103687b40 --- /dev/null +++ b/docs/reference/functions/table_getLeftTotalSize.md @@ -0,0 +1,32 @@ +--- +id: table_getLeftTotalSize +title: table_getLeftTotalSize +--- + +# Function: table\_getLeftTotalSize() + +```ts +function table_getLeftTotalSize(table): any; +``` + +Defined in: [features/column-sizing/columnSizingFeature.utils.ts:168](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.utils.ts#L168) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any` diff --git a/docs/reference/functions/table_getLeftVisibleLeafColumns.md b/docs/reference/functions/table_getLeftVisibleLeafColumns.md new file mode 100644 index 0000000000..53a01016eb --- /dev/null +++ b/docs/reference/functions/table_getLeftVisibleLeafColumns.md @@ -0,0 +1,32 @@ +--- +id: table_getLeftVisibleLeafColumns +title: table_getLeftVisibleLeafColumns +--- + +# Function: table\_getLeftVisibleLeafColumns() + +```ts +function table_getLeftVisibleLeafColumns(table): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:468](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L468) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getOrderColumnsFn.md b/docs/reference/functions/table_getOrderColumnsFn.md new file mode 100644 index 0000000000..df1d229957 --- /dev/null +++ b/docs/reference/functions/table_getOrderColumnsFn.md @@ -0,0 +1,44 @@ +--- +id: table_getOrderColumnsFn +title: table_getOrderColumnsFn +--- + +# Function: table\_getOrderColumnsFn() + +```ts +function table_getOrderColumnsFn(table): (columns) => Column_Internal[]; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.utils.ts:67](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.utils.ts#L67) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +```ts +(columns): Column_Internal[]; +``` + +### Parameters + +#### columns + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `unknown`\>[] + +### Returns + +[`Column_Internal`](../type-aliases/Column_Internal.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/table_getPageCount.md b/docs/reference/functions/table_getPageCount.md new file mode 100644 index 0000000000..3f22dbfe6f --- /dev/null +++ b/docs/reference/functions/table_getPageCount.md @@ -0,0 +1,32 @@ +--- +id: table_getPageCount +title: table_getPageCount +--- + +# Function: table\_getPageCount() + +```ts +function table_getPageCount(table): number; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:186](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L186) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`number` diff --git a/docs/reference/functions/table_getPageOptions.md b/docs/reference/functions/table_getPageOptions.md new file mode 100644 index 0000000000..c80263f424 --- /dev/null +++ b/docs/reference/functions/table_getPageOptions.md @@ -0,0 +1,32 @@ +--- +id: table_getPageOptions +title: table_getPageOptions +--- + +# Function: table\_getPageOptions() + +```ts +function table_getPageOptions(table): number[]; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:118](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L118) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`number`[] diff --git a/docs/reference/functions/table_getPaginatedRowModel.md b/docs/reference/functions/table_getPaginatedRowModel.md new file mode 100644 index 0000000000..6996562149 --- /dev/null +++ b/docs/reference/functions/table_getPaginatedRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getPaginatedRowModel +title: table_getPaginatedRowModel +--- + +# Function: table\_getPaginatedRowModel() + +```ts +function table_getPaginatedRowModel(table): RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.utils.ts:119](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.utils.ts#L119) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getPinnedLeafColumns.md b/docs/reference/functions/table_getPinnedLeafColumns.md new file mode 100644 index 0000000000..f9b6329fc5 --- /dev/null +++ b/docs/reference/functions/table_getPinnedLeafColumns.md @@ -0,0 +1,36 @@ +--- +id: table_getPinnedLeafColumns +title: table_getPinnedLeafColumns +--- + +# Function: table\_getPinnedLeafColumns() + +```ts +function table_getPinnedLeafColumns(table, position): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:438](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L438) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### position + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) | `"center"` + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getPinnedVisibleLeafColumns.md b/docs/reference/functions/table_getPinnedVisibleLeafColumns.md new file mode 100644 index 0000000000..03fd18975d --- /dev/null +++ b/docs/reference/functions/table_getPinnedVisibleLeafColumns.md @@ -0,0 +1,36 @@ +--- +id: table_getPinnedVisibleLeafColumns +title: table_getPinnedVisibleLeafColumns +--- + +# Function: table\_getPinnedVisibleLeafColumns() + +```ts +function table_getPinnedVisibleLeafColumns(table, position?): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:507](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L507) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### position? + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) | `"center"` + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getPreExpandedRowModel.md b/docs/reference/functions/table_getPreExpandedRowModel.md new file mode 100644 index 0000000000..5cb7eddb47 --- /dev/null +++ b/docs/reference/functions/table_getPreExpandedRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getPreExpandedRowModel +title: table_getPreExpandedRowModel +--- + +# Function: table\_getPreExpandedRowModel() + +```ts +function table_getPreExpandedRowModel(table): RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.utils.ts:89](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.utils.ts#L89) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getPreFilteredRowModel.md b/docs/reference/functions/table_getPreFilteredRowModel.md new file mode 100644 index 0000000000..603795219d --- /dev/null +++ b/docs/reference/functions/table_getPreFilteredRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getPreFilteredRowModel +title: table_getPreFilteredRowModel +--- + +# Function: table\_getPreFilteredRowModel() + +```ts +function table_getPreFilteredRowModel(table): RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.utils.ts:20](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.utils.ts#L20) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getPreGroupedRowModel.md b/docs/reference/functions/table_getPreGroupedRowModel.md new file mode 100644 index 0000000000..3c2f92571c --- /dev/null +++ b/docs/reference/functions/table_getPreGroupedRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getPreGroupedRowModel +title: table_getPreGroupedRowModel +--- + +# Function: table\_getPreGroupedRowModel() + +```ts +function table_getPreGroupedRowModel(table): RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.utils.ts:43](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.utils.ts#L43) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getPrePaginatedRowModel.md b/docs/reference/functions/table_getPrePaginatedRowModel.md new file mode 100644 index 0000000000..33b8000ea1 --- /dev/null +++ b/docs/reference/functions/table_getPrePaginatedRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getPrePaginatedRowModel +title: table_getPrePaginatedRowModel +--- + +# Function: table\_getPrePaginatedRowModel() + +```ts +function table_getPrePaginatedRowModel(table): RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.utils.ts:112](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.utils.ts#L112) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getPreSelectedRowModel.md b/docs/reference/functions/table_getPreSelectedRowModel.md new file mode 100644 index 0000000000..c165218481 --- /dev/null +++ b/docs/reference/functions/table_getPreSelectedRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getPreSelectedRowModel +title: table_getPreSelectedRowModel +--- + +# Function: table\_getPreSelectedRowModel() + +```ts +function table_getPreSelectedRowModel(table): RowModel; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:87](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L87) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getPreSortedRowModel.md b/docs/reference/functions/table_getPreSortedRowModel.md new file mode 100644 index 0000000000..d0a12c85de --- /dev/null +++ b/docs/reference/functions/table_getPreSortedRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getPreSortedRowModel +title: table_getPreSortedRowModel +--- + +# Function: table\_getPreSortedRowModel() + +```ts +function table_getPreSortedRowModel(table): RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.utils.ts:66](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.utils.ts#L66) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getRightFlatHeaders.md b/docs/reference/functions/table_getRightFlatHeaders.md new file mode 100644 index 0000000000..4aace1cb48 --- /dev/null +++ b/docs/reference/functions/table_getRightFlatHeaders.md @@ -0,0 +1,32 @@ +--- +id: table_getRightFlatHeaders +title: table_getRightFlatHeaders +--- + +# Function: table\_getRightFlatHeaders() + +```ts +function table_getRightFlatHeaders(table): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:331](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L331) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getRightFooterGroups.md b/docs/reference/functions/table_getRightFooterGroups.md new file mode 100644 index 0000000000..d783e28b41 --- /dev/null +++ b/docs/reference/functions/table_getRightFooterGroups.md @@ -0,0 +1,32 @@ +--- +id: table_getRightFooterGroups +title: table_getRightFooterGroups +--- + +# Function: table\_getRightFooterGroups() + +```ts +function table_getRightFooterGroups(table): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:289](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L289) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getRightHeaderGroups.md b/docs/reference/functions/table_getRightHeaderGroups.md new file mode 100644 index 0000000000..84bb873bcf --- /dev/null +++ b/docs/reference/functions/table_getRightHeaderGroups.md @@ -0,0 +1,32 @@ +--- +id: table_getRightHeaderGroups +title: table_getRightHeaderGroups +--- + +# Function: table\_getRightHeaderGroups() + +```ts +function table_getRightHeaderGroups(table): HeaderGroup[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:233](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L233) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`HeaderGroup`](../type-aliases/HeaderGroup.md)\<`TFeatures`, `TData`\>[] diff --git a/docs/reference/functions/table_getRightLeafColumns.md b/docs/reference/functions/table_getRightLeafColumns.md new file mode 100644 index 0000000000..349a11ad53 --- /dev/null +++ b/docs/reference/functions/table_getRightLeafColumns.md @@ -0,0 +1,32 @@ +--- +id: table_getRightLeafColumns +title: table_getRightLeafColumns +--- + +# Function: table\_getRightLeafColumns() + +```ts +function table_getRightLeafColumns(table): Column[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:414](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L414) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/table_getRightLeafHeaders.md b/docs/reference/functions/table_getRightLeafHeaders.md new file mode 100644 index 0000000000..b5954174a6 --- /dev/null +++ b/docs/reference/functions/table_getRightLeafHeaders.md @@ -0,0 +1,32 @@ +--- +id: table_getRightLeafHeaders +title: table_getRightLeafHeaders +--- + +# Function: table\_getRightLeafHeaders() + +```ts +function table_getRightLeafHeaders(table): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:376](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L376) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getRightTotalSize.md b/docs/reference/functions/table_getRightTotalSize.md new file mode 100644 index 0000000000..e212ade5cd --- /dev/null +++ b/docs/reference/functions/table_getRightTotalSize.md @@ -0,0 +1,32 @@ +--- +id: table_getRightTotalSize +title: table_getRightTotalSize +--- + +# Function: table\_getRightTotalSize() + +```ts +function table_getRightTotalSize(table): any; +``` + +Defined in: [features/column-sizing/columnSizingFeature.utils.ts:198](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.utils.ts#L198) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any` diff --git a/docs/reference/functions/table_getRightVisibleLeafColumns.md b/docs/reference/functions/table_getRightVisibleLeafColumns.md new file mode 100644 index 0000000000..7db070ec85 --- /dev/null +++ b/docs/reference/functions/table_getRightVisibleLeafColumns.md @@ -0,0 +1,32 @@ +--- +id: table_getRightVisibleLeafColumns +title: table_getRightVisibleLeafColumns +--- + +# Function: table\_getRightVisibleLeafColumns() + +```ts +function table_getRightVisibleLeafColumns(table): any[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:481](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L481) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`any`[] diff --git a/docs/reference/functions/table_getRow.md b/docs/reference/functions/table_getRow.md new file mode 100644 index 0000000000..6c25537082 --- /dev/null +++ b/docs/reference/functions/table_getRow.md @@ -0,0 +1,43 @@ +--- +id: table_getRow +title: table_getRow +--- + +# Function: table\_getRow() + +```ts +function table_getRow( + table, + rowId, +searchAll?): Row; +``` + +Defined in: [core/rows/coreRowsFeature.utils.ts:129](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L129) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### rowId + +`string` + +### searchAll? + +`boolean` + +## Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getRowCount.md b/docs/reference/functions/table_getRowCount.md new file mode 100644 index 0000000000..7ab73f67ef --- /dev/null +++ b/docs/reference/functions/table_getRowCount.md @@ -0,0 +1,32 @@ +--- +id: table_getRowCount +title: table_getRowCount +--- + +# Function: table\_getRowCount() + +```ts +function table_getRowCount(table): number; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:199](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L199) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`number` diff --git a/docs/reference/functions/table_getRowId.md b/docs/reference/functions/table_getRowId.md new file mode 100644 index 0000000000..9b1fa0c820 --- /dev/null +++ b/docs/reference/functions/table_getRowId.md @@ -0,0 +1,48 @@ +--- +id: table_getRowId +title: table_getRowId +--- + +# Function: table\_getRowId() + +```ts +function table_getRowId( + originalRow, + table, + index, + parent?): string; +``` + +Defined in: [core/rows/coreRowsFeature.utils.ts:114](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.utils.ts#L114) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### originalRow + +`TData` + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### index + +`number` + +### parent? + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +## Returns + +`string` diff --git a/docs/reference/functions/table_getRowModel.md b/docs/reference/functions/table_getRowModel.md new file mode 100644 index 0000000000..303f6fabb2 --- /dev/null +++ b/docs/reference/functions/table_getRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getRowModel +title: table_getRowModel +--- + +# Function: table\_getRowModel() + +```ts +function table_getRowModel(table): RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.utils.ts:135](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.utils.ts#L135) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getSelectedRowModel.md b/docs/reference/functions/table_getSelectedRowModel.md new file mode 100644 index 0000000000..7172e0dbb0 --- /dev/null +++ b/docs/reference/functions/table_getSelectedRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getSelectedRowModel +title: table_getSelectedRowModel +--- + +# Function: table\_getSelectedRowModel() + +```ts +function table_getSelectedRowModel(table): RowModel; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:94](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L94) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getSortedRowModel.md b/docs/reference/functions/table_getSortedRowModel.md new file mode 100644 index 0000000000..d602828f2c --- /dev/null +++ b/docs/reference/functions/table_getSortedRowModel.md @@ -0,0 +1,32 @@ +--- +id: table_getSortedRowModel +title: table_getSortedRowModel +--- + +# Function: table\_getSortedRowModel() + +```ts +function table_getSortedRowModel(table): RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.utils.ts:73](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.utils.ts#L73) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_getToggleAllColumnsVisibilityHandler.md b/docs/reference/functions/table_getToggleAllColumnsVisibilityHandler.md new file mode 100644 index 0000000000..704eff3bb0 --- /dev/null +++ b/docs/reference/functions/table_getToggleAllColumnsVisibilityHandler.md @@ -0,0 +1,44 @@ +--- +id: table_getToggleAllColumnsVisibilityHandler +title: table_getToggleAllColumnsVisibilityHandler +--- + +# Function: table\_getToggleAllColumnsVisibilityHandler() + +```ts +function table_getToggleAllColumnsVisibilityHandler(table): (e) => void; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:173](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L173) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +```ts +(e): void; +``` + +### Parameters + +#### e + +`unknown` + +### Returns + +`void` diff --git a/docs/reference/functions/table_getToggleAllPageRowsSelectedHandler.md b/docs/reference/functions/table_getToggleAllPageRowsSelectedHandler.md new file mode 100644 index 0000000000..799f1a1c61 --- /dev/null +++ b/docs/reference/functions/table_getToggleAllPageRowsSelectedHandler.md @@ -0,0 +1,44 @@ +--- +id: table_getToggleAllPageRowsSelectedHandler +title: table_getToggleAllPageRowsSelectedHandler +--- + +# Function: table\_getToggleAllPageRowsSelectedHandler() + +```ts +function table_getToggleAllPageRowsSelectedHandler(table): (e) => void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:227](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L227) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +```ts +(e): void; +``` + +### Parameters + +#### e + +`unknown` + +### Returns + +`void` diff --git a/docs/reference/functions/table_getToggleAllRowsExpandedHandler.md b/docs/reference/functions/table_getToggleAllRowsExpandedHandler.md new file mode 100644 index 0000000000..e66d3171e0 --- /dev/null +++ b/docs/reference/functions/table_getToggleAllRowsExpandedHandler.md @@ -0,0 +1,44 @@ +--- +id: table_getToggleAllRowsExpandedHandler +title: table_getToggleAllRowsExpandedHandler +--- + +# Function: table\_getToggleAllRowsExpandedHandler() + +```ts +function table_getToggleAllRowsExpandedHandler(table): (e) => void; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:64](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L64) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +```ts +(e): void; +``` + +### Parameters + +#### e + +`unknown` + +### Returns + +`void` diff --git a/docs/reference/functions/table_getToggleAllRowsSelectedHandler.md b/docs/reference/functions/table_getToggleAllRowsSelectedHandler.md new file mode 100644 index 0000000000..6212b6a5f3 --- /dev/null +++ b/docs/reference/functions/table_getToggleAllRowsSelectedHandler.md @@ -0,0 +1,44 @@ +--- +id: table_getToggleAllRowsSelectedHandler +title: table_getToggleAllRowsSelectedHandler +--- + +# Function: table\_getToggleAllRowsSelectedHandler() + +```ts +function table_getToggleAllRowsSelectedHandler(table): (e) => void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:215](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L215) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +```ts +(e): void; +``` + +### Parameters + +#### e + +`unknown` + +### Returns + +`void` diff --git a/docs/reference/functions/table_getTopRows.md b/docs/reference/functions/table_getTopRows.md new file mode 100644 index 0000000000..b5230c2d34 --- /dev/null +++ b/docs/reference/functions/table_getTopRows.md @@ -0,0 +1,32 @@ +--- +id: table_getTopRows +title: table_getTopRows +--- + +# Function: table\_getTopRows() + +```ts +function table_getTopRows(table): Row[]; +``` + +Defined in: [features/row-pinning/rowPinningFeature.utils.ts:91](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.utils.ts#L91) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] diff --git a/docs/reference/functions/table_getTotalSize.md b/docs/reference/functions/table_getTotalSize.md new file mode 100644 index 0000000000..007b1e3928 --- /dev/null +++ b/docs/reference/functions/table_getTotalSize.md @@ -0,0 +1,32 @@ +--- +id: table_getTotalSize +title: table_getTotalSize +--- + +# Function: table\_getTotalSize() + +```ts +function table_getTotalSize(table): number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.utils.ts:157](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.utils.ts#L157) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`number` diff --git a/docs/reference/functions/table_getVisibleFlatColumns.md b/docs/reference/functions/table_getVisibleFlatColumns.md new file mode 100644 index 0000000000..91af3fecd7 --- /dev/null +++ b/docs/reference/functions/table_getVisibleFlatColumns.md @@ -0,0 +1,32 @@ +--- +id: table_getVisibleFlatColumns +title: table_getVisibleFlatColumns +--- + +# Function: table\_getVisibleFlatColumns() + +```ts +function table_getVisibleFlatColumns(table): Column[]; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:90](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L90) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/table_getVisibleLeafColumns.md b/docs/reference/functions/table_getVisibleLeafColumns.md new file mode 100644 index 0000000000..27e489fcdf --- /dev/null +++ b/docs/reference/functions/table_getVisibleLeafColumns.md @@ -0,0 +1,32 @@ +--- +id: table_getVisibleLeafColumns +title: table_getVisibleLeafColumns +--- + +# Function: table\_getVisibleLeafColumns() + +```ts +function table_getVisibleLeafColumns(table): Column[]; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:101](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L101) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/functions/table_lastPage.md b/docs/reference/functions/table_lastPage.md new file mode 100644 index 0000000000..abf04de99a --- /dev/null +++ b/docs/reference/functions/table_lastPage.md @@ -0,0 +1,32 @@ +--- +id: table_lastPage +title: table_lastPage +--- + +# Function: table\_lastPage() + +```ts +function table_lastPage(table): void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:179](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L179) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_mergeOptions.md b/docs/reference/functions/table_mergeOptions.md new file mode 100644 index 0000000000..4291d7c53c --- /dev/null +++ b/docs/reference/functions/table_mergeOptions.md @@ -0,0 +1,36 @@ +--- +id: table_mergeOptions +title: table_mergeOptions +--- + +# Function: table\_mergeOptions() + +```ts +function table_mergeOptions(table, newOptions): TableOptions; +``` + +Defined in: [core/table/coreTablesFeature.utils.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.utils.ts#L14) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### newOptions + +[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\> + +## Returns + +[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/functions/table_nextPage.md b/docs/reference/functions/table_nextPage.md new file mode 100644 index 0000000000..23e6fd966d --- /dev/null +++ b/docs/reference/functions/table_nextPage.md @@ -0,0 +1,32 @@ +--- +id: table_nextPage +title: table_nextPage +--- + +# Function: table\_nextPage() + +```ts +function table_nextPage(table): void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:163](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L163) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_previousPage.md b/docs/reference/functions/table_previousPage.md new file mode 100644 index 0000000000..d62365d50a --- /dev/null +++ b/docs/reference/functions/table_previousPage.md @@ -0,0 +1,32 @@ +--- +id: table_previousPage +title: table_previousPage +--- + +# Function: table\_previousPage() + +```ts +function table_previousPage(table): void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:156](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L156) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_reset.md b/docs/reference/functions/table_reset.md new file mode 100644 index 0000000000..268cd94307 --- /dev/null +++ b/docs/reference/functions/table_reset.md @@ -0,0 +1,32 @@ +--- +id: table_reset +title: table_reset +--- + +# Function: table\_reset() + +```ts +function table_reset(table): void; +``` + +Defined in: [core/table/coreTablesFeature.utils.ts:7](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.utils.ts#L7) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetColumnFilters.md b/docs/reference/functions/table_resetColumnFilters.md new file mode 100644 index 0000000000..f788d879eb --- /dev/null +++ b/docs/reference/functions/table_resetColumnFilters.md @@ -0,0 +1,36 @@ +--- +id: table_resetColumnFilters +title: table_resetColumnFilters +--- + +# Function: table\_resetColumnFilters() + +```ts +function table_resetColumnFilters(table, defaultState?): void; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.utils.ts:184](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.utils.ts#L184) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetColumnOrder.md b/docs/reference/functions/table_resetColumnOrder.md new file mode 100644 index 0000000000..0873757721 --- /dev/null +++ b/docs/reference/functions/table_resetColumnOrder.md @@ -0,0 +1,36 @@ +--- +id: table_resetColumnOrder +title: table_resetColumnOrder +--- + +# Function: table\_resetColumnOrder() + +```ts +function table_resetColumnOrder(table, defaultState?): void; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.utils.ts:57](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.utils.ts#L57) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetColumnPinning.md b/docs/reference/functions/table_resetColumnPinning.md new file mode 100644 index 0000000000..fbfbaffe0a --- /dev/null +++ b/docs/reference/functions/table_resetColumnPinning.md @@ -0,0 +1,36 @@ +--- +id: table_resetColumnPinning +title: table_resetColumnPinning +--- + +# Function: table\_resetColumnPinning() + +```ts +function table_resetColumnPinning(table, defaultState?): void; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:187](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L187) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetColumnSizing.md b/docs/reference/functions/table_resetColumnSizing.md new file mode 100644 index 0000000000..26b017da2c --- /dev/null +++ b/docs/reference/functions/table_resetColumnSizing.md @@ -0,0 +1,36 @@ +--- +id: table_resetColumnSizing +title: table_resetColumnSizing +--- + +# Function: table\_resetColumnSizing() + +```ts +function table_resetColumnSizing(table, defaultState?): void; +``` + +Defined in: [features/column-sizing/columnSizingFeature.utils.ts:147](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.utils.ts#L147) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetColumnVisibility.md b/docs/reference/functions/table_resetColumnVisibility.md new file mode 100644 index 0000000000..f0f3ec5741 --- /dev/null +++ b/docs/reference/functions/table_resetColumnVisibility.md @@ -0,0 +1,36 @@ +--- +id: table_resetColumnVisibility +title: table_resetColumnVisibility +--- + +# Function: table\_resetColumnVisibility() + +```ts +function table_resetColumnVisibility(table, defaultState?): void; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:122](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L122) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetExpanded.md b/docs/reference/functions/table_resetExpanded.md new file mode 100644 index 0000000000..a164e7b853 --- /dev/null +++ b/docs/reference/functions/table_resetExpanded.md @@ -0,0 +1,36 @@ +--- +id: table_resetExpanded +title: table_resetExpanded +--- + +# Function: table\_resetExpanded() + +```ts +function table_resetExpanded(table, defaultState?): void; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L45) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetGlobalFilter.md b/docs/reference/functions/table_resetGlobalFilter.md new file mode 100644 index 0000000000..e79e2fa396 --- /dev/null +++ b/docs/reference/functions/table_resetGlobalFilter.md @@ -0,0 +1,36 @@ +--- +id: table_resetGlobalFilter +title: table_resetGlobalFilter +--- + +# Function: table\_resetGlobalFilter() + +```ts +function table_resetGlobalFilter(table, defaultState?): void; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.utils.ts:52](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.utils.ts#L52) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetGrouping.md b/docs/reference/functions/table_resetGrouping.md new file mode 100644 index 0000000000..958d286225 --- /dev/null +++ b/docs/reference/functions/table_resetGrouping.md @@ -0,0 +1,36 @@ +--- +id: table_resetGrouping +title: table_resetGrouping +--- + +# Function: table\_resetGrouping() + +```ts +function table_resetGrouping(table, defaultState?): void; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:120](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L120) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetHeaderSizeInfo.md b/docs/reference/functions/table_resetHeaderSizeInfo.md new file mode 100644 index 0000000000..776c0af9a6 --- /dev/null +++ b/docs/reference/functions/table_resetHeaderSizeInfo.md @@ -0,0 +1,36 @@ +--- +id: table_resetHeaderSizeInfo +title: table_resetHeaderSizeInfo +--- + +# Function: table\_resetHeaderSizeInfo() + +```ts +function table_resetHeaderSizeInfo(table, defaultState?): void; +``` + +Defined in: [features/column-resizing/columnResizingFeature.utils.ts:226](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.utils.ts#L226) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetPageIndex.md b/docs/reference/functions/table_resetPageIndex.md new file mode 100644 index 0000000000..affab42ebb --- /dev/null +++ b/docs/reference/functions/table_resetPageIndex.md @@ -0,0 +1,36 @@ +--- +id: table_resetPageIndex +title: table_resetPageIndex +--- + +# Function: table\_resetPageIndex() + +```ts +function table_resetPageIndex(table, defaultState?): void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:77](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L77) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetPageSize.md b/docs/reference/functions/table_resetPageSize.md new file mode 100644 index 0000000000..38fbe43662 --- /dev/null +++ b/docs/reference/functions/table_resetPageSize.md @@ -0,0 +1,36 @@ +--- +id: table_resetPageSize +title: table_resetPageSize +--- + +# Function: table\_resetPageSize() + +```ts +function table_resetPageSize(table, defaultState?): void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:89](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L89) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetPagination.md b/docs/reference/functions/table_resetPagination.md new file mode 100644 index 0000000000..498e798574 --- /dev/null +++ b/docs/reference/functions/table_resetPagination.md @@ -0,0 +1,36 @@ +--- +id: table_resetPagination +title: table_resetPagination +--- + +# Function: table\_resetPagination() + +```ts +function table_resetPagination(table, defaultState?): void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:43](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L43) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetRowPinning.md b/docs/reference/functions/table_resetRowPinning.md new file mode 100644 index 0000000000..5a3fec2b65 --- /dev/null +++ b/docs/reference/functions/table_resetRowPinning.md @@ -0,0 +1,36 @@ +--- +id: table_resetRowPinning +title: table_resetRowPinning +--- + +# Function: table\_resetRowPinning() + +```ts +function table_resetRowPinning(table, defaultState?): void; +``` + +Defined in: [features/row-pinning/rowPinningFeature.utils.ts:31](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.utils.ts#L31) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetRowSelection.md b/docs/reference/functions/table_resetRowSelection.md new file mode 100644 index 0000000000..3b26e10215 --- /dev/null +++ b/docs/reference/functions/table_resetRowSelection.md @@ -0,0 +1,36 @@ +--- +id: table_resetRowSelection +title: table_resetRowSelection +--- + +# Function: table\_resetRowSelection() + +```ts +function table_resetRowSelection(table, defaultState?): void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:24](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L24) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_resetSorting.md b/docs/reference/functions/table_resetSorting.md new file mode 100644 index 0000000000..430ee9571e --- /dev/null +++ b/docs/reference/functions/table_resetSorting.md @@ -0,0 +1,36 @@ +--- +id: table_resetSorting +title: table_resetSorting +--- + +# Function: table\_resetSorting() + +```ts +function table_resetSorting(table, defaultState?): void; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L26) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### defaultState? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_setColumnFilters.md b/docs/reference/functions/table_setColumnFilters.md new file mode 100644 index 0000000000..7f99000024 --- /dev/null +++ b/docs/reference/functions/table_setColumnFilters.md @@ -0,0 +1,36 @@ +--- +id: table_setColumnFilters +title: table_setColumnFilters +--- + +# Function: table\_setColumnFilters() + +```ts +function table_setColumnFilters(table, updater): void; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.utils.ts:156](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.utils.ts#L156) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<[`ColumnFiltersState`](../type-aliases/ColumnFiltersState.md)\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_setColumnOrder.md b/docs/reference/functions/table_setColumnOrder.md new file mode 100644 index 0000000000..ef3b2542cd --- /dev/null +++ b/docs/reference/functions/table_setColumnOrder.md @@ -0,0 +1,36 @@ +--- +id: table_setColumnOrder +title: table_setColumnOrder +--- + +# Function: table\_setColumnOrder() + +```ts +function table_setColumnOrder(table, updater): void; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.utils.ts:50](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.utils.ts#L50) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<[`ColumnOrderState`](../type-aliases/ColumnOrderState.md)\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_setColumnPinning.md b/docs/reference/functions/table_setColumnPinning.md new file mode 100644 index 0000000000..6f139e9347 --- /dev/null +++ b/docs/reference/functions/table_setColumnPinning.md @@ -0,0 +1,36 @@ +--- +id: table_setColumnPinning +title: table_setColumnPinning +--- + +# Function: table\_setColumnPinning() + +```ts +function table_setColumnPinning(table, updater): void; +``` + +Defined in: [features/column-pinning/columnPinningFeature.utils.ts:177](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.utils.ts#L177) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<[`ColumnPinningState`](../interfaces/ColumnPinningState.md)\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_setColumnResizing.md b/docs/reference/functions/table_setColumnResizing.md new file mode 100644 index 0000000000..1472bbbed2 --- /dev/null +++ b/docs/reference/functions/table_setColumnResizing.md @@ -0,0 +1,36 @@ +--- +id: table_setColumnResizing +title: table_setColumnResizing +--- + +# Function: table\_setColumnResizing() + +```ts +function table_setColumnResizing(table, updater): void; +``` + +Defined in: [features/column-resizing/columnResizingFeature.utils.ts:216](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.utils.ts#L216) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<[`columnResizingState`](../interfaces/columnResizingState.md)\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_setColumnSizing.md b/docs/reference/functions/table_setColumnSizing.md new file mode 100644 index 0000000000..40553648e4 --- /dev/null +++ b/docs/reference/functions/table_setColumnSizing.md @@ -0,0 +1,36 @@ +--- +id: table_setColumnSizing +title: table_setColumnSizing +--- + +# Function: table\_setColumnSizing() + +```ts +function table_setColumnSizing(table, updater): void; +``` + +Defined in: [features/column-sizing/columnSizingFeature.utils.ts:137](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.utils.ts#L137) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<[`ColumnSizingState`](../type-aliases/ColumnSizingState.md)\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_setColumnVisibility.md b/docs/reference/functions/table_setColumnVisibility.md new file mode 100644 index 0000000000..d3fdb3b74a --- /dev/null +++ b/docs/reference/functions/table_setColumnVisibility.md @@ -0,0 +1,36 @@ +--- +id: table_setColumnVisibility +title: table_setColumnVisibility +--- + +# Function: table\_setColumnVisibility() + +```ts +function table_setColumnVisibility(table, updater): void; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:112](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L112) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<[`ColumnVisibilityState`](../type-aliases/ColumnVisibilityState.md)\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_setExpanded.md b/docs/reference/functions/table_setExpanded.md new file mode 100644 index 0000000000..dab47fb281 --- /dev/null +++ b/docs/reference/functions/table_setExpanded.md @@ -0,0 +1,36 @@ +--- +id: table_setExpanded +title: table_setExpanded +--- + +# Function: table\_setExpanded() + +```ts +function table_setExpanded(table, updater): void; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L27) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<[`ExpandedState`](../type-aliases/ExpandedState.md)\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_setGlobalFilter.md b/docs/reference/functions/table_setGlobalFilter.md new file mode 100644 index 0000000000..4405ffe0ce --- /dev/null +++ b/docs/reference/functions/table_setGlobalFilter.md @@ -0,0 +1,36 @@ +--- +id: table_setGlobalFilter +title: table_setGlobalFilter +--- + +# Function: table\_setGlobalFilter() + +```ts +function table_setGlobalFilter(table, updater): void; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.utils.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.utils.ts#L45) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +`any` + +## Returns + +`void` diff --git a/docs/reference/functions/table_setGrouping.md b/docs/reference/functions/table_setGrouping.md new file mode 100644 index 0000000000..2f830a010c --- /dev/null +++ b/docs/reference/functions/table_setGrouping.md @@ -0,0 +1,36 @@ +--- +id: table_setGrouping +title: table_setGrouping +--- + +# Function: table\_setGrouping() + +```ts +function table_setGrouping(table, updater): void; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.utils.ts:113](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.utils.ts#L113) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<[`GroupingState`](../type-aliases/GroupingState.md)\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_setOptions.md b/docs/reference/functions/table_setOptions.md new file mode 100644 index 0000000000..fb947a6249 --- /dev/null +++ b/docs/reference/functions/table_setOptions.md @@ -0,0 +1,36 @@ +--- +id: table_setOptions +title: table_setOptions +--- + +# Function: table\_setOptions() + +```ts +function table_setOptions(table, updater): void; +``` + +Defined in: [core/table/coreTablesFeature.utils.ts:31](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.utils.ts#L31) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_setPageIndex.md b/docs/reference/functions/table_setPageIndex.md new file mode 100644 index 0000000000..1b8ccdec18 --- /dev/null +++ b/docs/reference/functions/table_setPageIndex.md @@ -0,0 +1,36 @@ +--- +id: table_setPageIndex +title: table_setPageIndex +--- + +# Function: table\_setPageIndex() + +```ts +function table_setPageIndex(table, updater): void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:55](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L55) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<`number`\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_setPageSize.md b/docs/reference/functions/table_setPageSize.md new file mode 100644 index 0000000000..65a82fa862 --- /dev/null +++ b/docs/reference/functions/table_setPageSize.md @@ -0,0 +1,36 @@ +--- +id: table_setPageSize +title: table_setPageSize +--- + +# Function: table\_setPageSize() + +```ts +function table_setPageSize(table, updater): void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:101](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L101) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<`number`\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_setPagination.md b/docs/reference/functions/table_setPagination.md new file mode 100644 index 0000000000..d0752fa6e0 --- /dev/null +++ b/docs/reference/functions/table_setPagination.md @@ -0,0 +1,36 @@ +--- +id: table_setPagination +title: table_setPagination +--- + +# Function: table\_setPagination() + +```ts +function table_setPagination(table, updater): void | undefined; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.utils.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.utils.ts#L30) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<[`PaginationState`](../interfaces/PaginationState.md)\> + +## Returns + +`void` \| `undefined` diff --git a/docs/reference/functions/table_setRowPinning.md b/docs/reference/functions/table_setRowPinning.md new file mode 100644 index 0000000000..dc70b2d079 --- /dev/null +++ b/docs/reference/functions/table_setRowPinning.md @@ -0,0 +1,36 @@ +--- +id: table_setRowPinning +title: table_setRowPinning +--- + +# Function: table\_setRowPinning() + +```ts +function table_setRowPinning(table, updater): void; +``` + +Defined in: [features/row-pinning/rowPinningFeature.utils.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.utils.ts#L21) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<[`RowPinningState`](../interfaces/RowPinningState.md)\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_setRowSelection.md b/docs/reference/functions/table_setRowSelection.md new file mode 100644 index 0000000000..a60e39c33b --- /dev/null +++ b/docs/reference/functions/table_setRowSelection.md @@ -0,0 +1,36 @@ +--- +id: table_setRowSelection +title: table_setRowSelection +--- + +# Function: table\_setRowSelection() + +```ts +function table_setRowSelection(table, updater): void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L14) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<[`RowSelectionState`](../type-aliases/RowSelectionState.md)\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_setSorting.md b/docs/reference/functions/table_setSorting.md new file mode 100644 index 0000000000..384ea33bfc --- /dev/null +++ b/docs/reference/functions/table_setSorting.md @@ -0,0 +1,36 @@ +--- +id: table_setSorting +title: table_setSorting +--- + +# Function: table\_setSorting() + +```ts +function table_setSorting(table, updater): void; +``` + +Defined in: [features/row-sorting/rowSortingFeature.utils.ts:19](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.utils.ts#L19) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### updater + +[`Updater`](../type-aliases/Updater.md)\<[`SortingState`](../type-aliases/SortingState.md)\> + +## Returns + +`void` diff --git a/docs/reference/functions/table_toggleAllColumnsVisible.md b/docs/reference/functions/table_toggleAllColumnsVisible.md new file mode 100644 index 0000000000..bccc4ac8a4 --- /dev/null +++ b/docs/reference/functions/table_toggleAllColumnsVisible.md @@ -0,0 +1,36 @@ +--- +id: table_toggleAllColumnsVisible +title: table_toggleAllColumnsVisible +--- + +# Function: table\_toggleAllColumnsVisible() + +```ts +function table_toggleAllColumnsVisible(table, value?): void; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.utils.ts:132](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.utils.ts#L132) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### value? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_toggleAllPageRowsSelected.md b/docs/reference/functions/table_toggleAllPageRowsSelected.md new file mode 100644 index 0000000000..43cf3869cf --- /dev/null +++ b/docs/reference/functions/table_toggleAllPageRowsSelected.md @@ -0,0 +1,36 @@ +--- +id: table_toggleAllPageRowsSelected +title: table_toggleAllPageRowsSelected +--- + +# Function: table\_toggleAllPageRowsSelected() + +```ts +function table_toggleAllPageRowsSelected(table, value?): void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:67](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L67) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### value? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_toggleAllRowsExpanded.md b/docs/reference/functions/table_toggleAllRowsExpanded.md new file mode 100644 index 0000000000..c122626644 --- /dev/null +++ b/docs/reference/functions/table_toggleAllRowsExpanded.md @@ -0,0 +1,36 @@ +--- +id: table_toggleAllRowsExpanded +title: table_toggleAllRowsExpanded +--- + +# Function: table\_toggleAllRowsExpanded() + +```ts +function table_toggleAllRowsExpanded(table, expanded?): void; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.utils.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.utils.ts#L34) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### expanded? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/functions/table_toggleAllRowsSelected.md b/docs/reference/functions/table_toggleAllRowsSelected.md new file mode 100644 index 0000000000..e4c7740e78 --- /dev/null +++ b/docs/reference/functions/table_toggleAllRowsSelected.md @@ -0,0 +1,36 @@ +--- +id: table_toggleAllRowsSelected +title: table_toggleAllRowsSelected +--- + +# Function: table\_toggleAllRowsSelected() + +```ts +function table_toggleAllRowsSelected(table, value?): void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.utils.ts:36](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.utils.ts#L36) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Parameters + +### table + +[`Table_Internal`](../type-aliases/Table_Internal.md)\<`TFeatures`, `TData`\> + +### value? + +`boolean` + +## Returns + +`void` diff --git a/docs/reference/index.md b/docs/reference/index.md new file mode 100644 index 0000000000..8ffe4a5d17 --- /dev/null +++ b/docs/reference/index.md @@ -0,0 +1,644 @@ +--- +id: "@tanstack/table-core" +title: "@tanstack/table-core" +--- + +# @tanstack/table-core + +## Namespaces + +- [filterFn\_arrIncludes](@tanstack/namespaces/filterFn_arrIncludes/index.md) +- [filterFn\_arrIncludesAll](@tanstack/namespaces/filterFn_arrIncludesAll/index.md) +- [filterFn\_arrIncludesSome](@tanstack/namespaces/filterFn_arrIncludesSome/index.md) +- [filterFn\_equals](@tanstack/namespaces/filterFn_equals/index.md) +- [filterFn\_equalsString](@tanstack/namespaces/filterFn_equalsString/index.md) +- [filterFn\_equalsStringSensitive](@tanstack/namespaces/filterFn_equalsStringSensitive/index.md) +- [filterFn\_greaterThan](@tanstack/namespaces/filterFn_greaterThan/index.md) +- [filterFn\_greaterThanOrEqualTo](@tanstack/namespaces/filterFn_greaterThanOrEqualTo/index.md) +- [filterFn\_includesString](@tanstack/namespaces/filterFn_includesString/index.md) +- [filterFn\_includesStringSensitive](@tanstack/namespaces/filterFn_includesStringSensitive/index.md) +- [filterFn\_inNumberRange](@tanstack/namespaces/filterFn_inNumberRange/index.md) +- [filterFn\_lessThan](@tanstack/namespaces/filterFn_lessThan/index.md) +- [filterFn\_lessThanOrEqualTo](@tanstack/namespaces/filterFn_lessThanOrEqualTo/index.md) +- [filterFn\_weakEquals](@tanstack/namespaces/filterFn_weakEquals/index.md) + +## Interfaces + +- [AggregationFns](interfaces/AggregationFns.md) +- [API](interfaces/API.md) +- [CachedRowModel\_Core](interfaces/CachedRowModel_Core.md) +- [CachedRowModel\_Expanded](interfaces/CachedRowModel_Expanded.md) +- [CachedRowModel\_Faceted](interfaces/CachedRowModel_Faceted.md) +- [CachedRowModel\_Filtered](interfaces/CachedRowModel_Filtered.md) +- [CachedRowModel\_Grouped](interfaces/CachedRowModel_Grouped.md) +- [CachedRowModel\_Paginated](interfaces/CachedRowModel_Paginated.md) +- [CachedRowModel\_Plugins](interfaces/CachedRowModel_Plugins.md) +- [CachedRowModel\_Sorted](interfaces/CachedRowModel_Sorted.md) +- [CachedRowModels\_Plugins](interfaces/CachedRowModels_Plugins.md) +- [Cell\_Cell](interfaces/Cell_Cell.md) +- [Cell\_ColumnGrouping](interfaces/Cell_ColumnGrouping.md) +- [Cell\_Core](interfaces/Cell_Core.md) +- [Cell\_CoreProperties](interfaces/Cell_CoreProperties.md) +- [Cell\_Plugins](interfaces/Cell_Plugins.md) +- [CellContext](interfaces/CellContext.md) +- [Column\_Column](interfaces/Column_Column.md) +- [Column\_ColumnFaceting](interfaces/Column_ColumnFaceting.md) +- [Column\_ColumnFiltering](interfaces/Column_ColumnFiltering.md) +- [Column\_ColumnGrouping](interfaces/Column_ColumnGrouping.md) +- [Column\_ColumnOrdering](interfaces/Column_ColumnOrdering.md) +- [Column\_ColumnPinning](interfaces/Column_ColumnPinning.md) +- [Column\_ColumnResizing](interfaces/Column_ColumnResizing.md) +- [Column\_ColumnSizing](interfaces/Column_ColumnSizing.md) +- [Column\_ColumnVisibility](interfaces/Column_ColumnVisibility.md) +- [Column\_Core](interfaces/Column_Core.md) +- [Column\_CoreProperties](interfaces/Column_CoreProperties.md) +- [Column\_GlobalFiltering](interfaces/Column_GlobalFiltering.md) +- [Column\_Plugins](interfaces/Column_Plugins.md) +- [Column\_RowSorting](interfaces/Column_RowSorting.md) +- [ColumnDef\_ColumnFiltering](interfaces/ColumnDef_ColumnFiltering.md) +- [ColumnDef\_ColumnGrouping](interfaces/ColumnDef_ColumnGrouping.md) +- [ColumnDef\_ColumnPinning](interfaces/ColumnDef_ColumnPinning.md) +- [ColumnDef\_ColumnResizing](interfaces/ColumnDef_ColumnResizing.md) +- [ColumnDef\_ColumnSizing](interfaces/ColumnDef_ColumnSizing.md) +- [ColumnDef\_ColumnVisibility](interfaces/ColumnDef_ColumnVisibility.md) +- [ColumnDef\_GlobalFiltering](interfaces/ColumnDef_GlobalFiltering.md) +- [ColumnDef\_Plugins](interfaces/ColumnDef_Plugins.md) +- [ColumnDef\_RowSorting](interfaces/ColumnDef_RowSorting.md) +- [ColumnDefaultOptions](interfaces/ColumnDefaultOptions.md) +- [ColumnFilter](interfaces/ColumnFilter.md) +- [ColumnMeta](interfaces/ColumnMeta.md) +- [ColumnOrderDefaultOptions](interfaces/ColumnOrderDefaultOptions.md) +- [ColumnPinningDefaultOptions](interfaces/ColumnPinningDefaultOptions.md) +- [ColumnPinningState](interfaces/ColumnPinningState.md) +- [columnResizingState](interfaces/columnResizingState.md) +- [ColumnSort](interfaces/ColumnSort.md) +- [CoreFeatures](interfaces/CoreFeatures.md) +- [CreateRowModel\_Core](interfaces/CreateRowModel_Core.md) +- [CreateRowModel\_Expanded](interfaces/CreateRowModel_Expanded.md) +- [CreateRowModel\_Faceted](interfaces/CreateRowModel_Faceted.md) +- [CreateRowModel\_Filtered](interfaces/CreateRowModel_Filtered.md) +- [CreateRowModel\_Grouped](interfaces/CreateRowModel_Grouped.md) +- [CreateRowModel\_Paginated](interfaces/CreateRowModel_Paginated.md) +- [CreateRowModel\_Plugins](interfaces/CreateRowModel_Plugins.md) +- [CreateRowModel\_Sorted](interfaces/CreateRowModel_Sorted.md) +- [CreateRowModels\_Plugins](interfaces/CreateRowModels_Plugins.md) +- [FilterFn](interfaces/FilterFn.md) +- [FilterFns](interfaces/FilterFns.md) +- [FilterMeta](interfaces/FilterMeta.md) +- [Header\_ColumnResizing](interfaces/Header_ColumnResizing.md) +- [Header\_ColumnSizing](interfaces/Header_ColumnSizing.md) +- [Header\_Core](interfaces/Header_Core.md) +- [Header\_CoreProperties](interfaces/Header_CoreProperties.md) +- [Header\_Header](interfaces/Header_Header.md) +- [Header\_Plugins](interfaces/Header_Plugins.md) +- [HeaderContext](interfaces/HeaderContext.md) +- [HeaderGroup\_Core](interfaces/HeaderGroup_Core.md) +- [HeaderGroup\_Header](interfaces/HeaderGroup_Header.md) +- [HeaderGroup\_Plugins](interfaces/HeaderGroup_Plugins.md) +- [IdIdentifier](interfaces/IdIdentifier.md) +- [PaginationDefaultOptions](interfaces/PaginationDefaultOptions.md) +- [PaginationState](interfaces/PaginationState.md) +- [Plugins](interfaces/Plugins.md) +- [PrototypeAPI](interfaces/PrototypeAPI.md) +- [ResolvedColumnFilter](interfaces/ResolvedColumnFilter.md) +- [Row\_ColumnFiltering](interfaces/Row_ColumnFiltering.md) +- [Row\_ColumnGrouping](interfaces/Row_ColumnGrouping.md) +- [Row\_ColumnPinning](interfaces/Row_ColumnPinning.md) +- [Row\_ColumnVisibility](interfaces/Row_ColumnVisibility.md) +- [Row\_Core](interfaces/Row_Core.md) +- [Row\_CoreProperties](interfaces/Row_CoreProperties.md) +- [Row\_Plugins](interfaces/Row_Plugins.md) +- [Row\_Row](interfaces/Row_Row.md) +- [Row\_RowExpanding](interfaces/Row_RowExpanding.md) +- [Row\_RowPinning](interfaces/Row_RowPinning.md) +- [Row\_RowSelection](interfaces/Row_RowSelection.md) +- [RowModel](interfaces/RowModel.md) +- [RowModelFns\_ColumnFiltering](interfaces/RowModelFns_ColumnFiltering.md) +- [RowModelFns\_ColumnGrouping](interfaces/RowModelFns_ColumnGrouping.md) +- [RowModelFns\_Core](interfaces/RowModelFns_Core.md) +- [RowModelFns\_Plugins](interfaces/RowModelFns_Plugins.md) +- [RowModelFns\_RowSorting](interfaces/RowModelFns_RowSorting.md) +- [RowPinningDefaultOptions](interfaces/RowPinningDefaultOptions.md) +- [RowPinningState](interfaces/RowPinningState.md) +- [SortFn](interfaces/SortFn.md) +- [SortFns](interfaces/SortFns.md) +- [StockFeatures](interfaces/StockFeatures.md) +- [StringHeaderIdentifier](interfaces/StringHeaderIdentifier.md) +- [Table\_ColumnFaceting](interfaces/Table_ColumnFaceting.md) +- [Table\_ColumnFiltering](interfaces/Table_ColumnFiltering.md) +- [Table\_ColumnGrouping](interfaces/Table_ColumnGrouping.md) +- [Table\_ColumnOrdering](interfaces/Table_ColumnOrdering.md) +- [Table\_ColumnPinning](interfaces/Table_ColumnPinning.md) +- [Table\_ColumnResizing](interfaces/Table_ColumnResizing.md) +- [Table\_Columns](interfaces/Table_Columns.md) +- [Table\_ColumnSizing](interfaces/Table_ColumnSizing.md) +- [Table\_ColumnVisibility](interfaces/Table_ColumnVisibility.md) +- [Table\_CoreProperties](interfaces/Table_CoreProperties.md) +- [Table\_GlobalFiltering](interfaces/Table_GlobalFiltering.md) +- [Table\_Headers](interfaces/Table_Headers.md) +- [Table\_Plugins](interfaces/Table_Plugins.md) +- [Table\_RowExpanding](interfaces/Table_RowExpanding.md) +- [Table\_RowModels\_Core](interfaces/Table_RowModels_Core.md) +- [Table\_RowModels\_Expanded](interfaces/Table_RowModels_Expanded.md) +- [Table\_RowModels\_Faceted](interfaces/Table_RowModels_Faceted.md) +- [Table\_RowModels\_Filtered](interfaces/Table_RowModels_Filtered.md) +- [Table\_RowModels\_Grouped](interfaces/Table_RowModels_Grouped.md) +- [Table\_RowModels\_Paginated](interfaces/Table_RowModels_Paginated.md) +- [Table\_RowModels\_Sorted](interfaces/Table_RowModels_Sorted.md) +- [Table\_RowPagination](interfaces/Table_RowPagination.md) +- [Table\_RowPinning](interfaces/Table_RowPinning.md) +- [Table\_Rows](interfaces/Table_Rows.md) +- [Table\_RowSelection](interfaces/Table_RowSelection.md) +- [Table\_RowSorting](interfaces/Table_RowSorting.md) +- [Table\_Table](interfaces/Table_Table.md) +- [TableFeature](interfaces/TableFeature.md) +- [TableFeatures](interfaces/TableFeatures.md) +- [TableMeta](interfaces/TableMeta.md) +- [TableOptions\_Cell](interfaces/TableOptions_Cell.md) +- [TableOptions\_ColumnFiltering](interfaces/TableOptions_ColumnFiltering.md) +- [TableOptions\_ColumnGrouping](interfaces/TableOptions_ColumnGrouping.md) +- [TableOptions\_ColumnOrdering](interfaces/TableOptions_ColumnOrdering.md) +- [TableOptions\_ColumnPinning](interfaces/TableOptions_ColumnPinning.md) +- [TableOptions\_ColumnResizing](interfaces/TableOptions_ColumnResizing.md) +- [TableOptions\_Columns](interfaces/TableOptions_Columns.md) +- [TableOptions\_ColumnSizing](interfaces/TableOptions_ColumnSizing.md) +- [TableOptions\_ColumnVisibility](interfaces/TableOptions_ColumnVisibility.md) +- [TableOptions\_Core](interfaces/TableOptions_Core.md) +- [TableOptions\_GlobalFiltering](interfaces/TableOptions_GlobalFiltering.md) +- [TableOptions\_Plugins](interfaces/TableOptions_Plugins.md) +- [TableOptions\_RowExpanding](interfaces/TableOptions_RowExpanding.md) +- [TableOptions\_RowPagination](interfaces/TableOptions_RowPagination.md) +- [TableOptions\_RowPinning](interfaces/TableOptions_RowPinning.md) +- [TableOptions\_Rows](interfaces/TableOptions_Rows.md) +- [TableOptions\_RowSelection](interfaces/TableOptions_RowSelection.md) +- [TableOptions\_RowSorting](interfaces/TableOptions_RowSorting.md) +- [TableOptions\_Table](interfaces/TableOptions_Table.md) +- [TableState\_ColumnFiltering](interfaces/TableState_ColumnFiltering.md) +- [TableState\_ColumnGrouping](interfaces/TableState_ColumnGrouping.md) +- [TableState\_ColumnOrdering](interfaces/TableState_ColumnOrdering.md) +- [TableState\_ColumnPinning](interfaces/TableState_ColumnPinning.md) +- [TableState\_ColumnResizing](interfaces/TableState_ColumnResizing.md) +- [TableState\_ColumnSizing](interfaces/TableState_ColumnSizing.md) +- [TableState\_ColumnVisibility](interfaces/TableState_ColumnVisibility.md) +- [TableState\_GlobalFiltering](interfaces/TableState_GlobalFiltering.md) +- [TableState\_Plugins](interfaces/TableState_Plugins.md) +- [TableState\_RowExpanding](interfaces/TableState_RowExpanding.md) +- [TableState\_RowPagination](interfaces/TableState_RowPagination.md) +- [TableState\_RowPinning](interfaces/TableState_RowPinning.md) +- [TableState\_RowSelection](interfaces/TableState_RowSelection.md) +- [TableState\_RowSorting](interfaces/TableState_RowSorting.md) + +## Type Aliases + +- [AccessorColumnDef](type-aliases/AccessorColumnDef.md) +- [AccessorFn](type-aliases/AccessorFn.md) +- [AccessorFnColumnDef](type-aliases/AccessorFnColumnDef.md) +- [AccessorFnColumnDefBase](type-aliases/AccessorFnColumnDefBase.md) +- [AccessorKeyColumnDef](type-aliases/AccessorKeyColumnDef.md) +- [AccessorKeyColumnDefBase](type-aliases/AccessorKeyColumnDefBase.md) +- [AggregationFn](type-aliases/AggregationFn.md) +- [AggregationFnOption](type-aliases/AggregationFnOption.md) +- [APIObject](type-aliases/APIObject.md) +- [AssignCellPrototype](type-aliases/AssignCellPrototype.md) +- [AssignColumnPrototype](type-aliases/AssignColumnPrototype.md) +- [AssignHeaderPrototype](type-aliases/AssignHeaderPrototype.md) +- [AssignRowPrototype](type-aliases/AssignRowPrototype.md) +- [BuiltInAggregationFn](type-aliases/BuiltInAggregationFn.md) +- [BuiltInFilterFn](type-aliases/BuiltInFilterFn.md) +- [BuiltInSortFn](type-aliases/BuiltInSortFn.md) +- [CachedRowModel\_All](type-aliases/CachedRowModel_All.md) +- [CachedRowModels](type-aliases/CachedRowModels.md) +- [Cell](type-aliases/Cell.md) +- [CellData](type-aliases/CellData.md) +- [Column](type-aliases/Column.md) +- [Column\_Internal](type-aliases/Column_Internal.md) +- [ColumnDef](type-aliases/ColumnDef.md) +- [ColumnDefBase](type-aliases/ColumnDefBase.md) +- [ColumnDefBase\_All](type-aliases/ColumnDefBase_All.md) +- [ColumnDefResolved](type-aliases/ColumnDefResolved.md) +- [ColumnDefTemplate](type-aliases/ColumnDefTemplate.md) +- [ColumnFilterAutoRemoveTestFn](type-aliases/ColumnFilterAutoRemoveTestFn.md) +- [ColumnFiltersState](type-aliases/ColumnFiltersState.md) +- [ColumnHelper](type-aliases/ColumnHelper.md) +- [ColumnOrderState](type-aliases/ColumnOrderState.md) +- [ColumnPinningPosition](type-aliases/ColumnPinningPosition.md) +- [ColumnResizeDirection](type-aliases/ColumnResizeDirection.md) +- [ColumnResizeMode](type-aliases/ColumnResizeMode.md) +- [ColumnResizingDefaultOptions](type-aliases/ColumnResizingDefaultOptions.md) +- [ColumnSizingDefaultOptions](type-aliases/ColumnSizingDefaultOptions.md) +- [ColumnSizingState](type-aliases/ColumnSizingState.md) +- [ColumnVisibilityState](type-aliases/ColumnVisibilityState.md) +- [ConstructTableAPIs](type-aliases/ConstructTableAPIs.md) +- [CreateRowModels](type-aliases/CreateRowModels.md) +- [CreateRowModels\_All](type-aliases/CreateRowModels_All.md) +- [CustomAggregationFns](type-aliases/CustomAggregationFns.md) +- [CustomFilterFns](type-aliases/CustomFilterFns.md) +- [CustomSortFns](type-aliases/CustomSortFns.md) +- [DebugOptions](type-aliases/DebugOptions.md) +- [DeepKeys](type-aliases/DeepKeys.md) +- [DeepValue](type-aliases/DeepValue.md) +- [DisplayColumnDef](type-aliases/DisplayColumnDef.md) +- [ExpandedState](type-aliases/ExpandedState.md) +- [ExpandedStateList](type-aliases/ExpandedStateList.md) +- [ExtractFeatureTypes](type-aliases/ExtractFeatureTypes.md) +- [FilterFnOption](type-aliases/FilterFnOption.md) +- [GetDefaultColumnDef](type-aliases/GetDefaultColumnDef.md) +- [GetDefaultStateSelector](type-aliases/GetDefaultStateSelector.md) +- [GetDefaultTableOptions](type-aliases/GetDefaultTableOptions.md) +- [GetInitialState](type-aliases/GetInitialState.md) +- [Getter](type-aliases/Getter.md) +- [GroupColumnDef](type-aliases/GroupColumnDef.md) +- [GroupingColumnMode](type-aliases/GroupingColumnMode.md) +- [GroupingState](type-aliases/GroupingState.md) +- [Header](type-aliases/Header.md) +- [HeaderGroup](type-aliases/HeaderGroup.md) +- [IdentifiedColumnDef](type-aliases/IdentifiedColumnDef.md) +- [InitRowInstanceData](type-aliases/InitRowInstanceData.md) +- [MemoFnMeta](type-aliases/MemoFnMeta.md) +- [NoInfer](type-aliases/NoInfer.md) +- [OnChangeFn](type-aliases/OnChangeFn.md) +- [PartialKeys](type-aliases/PartialKeys.md) +- [Prettify](type-aliases/Prettify.md) +- [PrototypeAPIObject](type-aliases/PrototypeAPIObject.md) +- [RequiredKeys](type-aliases/RequiredKeys.md) +- [Row](type-aliases/Row.md) +- [RowData](type-aliases/RowData.md) +- [RowModelFns](type-aliases/RowModelFns.md) +- [RowModelFns\_All](type-aliases/RowModelFns_All.md) +- [RowPinningPosition](type-aliases/RowPinningPosition.md) +- [RowSelectionState](type-aliases/RowSelectionState.md) +- [SortDirection](type-aliases/SortDirection.md) +- [SortFnOption](type-aliases/SortFnOption.md) +- [SortingState](type-aliases/SortingState.md) +- [StringOrTemplateHeader](type-aliases/StringOrTemplateHeader.md) +- [Table](type-aliases/Table.md) +- [Table\_Core](type-aliases/Table_Core.md) +- [Table\_Internal](type-aliases/Table_Internal.md) +- [Table\_RowModels](type-aliases/Table_RowModels.md) +- [TableHelper\_Core](type-aliases/TableHelper_Core.md) +- [TableHelperOptions](type-aliases/TableHelperOptions.md) +- [TableOptions](type-aliases/TableOptions.md) +- [TableOptions\_All](type-aliases/TableOptions_All.md) +- [TableState](type-aliases/TableState.md) +- [TableState\_All](type-aliases/TableState_All.md) +- [TransformFilterValueFn](type-aliases/TransformFilterValueFn.md) +- [UnionToIntersection](type-aliases/UnionToIntersection.md) +- [Updater](type-aliases/Updater.md) +- [VisibilityDefaultOptions](type-aliases/VisibilityDefaultOptions.md) + +## Variables + +- [$internalMemoFnMeta](variables/$internalMemoFnMeta.md) +- [aggregationFn\_count](variables/aggregationFn_count.md) +- [aggregationFn\_extent](variables/aggregationFn_extent.md) +- [aggregationFn\_max](variables/aggregationFn_max.md) +- [aggregationFn\_mean](variables/aggregationFn_mean.md) +- [aggregationFn\_median](variables/aggregationFn_median.md) +- [aggregationFn\_min](variables/aggregationFn_min.md) +- [aggregationFn\_sum](variables/aggregationFn_sum.md) +- [aggregationFn\_unique](variables/aggregationFn_unique.md) +- [aggregationFn\_uniqueCount](variables/aggregationFn_uniqueCount.md) +- [aggregationFns](variables/aggregationFns.md) +- [columnFacetingFeature](variables/columnFacetingFeature.md) +- [columnFilteringFeature](variables/columnFilteringFeature.md) +- [columnGroupingFeature](variables/columnGroupingFeature.md) +- [columnOrderingFeature](variables/columnOrderingFeature.md) +- [columnPinningFeature](variables/columnPinningFeature.md) +- [columnResizingFeature](variables/columnResizingFeature.md) +- [columnSizingFeature](variables/columnSizingFeature.md) +- [columnVisibilityFeature](variables/columnVisibilityFeature.md) +- [coreCellsFeature](variables/coreCellsFeature.md) +- [coreColumnsFeature](variables/coreColumnsFeature.md) +- [coreFeatures](variables/coreFeatures.md) +- [coreHeadersFeature](variables/coreHeadersFeature.md) +- [coreRowModelsFeature](variables/coreRowModelsFeature.md) +- [coreRowsFeature](variables/coreRowsFeature.md) +- [coreTablesFeature](variables/coreTablesFeature.md) +- [filterFn\_arrHas](variables/filterFn_arrHas.md) +- [filterFn\_arrIncludes](variables/filterFn_arrIncludes.md) +- [filterFn\_arrIncludesAll](variables/filterFn_arrIncludesAll.md) +- [filterFn\_arrIncludesSome](variables/filterFn_arrIncludesSome.md) +- [filterFn\_equals](variables/filterFn_equals.md) +- [filterFn\_equalsString](variables/filterFn_equalsString.md) +- [filterFn\_equalsStringSensitive](variables/filterFn_equalsStringSensitive.md) +- [filterFn\_greaterThan](variables/filterFn_greaterThan.md) +- [filterFn\_greaterThanOrEqualTo](variables/filterFn_greaterThanOrEqualTo.md) +- [filterFn\_includesString](variables/filterFn_includesString.md) +- [filterFn\_includesStringSensitive](variables/filterFn_includesStringSensitive.md) +- [filterFn\_inNumberRange](variables/filterFn_inNumberRange.md) +- [filterFn\_lessThan](variables/filterFn_lessThan.md) +- [filterFn\_lessThanOrEqualTo](variables/filterFn_lessThanOrEqualTo.md) +- [filterFn\_weakEquals](variables/filterFn_weakEquals.md) +- [filterFns](variables/filterFns.md) +- [globalFilteringFeature](variables/globalFilteringFeature.md) +- [reSplitAlphaNumeric](variables/reSplitAlphaNumeric.md) +- [rowExpandingFeature](variables/rowExpandingFeature.md) +- [rowPaginationFeature](variables/rowPaginationFeature.md) +- [rowPinningFeature](variables/rowPinningFeature.md) +- [rowSelectionFeature](variables/rowSelectionFeature.md) +- [rowSortingFeature](variables/rowSortingFeature.md) +- [sortFn\_alphanumeric](variables/sortFn_alphanumeric.md) +- [sortFn\_alphanumericCaseSensitive](variables/sortFn_alphanumericCaseSensitive.md) +- [sortFn\_basic](variables/sortFn_basic.md) +- [sortFn\_datetime](variables/sortFn_datetime.md) +- [sortFn\_text](variables/sortFn_text.md) +- [sortFn\_textCaseSensitive](variables/sortFn_textCaseSensitive.md) +- [sortFns](variables/sortFns.md) +- [stockFeatures](variables/stockFeatures.md) + +## Functions + +- [assignPrototypeAPIs](functions/assignPrototypeAPIs.md) +- [assignTableAPIs](functions/assignTableAPIs.md) +- [buildHeaderGroups](functions/buildHeaderGroups.md) +- [callMemoOrStaticFn](functions/callMemoOrStaticFn.md) +- [cell\_getContext](functions/cell_getContext.md) +- [cell\_getIsAggregated](functions/cell_getIsAggregated.md) +- [cell\_getIsGrouped](functions/cell_getIsGrouped.md) +- [cell\_getIsPlaceholder](functions/cell_getIsPlaceholder.md) +- [cell\_getValue](functions/cell_getValue.md) +- [cell\_renderValue](functions/cell_renderValue.md) +- [column\_clearSorting](functions/column_clearSorting.md) +- [column\_getAfter](functions/column_getAfter.md) +- [column\_getAggregationFn](functions/column_getAggregationFn.md) +- [column\_getAutoAggregationFn](functions/column_getAutoAggregationFn.md) +- [column\_getAutoFilterFn](functions/column_getAutoFilterFn.md) +- [column\_getAutoSortDir](functions/column_getAutoSortDir.md) +- [column\_getAutoSortFn](functions/column_getAutoSortFn.md) +- [column\_getCanFilter](functions/column_getCanFilter.md) +- [column\_getCanGlobalFilter](functions/column_getCanGlobalFilter.md) +- [column\_getCanGroup](functions/column_getCanGroup.md) +- [column\_getCanHide](functions/column_getCanHide.md) +- [column\_getCanMultiSort](functions/column_getCanMultiSort.md) +- [column\_getCanPin](functions/column_getCanPin.md) +- [column\_getCanResize](functions/column_getCanResize.md) +- [column\_getCanSort](functions/column_getCanSort.md) +- [column\_getFacetedMinMaxValues](functions/column_getFacetedMinMaxValues.md) +- [column\_getFacetedRowModel](functions/column_getFacetedRowModel.md) +- [column\_getFacetedUniqueValues](functions/column_getFacetedUniqueValues.md) +- [column\_getFilterFn](functions/column_getFilterFn.md) +- [column\_getFilterIndex](functions/column_getFilterIndex.md) +- [column\_getFilterValue](functions/column_getFilterValue.md) +- [column\_getFirstSortDir](functions/column_getFirstSortDir.md) +- [column\_getFlatColumns](functions/column_getFlatColumns.md) +- [column\_getGroupedIndex](functions/column_getGroupedIndex.md) +- [column\_getIndex](functions/column_getIndex.md) +- [column\_getIsFiltered](functions/column_getIsFiltered.md) +- [column\_getIsFirstColumn](functions/column_getIsFirstColumn.md) +- [column\_getIsGrouped](functions/column_getIsGrouped.md) +- [column\_getIsLastColumn](functions/column_getIsLastColumn.md) +- [column\_getIsPinned](functions/column_getIsPinned.md) +- [column\_getIsResizing](functions/column_getIsResizing.md) +- [column\_getIsSorted](functions/column_getIsSorted.md) +- [column\_getIsVisible](functions/column_getIsVisible.md) +- [column\_getLeafColumns](functions/column_getLeafColumns.md) +- [column\_getNextSortingOrder](functions/column_getNextSortingOrder.md) +- [column\_getPinnedIndex](functions/column_getPinnedIndex.md) +- [column\_getSize](functions/column_getSize.md) +- [column\_getSortFn](functions/column_getSortFn.md) +- [column\_getSortIndex](functions/column_getSortIndex.md) +- [column\_getStart](functions/column_getStart.md) +- [column\_getToggleGroupingHandler](functions/column_getToggleGroupingHandler.md) +- [column\_getToggleSortingHandler](functions/column_getToggleSortingHandler.md) +- [column\_getToggleVisibilityHandler](functions/column_getToggleVisibilityHandler.md) +- [column\_pin](functions/column_pin.md) +- [column\_resetSize](functions/column_resetSize.md) +- [column\_setFilterValue](functions/column_setFilterValue.md) +- [column\_toggleGrouping](functions/column_toggleGrouping.md) +- [column\_toggleSorting](functions/column_toggleSorting.md) +- [column\_toggleVisibility](functions/column_toggleVisibility.md) +- [constructCell](functions/constructCell.md) +- [constructColumn](functions/constructColumn.md) +- [constructColumnFacetingFeature](functions/constructColumnFacetingFeature.md) +- [constructColumnFilteringFeature](functions/constructColumnFilteringFeature.md) +- [constructColumnGroupingFeature](functions/constructColumnGroupingFeature.md) +- [constructColumnOrderingFeature](functions/constructColumnOrderingFeature.md) +- [constructColumnPinningFeature](functions/constructColumnPinningFeature.md) +- [constructColumnResizingFeature](functions/constructColumnResizingFeature.md) +- [constructColumnSizingFeature](functions/constructColumnSizingFeature.md) +- [constructColumnVisibilityFeature](functions/constructColumnVisibilityFeature.md) +- [constructCoreCellsFeature](functions/constructCoreCellsFeature.md) +- [constructCoreColumnsFeature](functions/constructCoreColumnsFeature.md) +- [constructCoreHeadersFeature](functions/constructCoreHeadersFeature.md) +- [constructCoreRowModelsFeature](functions/constructCoreRowModelsFeature.md) +- [constructCoreRowsFeature](functions/constructCoreRowsFeature.md) +- [constructCoreTablesFeature](functions/constructCoreTablesFeature.md) +- [constructGlobalFilteringFeature](functions/constructGlobalFilteringFeature.md) +- [constructHeader](functions/constructHeader.md) +- [constructRow](functions/constructRow.md) +- [constructRowExpandingFeature](functions/constructRowExpandingFeature.md) +- [constructRowPaginationFeature](functions/constructRowPaginationFeature.md) +- [constructRowPinningFeature](functions/constructRowPinningFeature.md) +- [constructRowSelectionFeature](functions/constructRowSelectionFeature.md) +- [constructRowSortingFeature](functions/constructRowSortingFeature.md) +- [constructTable](functions/constructTable.md) +- [constructTableHelper](functions/constructTableHelper.md) +- [createColumnHelper](functions/createColumnHelper.md) +- [createCoreRowModel](functions/createCoreRowModel.md) +- [createExpandedRowModel](functions/createExpandedRowModel.md) +- [createFacetedMinMaxValues](functions/createFacetedMinMaxValues.md) +- [createFacetedRowModel](functions/createFacetedRowModel.md) +- [createFacetedUniqueValues](functions/createFacetedUniqueValues.md) +- [createFilteredRowModel](functions/createFilteredRowModel.md) +- [createGroupedRowModel](functions/createGroupedRowModel.md) +- [createPaginatedRowModel](functions/createPaginatedRowModel.md) +- [createSortedRowModel](functions/createSortedRowModel.md) +- [createTableStore](functions/createTableStore.md) +- [expandRows](functions/expandRows.md) +- [flattenBy](functions/flattenBy.md) +- [functionalUpdate](functions/functionalUpdate.md) +- [getDefaultColumnFiltersState](functions/getDefaultColumnFiltersState.md) +- [getDefaultColumnOrderState](functions/getDefaultColumnOrderState.md) +- [getDefaultColumnPinningState](functions/getDefaultColumnPinningState.md) +- [getDefaultColumnResizingState](functions/getDefaultColumnResizingState.md) +- [getDefaultColumnSizingColumnDef](functions/getDefaultColumnSizingColumnDef.md) +- [getDefaultColumnSizingState](functions/getDefaultColumnSizingState.md) +- [getDefaultColumnVisibilityState](functions/getDefaultColumnVisibilityState.md) +- [getDefaultExpandedState](functions/getDefaultExpandedState.md) +- [getDefaultGroupingState](functions/getDefaultGroupingState.md) +- [getDefaultPaginationState](functions/getDefaultPaginationState.md) +- [getDefaultRowPinningState](functions/getDefaultRowPinningState.md) +- [getDefaultRowSelectionState](functions/getDefaultRowSelectionState.md) +- [getDefaultSortingState](functions/getDefaultSortingState.md) +- [getFunctionNameInfo](functions/getFunctionNameInfo.md) +- [getInitialTableState](functions/getInitialTableState.md) +- [getMemoFnMeta](functions/getMemoFnMeta.md) +- [header\_getContext](functions/header_getContext.md) +- [header\_getLeafHeaders](functions/header_getLeafHeaders.md) +- [header\_getResizeHandler](functions/header_getResizeHandler.md) +- [header\_getSize](functions/header_getSize.md) +- [header\_getStart](functions/header_getStart.md) +- [isFunction](functions/isFunction.md) +- [isNumberArray](functions/isNumberArray.md) +- [isRowSelected](functions/isRowSelected.md) +- [isSubRowSelected](functions/isSubRowSelected.md) +- [isTouchStartEvent](functions/isTouchStartEvent.md) +- [makeStateUpdater](functions/makeStateUpdater.md) +- [memo](functions/memo.md) +- [noop](functions/noop.md) +- [orderColumns](functions/orderColumns.md) +- [passiveEventSupported](functions/passiveEventSupported.md) +- [row\_getAllCells](functions/row_getAllCells.md) +- [row\_getAllCellsByColumnId](functions/row_getAllCellsByColumnId.md) +- [row\_getAllVisibleCells](functions/row_getAllVisibleCells.md) +- [row\_getCanExpand](functions/row_getCanExpand.md) +- [row\_getCanMultiSelect](functions/row_getCanMultiSelect.md) +- [row\_getCanPin](functions/row_getCanPin.md) +- [row\_getCanSelect](functions/row_getCanSelect.md) +- [row\_getCanSelectSubRows](functions/row_getCanSelectSubRows.md) +- [row\_getCenterVisibleCells](functions/row_getCenterVisibleCells.md) +- [row\_getGroupingValue](functions/row_getGroupingValue.md) +- [row\_getIsAllParentsExpanded](functions/row_getIsAllParentsExpanded.md) +- [row\_getIsAllSubRowsSelected](functions/row_getIsAllSubRowsSelected.md) +- [row\_getIsExpanded](functions/row_getIsExpanded.md) +- [row\_getIsGrouped](functions/row_getIsGrouped.md) +- [row\_getIsPinned](functions/row_getIsPinned.md) +- [row\_getIsSelected](functions/row_getIsSelected.md) +- [row\_getIsSomeSelected](functions/row_getIsSomeSelected.md) +- [row\_getLeafRows](functions/row_getLeafRows.md) +- [row\_getLeftVisibleCells](functions/row_getLeftVisibleCells.md) +- [row\_getParentRow](functions/row_getParentRow.md) +- [row\_getParentRows](functions/row_getParentRows.md) +- [row\_getPinnedIndex](functions/row_getPinnedIndex.md) +- [row\_getRightVisibleCells](functions/row_getRightVisibleCells.md) +- [row\_getToggleExpandedHandler](functions/row_getToggleExpandedHandler.md) +- [row\_getToggleSelectedHandler](functions/row_getToggleSelectedHandler.md) +- [row\_getUniqueValues](functions/row_getUniqueValues.md) +- [row\_getValue](functions/row_getValue.md) +- [row\_getVisibleCells](functions/row_getVisibleCells.md) +- [row\_pin](functions/row_pin.md) +- [row\_renderValue](functions/row_renderValue.md) +- [row\_toggleExpanded](functions/row_toggleExpanded.md) +- [row\_toggleSelected](functions/row_toggleSelected.md) +- [selectRowsFn](functions/selectRowsFn.md) +- [shouldAutoRemoveFilter](functions/shouldAutoRemoveFilter.md) +- [table\_autoResetExpanded](functions/table_autoResetExpanded.md) +- [table\_autoResetPageIndex](functions/table_autoResetPageIndex.md) +- [table\_firstPage](functions/table_firstPage.md) +- [table\_getAllColumns](functions/table_getAllColumns.md) +- [table\_getAllFlatColumns](functions/table_getAllFlatColumns.md) +- [table\_getAllFlatColumnsById](functions/table_getAllFlatColumnsById.md) +- [table\_getAllLeafColumns](functions/table_getAllLeafColumns.md) +- [table\_getBottomRows](functions/table_getBottomRows.md) +- [table\_getCanNextPage](functions/table_getCanNextPage.md) +- [table\_getCanPreviousPage](functions/table_getCanPreviousPage.md) +- [table\_getCanSomeRowsExpand](functions/table_getCanSomeRowsExpand.md) +- [table\_getCenterFlatHeaders](functions/table_getCenterFlatHeaders.md) +- [table\_getCenterFooterGroups](functions/table_getCenterFooterGroups.md) +- [table\_getCenterHeaderGroups](functions/table_getCenterHeaderGroups.md) +- [table\_getCenterLeafColumns](functions/table_getCenterLeafColumns.md) +- [table\_getCenterLeafHeaders](functions/table_getCenterLeafHeaders.md) +- [table\_getCenterRows](functions/table_getCenterRows.md) +- [table\_getCenterTotalSize](functions/table_getCenterTotalSize.md) +- [table\_getCenterVisibleLeafColumns](functions/table_getCenterVisibleLeafColumns.md) +- [table\_getColumn](functions/table_getColumn.md) +- [table\_getCoreRowModel](functions/table_getCoreRowModel.md) +- [table\_getDefaultColumnDef](functions/table_getDefaultColumnDef.md) +- [table\_getExpandedDepth](functions/table_getExpandedDepth.md) +- [table\_getExpandedRowModel](functions/table_getExpandedRowModel.md) +- [table\_getFilteredRowModel](functions/table_getFilteredRowModel.md) +- [table\_getFilteredSelectedRowModel](functions/table_getFilteredSelectedRowModel.md) +- [table\_getFlatHeaders](functions/table_getFlatHeaders.md) +- [table\_getFooterGroups](functions/table_getFooterGroups.md) +- [table\_getGlobalAutoFilterFn](functions/table_getGlobalAutoFilterFn.md) +- [table\_getGlobalFacetedMinMaxValues](functions/table_getGlobalFacetedMinMaxValues.md) +- [table\_getGlobalFacetedRowModel](functions/table_getGlobalFacetedRowModel.md) +- [table\_getGlobalFacetedUniqueValues](functions/table_getGlobalFacetedUniqueValues.md) +- [table\_getGlobalFilterFn](functions/table_getGlobalFilterFn.md) +- [table\_getGroupedRowModel](functions/table_getGroupedRowModel.md) +- [table\_getGroupedSelectedRowModel](functions/table_getGroupedSelectedRowModel.md) +- [table\_getHeaderGroups](functions/table_getHeaderGroups.md) +- [table\_getIsAllColumnsVisible](functions/table_getIsAllColumnsVisible.md) +- [table\_getIsAllPageRowsSelected](functions/table_getIsAllPageRowsSelected.md) +- [table\_getIsAllRowsExpanded](functions/table_getIsAllRowsExpanded.md) +- [table\_getIsAllRowsSelected](functions/table_getIsAllRowsSelected.md) +- [table\_getIsSomeColumnsPinned](functions/table_getIsSomeColumnsPinned.md) +- [table\_getIsSomeColumnsVisible](functions/table_getIsSomeColumnsVisible.md) +- [table\_getIsSomePageRowsSelected](functions/table_getIsSomePageRowsSelected.md) +- [table\_getIsSomeRowsExpanded](functions/table_getIsSomeRowsExpanded.md) +- [table\_getIsSomeRowsPinned](functions/table_getIsSomeRowsPinned.md) +- [table\_getIsSomeRowsSelected](functions/table_getIsSomeRowsSelected.md) +- [table\_getLeafHeaders](functions/table_getLeafHeaders.md) +- [table\_getLeftFlatHeaders](functions/table_getLeftFlatHeaders.md) +- [table\_getLeftFooterGroups](functions/table_getLeftFooterGroups.md) +- [table\_getLeftHeaderGroups](functions/table_getLeftHeaderGroups.md) +- [table\_getLeftLeafColumns](functions/table_getLeftLeafColumns.md) +- [table\_getLeftLeafHeaders](functions/table_getLeftLeafHeaders.md) +- [table\_getLeftTotalSize](functions/table_getLeftTotalSize.md) +- [table\_getLeftVisibleLeafColumns](functions/table_getLeftVisibleLeafColumns.md) +- [table\_getOrderColumnsFn](functions/table_getOrderColumnsFn.md) +- [table\_getPageCount](functions/table_getPageCount.md) +- [table\_getPageOptions](functions/table_getPageOptions.md) +- [table\_getPaginatedRowModel](functions/table_getPaginatedRowModel.md) +- [table\_getPinnedLeafColumns](functions/table_getPinnedLeafColumns.md) +- [table\_getPinnedVisibleLeafColumns](functions/table_getPinnedVisibleLeafColumns.md) +- [table\_getPreExpandedRowModel](functions/table_getPreExpandedRowModel.md) +- [table\_getPreFilteredRowModel](functions/table_getPreFilteredRowModel.md) +- [table\_getPreGroupedRowModel](functions/table_getPreGroupedRowModel.md) +- [table\_getPrePaginatedRowModel](functions/table_getPrePaginatedRowModel.md) +- [table\_getPreSelectedRowModel](functions/table_getPreSelectedRowModel.md) +- [table\_getPreSortedRowModel](functions/table_getPreSortedRowModel.md) +- [table\_getRightFlatHeaders](functions/table_getRightFlatHeaders.md) +- [table\_getRightFooterGroups](functions/table_getRightFooterGroups.md) +- [table\_getRightHeaderGroups](functions/table_getRightHeaderGroups.md) +- [table\_getRightLeafColumns](functions/table_getRightLeafColumns.md) +- [table\_getRightLeafHeaders](functions/table_getRightLeafHeaders.md) +- [table\_getRightTotalSize](functions/table_getRightTotalSize.md) +- [table\_getRightVisibleLeafColumns](functions/table_getRightVisibleLeafColumns.md) +- [table\_getRow](functions/table_getRow.md) +- [table\_getRowCount](functions/table_getRowCount.md) +- [table\_getRowId](functions/table_getRowId.md) +- [table\_getRowModel](functions/table_getRowModel.md) +- [table\_getSelectedRowModel](functions/table_getSelectedRowModel.md) +- [table\_getSortedRowModel](functions/table_getSortedRowModel.md) +- [table\_getToggleAllColumnsVisibilityHandler](functions/table_getToggleAllColumnsVisibilityHandler.md) +- [table\_getToggleAllPageRowsSelectedHandler](functions/table_getToggleAllPageRowsSelectedHandler.md) +- [table\_getToggleAllRowsExpandedHandler](functions/table_getToggleAllRowsExpandedHandler.md) +- [table\_getToggleAllRowsSelectedHandler](functions/table_getToggleAllRowsSelectedHandler.md) +- [table\_getTopRows](functions/table_getTopRows.md) +- [table\_getTotalSize](functions/table_getTotalSize.md) +- [table\_getVisibleFlatColumns](functions/table_getVisibleFlatColumns.md) +- [table\_getVisibleLeafColumns](functions/table_getVisibleLeafColumns.md) +- [table\_lastPage](functions/table_lastPage.md) +- [table\_mergeOptions](functions/table_mergeOptions.md) +- [table\_nextPage](functions/table_nextPage.md) +- [table\_previousPage](functions/table_previousPage.md) +- [table\_reset](functions/table_reset.md) +- [table\_resetColumnFilters](functions/table_resetColumnFilters.md) +- [table\_resetColumnOrder](functions/table_resetColumnOrder.md) +- [table\_resetColumnPinning](functions/table_resetColumnPinning.md) +- [table\_resetColumnSizing](functions/table_resetColumnSizing.md) +- [table\_resetColumnVisibility](functions/table_resetColumnVisibility.md) +- [table\_resetExpanded](functions/table_resetExpanded.md) +- [table\_resetGlobalFilter](functions/table_resetGlobalFilter.md) +- [table\_resetGrouping](functions/table_resetGrouping.md) +- [table\_resetHeaderSizeInfo](functions/table_resetHeaderSizeInfo.md) +- [table\_resetPageIndex](functions/table_resetPageIndex.md) +- [table\_resetPageSize](functions/table_resetPageSize.md) +- [table\_resetPagination](functions/table_resetPagination.md) +- [table\_resetRowPinning](functions/table_resetRowPinning.md) +- [table\_resetRowSelection](functions/table_resetRowSelection.md) +- [table\_resetSorting](functions/table_resetSorting.md) +- [table\_setColumnFilters](functions/table_setColumnFilters.md) +- [table\_setColumnOrder](functions/table_setColumnOrder.md) +- [table\_setColumnPinning](functions/table_setColumnPinning.md) +- [table\_setColumnResizing](functions/table_setColumnResizing.md) +- [table\_setColumnSizing](functions/table_setColumnSizing.md) +- [table\_setColumnVisibility](functions/table_setColumnVisibility.md) +- [table\_setExpanded](functions/table_setExpanded.md) +- [table\_setGlobalFilter](functions/table_setGlobalFilter.md) +- [table\_setGrouping](functions/table_setGrouping.md) +- [table\_setOptions](functions/table_setOptions.md) +- [table\_setPageIndex](functions/table_setPageIndex.md) +- [table\_setPageSize](functions/table_setPageSize.md) +- [table\_setPagination](functions/table_setPagination.md) +- [table\_setRowPinning](functions/table_setRowPinning.md) +- [table\_setRowSelection](functions/table_setRowSelection.md) +- [table\_setSorting](functions/table_setSorting.md) +- [table\_toggleAllColumnsVisible](functions/table_toggleAllColumnsVisible.md) +- [table\_toggleAllPageRowsSelected](functions/table_toggleAllPageRowsSelected.md) +- [table\_toggleAllRowsExpanded](functions/table_toggleAllRowsExpanded.md) +- [table\_toggleAllRowsSelected](functions/table_toggleAllRowsSelected.md) +- [tableFeatures](functions/tableFeatures.md) +- [tableMemo](functions/tableMemo.md) +- [tableOptions](functions/tableOptions.md) diff --git a/docs/reference/interfaces/API.md b/docs/reference/interfaces/API.md new file mode 100644 index 0000000000..0db647d0fb --- /dev/null +++ b/docs/reference/interfaces/API.md @@ -0,0 +1,58 @@ +--- +id: API +title: API +--- + +# Interface: API\ + +Defined in: [utils.ts:267](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L267) + +## Type Parameters + +### TDeps + +`TDeps` *extends* `ReadonlyArray`\<`any`\> + +### TDepArgs + +`TDepArgs` + +## Properties + +### fn() + +```ts +fn: (...args) => any; +``` + +Defined in: [utils.ts:268](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L268) + +#### Parameters + +##### args + +...`any` + +#### Returns + +`any` + +*** + +### memoDeps()? + +```ts +optional memoDeps: (depArgs?) => any[] | undefined; +``` + +Defined in: [utils.ts:269](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L269) + +#### Parameters + +##### depArgs? + +`any` + +#### Returns + +`any`[] \| `undefined` diff --git a/docs/reference/interfaces/AggregationFns.md b/docs/reference/interfaces/AggregationFns.md new file mode 100644 index 0000000000..a342522625 --- /dev/null +++ b/docs/reference/interfaces/AggregationFns.md @@ -0,0 +1,8 @@ +--- +id: AggregationFns +title: AggregationFns +--- + +# Interface: AggregationFns + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:28](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L28) diff --git a/docs/reference/interfaces/CachedRowModel_Core.md b/docs/reference/interfaces/CachedRowModel_Core.md new file mode 100644 index 0000000000..720835d910 --- /dev/null +++ b/docs/reference/interfaces/CachedRowModel_Core.md @@ -0,0 +1,36 @@ +--- +id: CachedRowModel_Core +title: CachedRowModel_Core +--- + +# Interface: CachedRowModel\_Core\ + +Defined in: [core/row-models/coreRowModelsFeature.types.ts:37](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.types.ts#L37) + +## Extends + +- [`CachedRowModel_Plugins`](CachedRowModel_Plugins.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### coreRowModel() + +```ts +coreRowModel: () => RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.types.ts:41](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.types.ts#L41) + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/CachedRowModel_Expanded.md b/docs/reference/interfaces/CachedRowModel_Expanded.md new file mode 100644 index 0000000000..f6928a1e16 --- /dev/null +++ b/docs/reference/interfaces/CachedRowModel_Expanded.md @@ -0,0 +1,32 @@ +--- +id: CachedRowModel_Expanded +title: CachedRowModel_Expanded +--- + +# Interface: CachedRowModel\_Expanded\ + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:136](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L136) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### expandedRowModel() + +```ts +expandedRowModel: () => RowModel; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:140](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L140) + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/CachedRowModel_Faceted.md b/docs/reference/interfaces/CachedRowModel_Faceted.md new file mode 100644 index 0000000000..63354e1300 --- /dev/null +++ b/docs/reference/interfaces/CachedRowModel_Faceted.md @@ -0,0 +1,84 @@ +--- +id: CachedRowModel_Faceted +title: CachedRowModel_Faceted +--- + +# Interface: CachedRowModel\_Faceted\ + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:72](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L72) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### facetedMinMaxValues()? + +```ts +optional facetedMinMaxValues: (columnId) => [number, number]; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:77](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L77) + +#### Parameters + +##### columnId + +`string` + +#### Returns + +\[`number`, `number`\] + +*** + +### facetedRowModel()? + +```ts +optional facetedRowModel: (columnId) => () => RowModel; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:76](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L76) + +#### Parameters + +##### columnId + +`string` + +#### Returns + +```ts +(): RowModel; +``` + +##### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### facetedUniqueValues()? + +```ts +optional facetedUniqueValues: (columnId) => Map; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:78](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L78) + +#### Parameters + +##### columnId + +`string` + +#### Returns + +`Map`\<`any`, `number`\> diff --git a/docs/reference/interfaces/CachedRowModel_Filtered.md b/docs/reference/interfaces/CachedRowModel_Filtered.md new file mode 100644 index 0000000000..4c61767176 --- /dev/null +++ b/docs/reference/interfaces/CachedRowModel_Filtered.md @@ -0,0 +1,32 @@ +--- +id: CachedRowModel_Filtered +title: CachedRowModel_Filtered +--- + +# Interface: CachedRowModel\_Filtered\ + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:214](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L214) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### filteredRowModel() + +```ts +filteredRowModel: () => RowModel; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:218](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L218) + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/CachedRowModel_Grouped.md b/docs/reference/interfaces/CachedRowModel_Grouped.md new file mode 100644 index 0000000000..0193aa521a --- /dev/null +++ b/docs/reference/interfaces/CachedRowModel_Grouped.md @@ -0,0 +1,32 @@ +--- +id: CachedRowModel_Grouped +title: CachedRowModel_Grouped +--- + +# Interface: CachedRowModel\_Grouped\ + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:213](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L213) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### groupedRowModel() + +```ts +groupedRowModel: () => RowModel; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:217](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L217) + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/CachedRowModel_Paginated.md b/docs/reference/interfaces/CachedRowModel_Paginated.md new file mode 100644 index 0000000000..65397dd426 --- /dev/null +++ b/docs/reference/interfaces/CachedRowModel_Paginated.md @@ -0,0 +1,32 @@ +--- +id: CachedRowModel_Paginated +title: CachedRowModel_Paginated +--- + +# Interface: CachedRowModel\_Paginated\ + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:136](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L136) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### paginatedRowModel() + +```ts +paginatedRowModel: () => RowModel; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:140](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L140) + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/CachedRowModel_Plugins.md b/docs/reference/interfaces/CachedRowModel_Plugins.md new file mode 100644 index 0000000000..22445fe2e2 --- /dev/null +++ b/docs/reference/interfaces/CachedRowModel_Plugins.md @@ -0,0 +1,12 @@ +--- +id: CachedRowModel_Plugins +title: CachedRowModel_Plugins +--- + +# Interface: CachedRowModel\_Plugins + +Defined in: [core/row-models/coreRowModelsFeature.types.ts:35](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.types.ts#L35) + +## Extended by + +- [`CachedRowModel_Core`](CachedRowModel_Core.md) diff --git a/docs/reference/interfaces/CachedRowModel_Sorted.md b/docs/reference/interfaces/CachedRowModel_Sorted.md new file mode 100644 index 0000000000..56ed9e74ce --- /dev/null +++ b/docs/reference/interfaces/CachedRowModel_Sorted.md @@ -0,0 +1,32 @@ +--- +id: CachedRowModel_Sorted +title: CachedRowModel_Sorted +--- + +# Interface: CachedRowModel\_Sorted\ + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:224](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L224) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### sortedRowModel() + +```ts +sortedRowModel: () => RowModel; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:228](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L228) + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/CachedRowModels_Plugins.md b/docs/reference/interfaces/CachedRowModels_Plugins.md new file mode 100644 index 0000000000..178e9a9cfc --- /dev/null +++ b/docs/reference/interfaces/CachedRowModels_Plugins.md @@ -0,0 +1,18 @@ +--- +id: CachedRowModels_Plugins +title: CachedRowModels_Plugins +--- + +# Interface: CachedRowModels\_Plugins\ + +Defined in: [types/RowModel.ts:87](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/RowModel.ts#L87) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) diff --git a/docs/reference/interfaces/CellContext.md b/docs/reference/interfaces/CellContext.md new file mode 100644 index 0000000000..cddb9a6e7c --- /dev/null +++ b/docs/reference/interfaces/CellContext.md @@ -0,0 +1,82 @@ +--- +id: CellContext +title: CellContext +--- + +# Interface: CellContext\ + +Defined in: [core/cells/coreCellsFeature.types.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L8) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) + +## Properties + +### cell + +```ts +cell: Cell; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:13](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L13) + +*** + +### column + +```ts +column: Column; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L14) + +*** + +### getValue + +```ts +getValue: Getter; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L15) + +*** + +### renderValue + +```ts +renderValue: Getter; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L16) + +*** + +### row + +```ts +row: Row; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L17) + +*** + +### table + +```ts +table: Table; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L18) diff --git a/docs/reference/interfaces/Cell_Cell.md b/docs/reference/interfaces/Cell_Cell.md new file mode 100644 index 0000000000..e2fe107a6b --- /dev/null +++ b/docs/reference/interfaces/Cell_Cell.md @@ -0,0 +1,134 @@ +--- +id: Cell_Cell +title: Cell_Cell +--- + +# Interface: Cell\_Cell\ + +Defined in: [core/cells/coreCellsFeature.types.ts:44](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L44) + +## Extends + +- [`Cell_CoreProperties`](Cell_CoreProperties.md)\<`TFeatures`, `TData`, `TValue`\> + +## Extended by + +- [`Cell_Core`](Cell_Core.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) + +## Properties + +### column + +```ts +column: Column; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L29) + +The associated Column object for the cell. + +#### Inherited from + +[`Cell_CoreProperties`](Cell_CoreProperties.md).[`column`](Cell_CoreProperties.md#column) + +*** + +### getContext() + +```ts +getContext: () => CellContext; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:52](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L52) + +Returns the rendering context (or props) for cell-based components like cells and aggregated cells. Use these props with your framework's `flexRender` utility to render these using the template of your choice: + +#### Returns + +[`CellContext`](CellContext.md)\<`TFeatures`, `TData`, `TValue`\> + +*** + +### getValue + +```ts +getValue: Getter; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:56](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L56) + +Returns the value for the cell, accessed via the associated column's accessor key or accessor function. + +*** + +### id + +```ts +id: string; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:33](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L33) + +The unique ID for the cell across the entire table. + +#### Inherited from + +[`Cell_CoreProperties`](Cell_CoreProperties.md).[`id`](Cell_CoreProperties.md#id) + +*** + +### renderValue + +```ts +renderValue: Getter; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:60](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L60) + +Renders the value for a cell the same as `getValue`, but will return the `renderFallbackValue` if no value is found. + +*** + +### row + +```ts +row: Row; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:37](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L37) + +The associated Row object for the cell. + +#### Inherited from + +[`Cell_CoreProperties`](Cell_CoreProperties.md).[`row`](Cell_CoreProperties.md#row) + +*** + +### table + +```ts +table: Table_Internal; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:41](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L41) + +Reference to the parent table instance. + +#### Inherited from + +[`Cell_CoreProperties`](Cell_CoreProperties.md).[`table`](Cell_CoreProperties.md#table) diff --git a/docs/reference/interfaces/Cell_ColumnGrouping.md b/docs/reference/interfaces/Cell_ColumnGrouping.md new file mode 100644 index 0000000000..e4b7682d8f --- /dev/null +++ b/docs/reference/interfaces/Cell_ColumnGrouping.md @@ -0,0 +1,56 @@ +--- +id: Cell_ColumnGrouping +title: Cell_ColumnGrouping +--- + +# Interface: Cell\_ColumnGrouping + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:132](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L132) + +## Properties + +### getIsAggregated() + +```ts +getIsAggregated: () => boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:136](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L136) + +Returns whether or not the cell is currently aggregated. + +#### Returns + +`boolean` + +*** + +### getIsGrouped() + +```ts +getIsGrouped: () => boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:140](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L140) + +Returns whether or not the cell is currently grouped. + +#### Returns + +`boolean` + +*** + +### getIsPlaceholder() + +```ts +getIsPlaceholder: () => boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:144](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L144) + +Returns whether or not the cell is currently a placeholder cell. + +#### Returns + +`boolean` diff --git a/docs/reference/interfaces/Cell_Core.md b/docs/reference/interfaces/Cell_Core.md new file mode 100644 index 0000000000..fa1c036d2e --- /dev/null +++ b/docs/reference/interfaces/Cell_Core.md @@ -0,0 +1,142 @@ +--- +id: Cell_Core +title: Cell_Core +--- + +# Interface: Cell\_Core\ + +Defined in: [types/Cell.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Cell.ts#L16) + +## Extends + +- [`Cell_Cell`](Cell_Cell.md)\<`TFeatures`, `TData`, `TValue`\> + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) + +## Properties + +### column + +```ts +column: Column; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L29) + +The associated Column object for the cell. + +#### Inherited from + +[`Cell_Cell`](Cell_Cell.md).[`column`](Cell_Cell.md#column) + +*** + +### getContext() + +```ts +getContext: () => CellContext; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:52](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L52) + +Returns the rendering context (or props) for cell-based components like cells and aggregated cells. Use these props with your framework's `flexRender` utility to render these using the template of your choice: + +#### Returns + +[`CellContext`](CellContext.md)\<`TFeatures`, `TData`, `TValue`\> + +#### Inherited from + +[`Cell_Cell`](Cell_Cell.md).[`getContext`](Cell_Cell.md#getcontext) + +*** + +### getValue + +```ts +getValue: Getter; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:56](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L56) + +Returns the value for the cell, accessed via the associated column's accessor key or accessor function. + +#### Inherited from + +[`Cell_Cell`](Cell_Cell.md).[`getValue`](Cell_Cell.md#getvalue) + +*** + +### id + +```ts +id: string; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:33](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L33) + +The unique ID for the cell across the entire table. + +#### Inherited from + +[`Cell_Cell`](Cell_Cell.md).[`id`](Cell_Cell.md#id) + +*** + +### renderValue + +```ts +renderValue: Getter; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:60](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L60) + +Renders the value for a cell the same as `getValue`, but will return the `renderFallbackValue` if no value is found. + +#### Inherited from + +[`Cell_Cell`](Cell_Cell.md).[`renderValue`](Cell_Cell.md#rendervalue) + +*** + +### row + +```ts +row: Row; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:37](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L37) + +The associated Row object for the cell. + +#### Inherited from + +[`Cell_Cell`](Cell_Cell.md).[`row`](Cell_Cell.md#row) + +*** + +### table + +```ts +table: Table_Internal; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:41](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L41) + +Reference to the parent table instance. + +#### Inherited from + +[`Cell_Cell`](Cell_Cell.md).[`table`](Cell_Cell.md#table) diff --git a/docs/reference/interfaces/Cell_CoreProperties.md b/docs/reference/interfaces/Cell_CoreProperties.md new file mode 100644 index 0000000000..67a3293126 --- /dev/null +++ b/docs/reference/interfaces/Cell_CoreProperties.md @@ -0,0 +1,74 @@ +--- +id: Cell_CoreProperties +title: Cell_CoreProperties +--- + +# Interface: Cell\_CoreProperties\ + +Defined in: [core/cells/coreCellsFeature.types.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L21) + +## Extended by + +- [`Cell_Cell`](Cell_Cell.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) + +## Properties + +### column + +```ts +column: Column; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L29) + +The associated Column object for the cell. + +*** + +### id + +```ts +id: string; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:33](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L33) + +The unique ID for the cell across the entire table. + +*** + +### row + +```ts +row: Row; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:37](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L37) + +The associated Row object for the cell. + +*** + +### table + +```ts +table: Table_Internal; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:41](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L41) + +Reference to the parent table instance. diff --git a/docs/reference/interfaces/Cell_Plugins.md b/docs/reference/interfaces/Cell_Plugins.md new file mode 100644 index 0000000000..a751054438 --- /dev/null +++ b/docs/reference/interfaces/Cell_Plugins.md @@ -0,0 +1,25 @@ +--- +id: Cell_Plugins +title: Cell_Plugins +--- + +# Interface: Cell\_Plugins\ + +Defined in: [types/Cell.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Cell.ts#L10) + +Use this interface as a target for declaration merging to add your own plugin properties. +Note: This will affect the types of all tables in your project. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) diff --git a/docs/reference/interfaces/ColumnDef_ColumnFiltering.md b/docs/reference/interfaces/ColumnDef_ColumnFiltering.md new file mode 100644 index 0000000000..3128dc63b7 --- /dev/null +++ b/docs/reference/interfaces/ColumnDef_ColumnFiltering.md @@ -0,0 +1,42 @@ +--- +id: ColumnDef_ColumnFiltering +title: ColumnDef_ColumnFiltering +--- + +# Interface: ColumnDef\_ColumnFiltering\ + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:81](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L81) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### enableColumnFilter? + +```ts +optional enableColumnFilter: boolean; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:88](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L88) + +Enables/disables the **column** filter for this column. + +*** + +### filterFn? + +```ts +optional filterFn: FilterFnOption; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:92](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L92) + +The filter function to use with this column. Can be the name of a built-in filter function or a custom filter function. diff --git a/docs/reference/interfaces/ColumnDef_ColumnGrouping.md b/docs/reference/interfaces/ColumnDef_ColumnGrouping.md new file mode 100644 index 0000000000..e1d57d7f83 --- /dev/null +++ b/docs/reference/interfaces/ColumnDef_ColumnGrouping.md @@ -0,0 +1,80 @@ +--- +id: ColumnDef_ColumnGrouping +title: ColumnDef_ColumnGrouping +--- + +# Interface: ColumnDef\_ColumnGrouping\ + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:53](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L53) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) + +## Properties + +### aggregatedCell? + +```ts +optional aggregatedCell: ColumnDefTemplate["getContext"]>>; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:61](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L61) + +The cell to display each row for the column if the cell is an aggregate. If a function is passed, it will be passed a props object with the context of the cell and should return the property type for your adapter (the exact type depends on the adapter being used). + +*** + +### aggregationFn? + +```ts +optional aggregationFn: AggregationFnOption; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:67](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L67) + +The resolved aggregation function for the column. + +*** + +### enableGrouping? + +```ts +optional enableGrouping: boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:71](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L71) + +Enables/disables grouping for this column. + +*** + +### getGroupingValue()? + +```ts +optional getGroupingValue: (row) => any; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:75](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L75) + +Specify a value to be used for grouping rows on this column. If this option is not specified, the value derived from `accessorKey` / `accessorFn` will be used instead. + +#### Parameters + +##### row + +`TData` + +#### Returns + +`any` diff --git a/docs/reference/interfaces/ColumnDef_ColumnPinning.md b/docs/reference/interfaces/ColumnDef_ColumnPinning.md new file mode 100644 index 0000000000..b57243b7dd --- /dev/null +++ b/docs/reference/interfaces/ColumnDef_ColumnPinning.md @@ -0,0 +1,20 @@ +--- +id: ColumnDef_ColumnPinning +title: ColumnDef_ColumnPinning +--- + +# Interface: ColumnDef\_ColumnPinning + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L34) + +## Properties + +### enablePinning? + +```ts +optional enablePinning: boolean; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L38) + +Enables/disables column pinning for this column. Defaults to `true`. diff --git a/docs/reference/interfaces/ColumnDef_ColumnResizing.md b/docs/reference/interfaces/ColumnDef_ColumnResizing.md new file mode 100644 index 0000000000..f5f22b7ef6 --- /dev/null +++ b/docs/reference/interfaces/ColumnDef_ColumnResizing.md @@ -0,0 +1,20 @@ +--- +id: ColumnDef_ColumnResizing +title: ColumnDef_ColumnResizing +--- + +# Interface: ColumnDef\_ColumnResizing + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:55](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L55) + +## Properties + +### enableResizing? + +```ts +optional enableResizing: boolean; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:59](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L59) + +Enables or disables column resizing for the column. diff --git a/docs/reference/interfaces/ColumnDef_ColumnSizing.md b/docs/reference/interfaces/ColumnDef_ColumnSizing.md new file mode 100644 index 0000000000..6180e9f82d --- /dev/null +++ b/docs/reference/interfaces/ColumnDef_ColumnSizing.md @@ -0,0 +1,44 @@ +--- +id: ColumnDef_ColumnSizing +title: ColumnDef_ColumnSizing +--- + +# Interface: ColumnDef\_ColumnSizing + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:49](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L49) + +## Properties + +### maxSize? + +```ts +optional maxSize: number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:53](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L53) + +The maximum allowed size for the column + +*** + +### minSize? + +```ts +optional minSize: number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:57](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L57) + +The minimum allowed size for the column + +*** + +### size? + +```ts +optional size: number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:61](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L61) + +The desired size for the column diff --git a/docs/reference/interfaces/ColumnDef_ColumnVisibility.md b/docs/reference/interfaces/ColumnDef_ColumnVisibility.md new file mode 100644 index 0000000000..b435ce2963 --- /dev/null +++ b/docs/reference/interfaces/ColumnDef_ColumnVisibility.md @@ -0,0 +1,20 @@ +--- +id: ColumnDef_ColumnVisibility +title: ColumnDef_ColumnVisibility +--- + +# Interface: ColumnDef\_ColumnVisibility + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:66](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L66) + +## Properties + +### enableHiding? + +```ts +optional enableHiding: boolean; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:70](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L70) + +Enables/disables column hiding for this column. Defaults to `true`. diff --git a/docs/reference/interfaces/ColumnDef_GlobalFiltering.md b/docs/reference/interfaces/ColumnDef_GlobalFiltering.md new file mode 100644 index 0000000000..b55f87b831 --- /dev/null +++ b/docs/reference/interfaces/ColumnDef_GlobalFiltering.md @@ -0,0 +1,20 @@ +--- +id: ColumnDef_GlobalFiltering +title: ColumnDef_GlobalFiltering +--- + +# Interface: ColumnDef\_GlobalFiltering + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L18) + +## Properties + +### enableGlobalFilter? + +```ts +optional enableGlobalFilter: boolean; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L22) + +Enables/disables the **global** filter for this column. diff --git a/docs/reference/interfaces/ColumnDef_Plugins.md b/docs/reference/interfaces/ColumnDef_Plugins.md new file mode 100644 index 0000000000..0f739f438f --- /dev/null +++ b/docs/reference/interfaces/ColumnDef_Plugins.md @@ -0,0 +1,25 @@ +--- +id: ColumnDef_Plugins +title: ColumnDef_Plugins +--- + +# Interface: ColumnDef\_Plugins\ + +Defined in: [types/ColumnDef.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L18) + +Use this interface as a target for declaration merging to add your own plugin properties. +Note: This will affect the types of all tables in your project. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) diff --git a/docs/reference/interfaces/ColumnDef_RowSorting.md b/docs/reference/interfaces/ColumnDef_RowSorting.md new file mode 100644 index 0000000000..c4d521db93 --- /dev/null +++ b/docs/reference/interfaces/ColumnDef_RowSorting.md @@ -0,0 +1,98 @@ +--- +id: ColumnDef_RowSorting +title: ColumnDef_RowSorting +--- + +# Interface: ColumnDef\_RowSorting\ + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:51](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L51) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### enableMultiSort? + +```ts +optional enableMultiSort: boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:58](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L58) + +Enables/Disables multi-sorting for this column. + +*** + +### enableSorting? + +```ts +optional enableSorting: boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:62](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L62) + +Enables/Disables sorting for this column. + +*** + +### invertSorting? + +```ts +optional invertSorting: boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:66](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L66) + +Inverts the order of the sorting for this column. This is useful for values that have an inverted best/worst scale where lower numbers are better, eg. a ranking (1st, 2nd, 3rd) or golf-like scoring + +*** + +### sortDescFirst? + +```ts +optional sortDescFirst: boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:70](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L70) + +Set to `true` for sorting toggles on this column to start in the descending direction. + +*** + +### sortFn? + +```ts +optional sortFn: SortFnOption; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:76](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L76) + +The sorting function to use with this column. +- A `string` referencing a built-in sorting function +- A custom sorting function + +*** + +### sortUndefined? + +```ts +optional sortUndefined: false | 1 | -1 | "first" | "last"; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:86](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L86) + +The priority of undefined values when sorting this column. +- `false` + - Undefined values will be considered tied and need to be sorted by the next column filter or original index (whichever applies) +- `-1` + - Undefined values will be sorted with higher priority (ascending) (if ascending, undefined will appear on the beginning of the list) +- `1` + - Undefined values will be sorted with lower priority (descending) (if ascending, undefined will appear on the end of the list) diff --git a/docs/reference/interfaces/ColumnDefaultOptions.md b/docs/reference/interfaces/ColumnDefaultOptions.md new file mode 100644 index 0000000000..9acb1cbd8d --- /dev/null +++ b/docs/reference/interfaces/ColumnDefaultOptions.md @@ -0,0 +1,28 @@ +--- +id: ColumnDefaultOptions +title: ColumnDefaultOptions +--- + +# Interface: ColumnDefaultOptions + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:147](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L147) + +## Properties + +### enableGrouping + +```ts +enableGrouping: boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:148](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L148) + +*** + +### onGroupingChange + +```ts +onGroupingChange: OnChangeFn; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:149](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L149) diff --git a/docs/reference/interfaces/ColumnFilter.md b/docs/reference/interfaces/ColumnFilter.md new file mode 100644 index 0000000000..d19677e9c5 --- /dev/null +++ b/docs/reference/interfaces/ColumnFilter.md @@ -0,0 +1,28 @@ +--- +id: ColumnFilter +title: ColumnFilter +--- + +# Interface: ColumnFilter + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:24](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L24) + +## Properties + +### id + +```ts +id: string; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:25](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L25) + +*** + +### value + +```ts +value: unknown; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L26) diff --git a/docs/reference/interfaces/ColumnMeta.md b/docs/reference/interfaces/ColumnMeta.md new file mode 100644 index 0000000000..9ecede6d4e --- /dev/null +++ b/docs/reference/interfaces/ColumnMeta.md @@ -0,0 +1,22 @@ +--- +id: ColumnMeta +title: ColumnMeta +--- + +# Interface: ColumnMeta\ + +Defined in: [types/ColumnDef.ts:24](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L24) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) diff --git a/docs/reference/interfaces/ColumnOrderDefaultOptions.md b/docs/reference/interfaces/ColumnOrderDefaultOptions.md new file mode 100644 index 0000000000..edf1bd0337 --- /dev/null +++ b/docs/reference/interfaces/ColumnOrderDefaultOptions.md @@ -0,0 +1,18 @@ +--- +id: ColumnOrderDefaultOptions +title: ColumnOrderDefaultOptions +--- + +# Interface: ColumnOrderDefaultOptions + +Defined in: [features/column-ordering/columnOrderingFeature.types.ts:33](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.types.ts#L33) + +## Properties + +### onColumnOrderChange + +```ts +onColumnOrderChange: OnChangeFn; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.types.ts#L34) diff --git a/docs/reference/interfaces/ColumnPinningDefaultOptions.md b/docs/reference/interfaces/ColumnPinningDefaultOptions.md new file mode 100644 index 0000000000..0e6bf24b07 --- /dev/null +++ b/docs/reference/interfaces/ColumnPinningDefaultOptions.md @@ -0,0 +1,18 @@ +--- +id: ColumnPinningDefaultOptions +title: ColumnPinningDefaultOptions +--- + +# Interface: ColumnPinningDefaultOptions + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L30) + +## Properties + +### onColumnPinningChange + +```ts +onColumnPinningChange: OnChangeFn; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:31](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L31) diff --git a/docs/reference/interfaces/ColumnPinningState.md b/docs/reference/interfaces/ColumnPinningState.md new file mode 100644 index 0000000000..7e30ac30ab --- /dev/null +++ b/docs/reference/interfaces/ColumnPinningState.md @@ -0,0 +1,28 @@ +--- +id: ColumnPinningState +title: ColumnPinningState +--- + +# Interface: ColumnPinningState + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L10) + +## Properties + +### left + +```ts +left: string[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L11) + +*** + +### right + +```ts +right: string[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L12) diff --git a/docs/reference/interfaces/ColumnSort.md b/docs/reference/interfaces/ColumnSort.md new file mode 100644 index 0000000000..0737a1eba0 --- /dev/null +++ b/docs/reference/interfaces/ColumnSort.md @@ -0,0 +1,28 @@ +--- +id: ColumnSort +title: ColumnSort +--- + +# Interface: ColumnSort + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L10) + +## Properties + +### desc + +```ts +desc: boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L11) + +*** + +### id + +```ts +id: string; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L12) diff --git a/docs/reference/interfaces/Column_Column.md b/docs/reference/interfaces/Column_Column.md new file mode 100644 index 0000000000..64e4ed69d8 --- /dev/null +++ b/docs/reference/interfaces/Column_Column.md @@ -0,0 +1,177 @@ +--- +id: Column_Column +title: Column_Column +--- + +# Interface: Column\_Column\ + +Defined in: [core/columns/coreColumnsFeature.types.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L45) + +## Extends + +- [`Column_CoreProperties`](Column_CoreProperties.md)\<`TFeatures`, `TData`, `TValue`\> + +## Extended by + +- [`Column_Core`](Column_Core.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) + +## Properties + +### accessorFn? + +```ts +optional accessorFn: AccessorFn; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L15) + +The resolved accessor function to use when extracting the value for the column from each row. Will only be defined if the column def has a valid accessor key or function defined. + +#### Inherited from + +[`Column_CoreProperties`](Column_CoreProperties.md).[`accessorFn`](Column_CoreProperties.md#accessorfn) + +*** + +### columnDef + +```ts +columnDef: ColumnDef; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:19](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L19) + +The original column def used to create the column. + +#### Inherited from + +[`Column_CoreProperties`](Column_CoreProperties.md).[`columnDef`](Column_CoreProperties.md#columndef) + +*** + +### columns + +```ts +columns: Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L23) + +The child column (if the column is a group column). Will be an empty array if the column is not a group column. + +#### Inherited from + +[`Column_CoreProperties`](Column_CoreProperties.md).[`columns`](Column_CoreProperties.md#columns) + +*** + +### depth + +```ts +depth: number; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L27) + +The depth of the column (if grouped) relative to the root column def array. + +#### Inherited from + +[`Column_CoreProperties`](Column_CoreProperties.md).[`depth`](Column_CoreProperties.md#depth) + +*** + +### getFlatColumns() + +```ts +getFlatColumns: () => Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:53](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L53) + +Returns the flattened array of this column and all child/grand-child columns for this column. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\>[] + +*** + +### getLeafColumns() + +```ts +getLeafColumns: () => Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:57](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L57) + +Returns an array of all leaf-node columns for this column. If a column has no children, it is considered the only leaf-node column. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\>[] + +*** + +### id + +```ts +id: string; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L34) + +The resolved unique identifier for the column resolved in this priority: + - A manual `id` property from the column def + - The accessor key from the column def + - The header string from the column def + +#### Inherited from + +[`Column_CoreProperties`](Column_CoreProperties.md).[`id`](Column_CoreProperties.md#id) + +*** + +### parent? + +```ts +optional parent: Column; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L38) + +The parent column for this column. Will be undefined if this is a root column. + +#### Inherited from + +[`Column_CoreProperties`](Column_CoreProperties.md).[`parent`](Column_CoreProperties.md#parent) + +*** + +### table + +```ts +table: Table_Internal; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L42) + +Reference to the parent table instance. + +#### Inherited from + +[`Column_CoreProperties`](Column_CoreProperties.md).[`table`](Column_CoreProperties.md#table) diff --git a/docs/reference/interfaces/Column_ColumnFaceting.md b/docs/reference/interfaces/Column_ColumnFaceting.md new file mode 100644 index 0000000000..4aa49e99c3 --- /dev/null +++ b/docs/reference/interfaces/Column_ColumnFaceting.md @@ -0,0 +1,66 @@ +--- +id: Column_ColumnFaceting +title: Column_ColumnFaceting +--- + +# Interface: Column\_ColumnFaceting\ + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:6](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L6) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getFacetedMinMaxValues() + +```ts +getFacetedMinMaxValues: () => [number, number] | undefined; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:13](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L13) + +A function that **computes and returns** a min/max tuple derived from `column.getFacetedRowModel`. Useful for displaying faceted result values. + +#### Returns + +\[`number`, `number`\] \| `undefined` + +*** + +### getFacetedRowModel() + +```ts +getFacetedRowModel: () => RowModel; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L17) + +A function that **computes and returns** a row model with all other column filters applied, excluding its own filter. Useful for displaying faceted result counts. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### getFacetedUniqueValues() + +```ts +getFacetedUniqueValues: () => Map; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L21) + +Returns a `Map` of unique values and their occurrences derived from `column.getFacetedRowModel`. Useful for displaying faceted result values. + +#### Returns + +`Map`\<`any`, `number`\> diff --git a/docs/reference/interfaces/Column_ColumnFiltering.md b/docs/reference/interfaces/Column_ColumnFiltering.md new file mode 100644 index 0000000000..6370e2c50c --- /dev/null +++ b/docs/reference/interfaces/Column_ColumnFiltering.md @@ -0,0 +1,136 @@ +--- +id: Column_ColumnFiltering +title: Column_ColumnFiltering +--- + +# Interface: Column\_ColumnFiltering\ + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:95](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L95) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getAutoFilterFn() + +```ts +getAutoFilterFn: () => FilterFn; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:102](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L102) + +Returns an automatically calculated filter function for the column based off of the columns first known value. + +#### Returns + +[`FilterFn`](FilterFn.md)\<`TFeatures`, `TData`\> + +*** + +### getCanFilter() + +```ts +getCanFilter: () => boolean; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:106](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L106) + +Returns whether or not the column can be **column** filtered. + +#### Returns + +`boolean` + +*** + +### getFilterFn() + +```ts +getFilterFn: () => FilterFn; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:110](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L110) + +Returns the filter function (either user-defined or automatic, depending on configuration) for the columnId specified. + +#### Returns + +[`FilterFn`](FilterFn.md)\<`TFeatures`, `TData`\> + +*** + +### getFilterIndex() + +```ts +getFilterIndex: () => number; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:114](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L114) + +Returns the index (including `-1`) of the column filter in the table's `state.columnFilters` array. + +#### Returns + +`number` + +*** + +### getFilterValue() + +```ts +getFilterValue: () => unknown; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:118](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L118) + +Returns the current filter value for the column. + +#### Returns + +`unknown` + +*** + +### getIsFiltered() + +```ts +getIsFiltered: () => boolean; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:122](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L122) + +Returns whether or not the column is currently filtered. + +#### Returns + +`boolean` + +*** + +### setFilterValue() + +```ts +setFilterValue: (updater) => void; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:126](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L126) + +A function that sets the current filter value for the column. You can pass it a value or an updater function for immutability-safe operations on existing values. + +#### Parameters + +##### updater + +`any` + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Column_ColumnGrouping.md b/docs/reference/interfaces/Column_ColumnGrouping.md new file mode 100644 index 0000000000..e7aef8f88b --- /dev/null +++ b/docs/reference/interfaces/Column_ColumnGrouping.md @@ -0,0 +1,142 @@ +--- +id: Column_ColumnGrouping +title: Column_ColumnGrouping +--- + +# Interface: Column\_ColumnGrouping\ + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:78](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L78) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getAggregationFn() + +```ts +getAggregationFn: () => + | AggregationFn + | undefined; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:85](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L85) + +Returns the aggregation function for the column. + +#### Returns + + \| [`AggregationFn`](../type-aliases/AggregationFn.md)\<`TFeatures`, `TData`\> + \| `undefined` + +*** + +### getAutoAggregationFn() + +```ts +getAutoAggregationFn: () => + | AggregationFn + | undefined; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:89](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L89) + +Returns the automatically inferred aggregation function for the column. + +#### Returns + + \| [`AggregationFn`](../type-aliases/AggregationFn.md)\<`TFeatures`, `TData`\> + \| `undefined` + +*** + +### getCanGroup() + +```ts +getCanGroup: () => boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:93](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L93) + +Returns whether or not the column can be grouped. + +#### Returns + +`boolean` + +*** + +### getGroupedIndex() + +```ts +getGroupedIndex: () => number; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:97](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L97) + +Returns the index of the column in the grouping state. + +#### Returns + +`number` + +*** + +### getIsGrouped() + +```ts +getIsGrouped: () => boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:101](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L101) + +Returns whether or not the column is currently grouped. + +#### Returns + +`boolean` + +*** + +### getToggleGroupingHandler() + +```ts +getToggleGroupingHandler: () => () => void; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:105](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L105) + +Returns a function that toggles the grouping state of the column. This is useful for passing to the `onClick` prop of a button. + +#### Returns + +```ts +(): void; +``` + +##### Returns + +`void` + +*** + +### toggleGrouping() + +```ts +toggleGrouping: () => void; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:109](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L109) + +Toggles the grouping state of the column. + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Column_ColumnOrdering.md b/docs/reference/interfaces/Column_ColumnOrdering.md new file mode 100644 index 0000000000..87c4f17d34 --- /dev/null +++ b/docs/reference/interfaces/Column_ColumnOrdering.md @@ -0,0 +1,74 @@ +--- +id: Column_ColumnOrdering +title: Column_ColumnOrdering +--- + +# Interface: Column\_ColumnOrdering + +Defined in: [features/column-ordering/columnOrderingFeature.types.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.types.ts#L18) + +## Properties + +### getIndex() + +```ts +getIndex: (position?) => number; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.types.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.types.ts#L22) + +Returns the index of the column in the order of the visible columns. Optionally pass a `position` parameter to get the index of the column in a sub-section of the table + +#### Parameters + +##### position? + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) | `"center"` + +#### Returns + +`number` + +*** + +### getIsFirstColumn() + +```ts +getIsFirstColumn: (position?) => boolean; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.types.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.types.ts#L26) + +Returns `true` if the column is the first column in the order of the visible columns. Optionally pass a `position` parameter to check if the column is the first in a sub-section of the table. + +#### Parameters + +##### position? + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) | `"center"` + +#### Returns + +`boolean` + +*** + +### getIsLastColumn() + +```ts +getIsLastColumn: (position?) => boolean; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.types.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.types.ts#L30) + +Returns `true` if the column is the last column in the order of the visible columns. Optionally pass a `position` parameter to check if the column is the last in a sub-section of the table. + +#### Parameters + +##### position? + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) | `"center"` + +#### Returns + +`boolean` diff --git a/docs/reference/interfaces/Column_ColumnPinning.md b/docs/reference/interfaces/Column_ColumnPinning.md new file mode 100644 index 0000000000..462ed38be5 --- /dev/null +++ b/docs/reference/interfaces/Column_ColumnPinning.md @@ -0,0 +1,78 @@ +--- +id: Column_ColumnPinning +title: Column_ColumnPinning +--- + +# Interface: Column\_ColumnPinning + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:41](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L41) + +## Properties + +### getCanPin() + +```ts +getCanPin: () => boolean; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L45) + +Returns whether or not the column can be pinned. + +#### Returns + +`boolean` + +*** + +### getIsPinned() + +```ts +getIsPinned: () => ColumnPinningPosition; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:49](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L49) + +Returns the pinned position of the column. (`'left'`, `'right'` or `false`) + +#### Returns + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) + +*** + +### getPinnedIndex() + +```ts +getPinnedIndex: () => number; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:53](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L53) + +Returns the numeric pinned index of the column within a pinned column group. + +#### Returns + +`number` + +*** + +### pin() + +```ts +pin: (position) => void; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:57](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L57) + +Pins a column to the `'left'` or `'right'`, or unpins the column to the center if `false` is passed. + +#### Parameters + +##### position + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Column_ColumnResizing.md b/docs/reference/interfaces/Column_ColumnResizing.md new file mode 100644 index 0000000000..65f5cdb51c --- /dev/null +++ b/docs/reference/interfaces/Column_ColumnResizing.md @@ -0,0 +1,40 @@ +--- +id: Column_ColumnResizing +title: Column_ColumnResizing +--- + +# Interface: Column\_ColumnResizing + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:62](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L62) + +## Properties + +### getCanResize() + +```ts +getCanResize: () => boolean; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:66](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L66) + +Returns `true` if the column can be resized. + +#### Returns + +`boolean` + +*** + +### getIsResizing() + +```ts +getIsResizing: () => boolean; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:70](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L70) + +Returns `true` if the column is currently being resized. + +#### Returns + +`boolean` diff --git a/docs/reference/interfaces/Column_ColumnSizing.md b/docs/reference/interfaces/Column_ColumnSizing.md new file mode 100644 index 0000000000..5f7eb98c76 --- /dev/null +++ b/docs/reference/interfaces/Column_ColumnSizing.md @@ -0,0 +1,84 @@ +--- +id: Column_ColumnSizing +title: Column_ColumnSizing +--- + +# Interface: Column\_ColumnSizing + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:64](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L64) + +## Properties + +### getAfter() + +```ts +getAfter: (position?) => number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:68](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L68) + +Returns the offset measurement along the row-axis (usually the x-axis for standard tables) for the header. This is effectively a sum of the offset measurements of all succeeding (right) headers in relation to the current column. + +#### Parameters + +##### position? + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) | `"center"` + +#### Returns + +`number` + +*** + +### getSize() + +```ts +getSize: () => number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:72](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L72) + +Returns the current size of the column. + +#### Returns + +`number` + +*** + +### getStart() + +```ts +getStart: (position?) => number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:76](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L76) + +Returns the offset measurement along the row-axis (usually the x-axis for standard tables) for the header. This is effectively a sum of the offset measurements of all preceding (left) headers in relation to the current column. + +#### Parameters + +##### position? + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) | `"center"` + +#### Returns + +`number` + +*** + +### resetSize() + +```ts +resetSize: () => void; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:80](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L80) + +Resets the column to its initial size. + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Column_ColumnVisibility.md b/docs/reference/interfaces/Column_ColumnVisibility.md new file mode 100644 index 0000000000..d9a4fd2cb3 --- /dev/null +++ b/docs/reference/interfaces/Column_ColumnVisibility.md @@ -0,0 +1,90 @@ +--- +id: Column_ColumnVisibility +title: Column_ColumnVisibility +--- + +# Interface: Column\_ColumnVisibility + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:84](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L84) + +## Properties + +### getCanHide() + +```ts +getCanHide: () => boolean; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:88](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L88) + +Returns whether the column can be hidden + +#### Returns + +`boolean` + +*** + +### getIsVisible() + +```ts +getIsVisible: () => boolean; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:92](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L92) + +Returns whether the column is visible + +#### Returns + +`boolean` + +*** + +### getToggleVisibilityHandler() + +```ts +getToggleVisibilityHandler: () => (event) => void; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:96](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L96) + +Returns a function that can be used to toggle the column visibility. This function can be used to bind to an event handler to a checkbox. + +#### Returns + +```ts +(event): void; +``` + +##### Parameters + +###### event + +`unknown` + +##### Returns + +`void` + +*** + +### toggleVisibility() + +```ts +toggleVisibility: (value?) => void; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:100](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L100) + +Toggles the visibility of the column. + +#### Parameters + +##### value? + +`boolean` + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Column_Core.md b/docs/reference/interfaces/Column_Core.md new file mode 100644 index 0000000000..19778f5f47 --- /dev/null +++ b/docs/reference/interfaces/Column_Core.md @@ -0,0 +1,181 @@ +--- +id: Column_Core +title: Column_Core +--- + +# Interface: Column\_Core\ + +Defined in: [types/Column.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Column.ts#L26) + +## Extends + +- [`Column_Column`](Column_Column.md)\<`TFeatures`, `TData`, `TValue`\> + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` = `unknown` + +## Properties + +### accessorFn? + +```ts +optional accessorFn: AccessorFn; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L15) + +The resolved accessor function to use when extracting the value for the column from each row. Will only be defined if the column def has a valid accessor key or function defined. + +#### Inherited from + +[`Column_Column`](Column_Column.md).[`accessorFn`](Column_Column.md#accessorfn) + +*** + +### columnDef + +```ts +columnDef: ColumnDef; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:19](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L19) + +The original column def used to create the column. + +#### Inherited from + +[`Column_Column`](Column_Column.md).[`columnDef`](Column_Column.md#columndef) + +*** + +### columns + +```ts +columns: Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L23) + +The child column (if the column is a group column). Will be an empty array if the column is not a group column. + +#### Inherited from + +[`Column_Column`](Column_Column.md).[`columns`](Column_Column.md#columns) + +*** + +### depth + +```ts +depth: number; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L27) + +The depth of the column (if grouped) relative to the root column def array. + +#### Inherited from + +[`Column_Column`](Column_Column.md).[`depth`](Column_Column.md#depth) + +*** + +### getFlatColumns() + +```ts +getFlatColumns: () => Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:53](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L53) + +Returns the flattened array of this column and all child/grand-child columns for this column. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\>[] + +#### Inherited from + +[`Column_Column`](Column_Column.md).[`getFlatColumns`](Column_Column.md#getflatcolumns) + +*** + +### getLeafColumns() + +```ts +getLeafColumns: () => Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:57](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L57) + +Returns an array of all leaf-node columns for this column. If a column has no children, it is considered the only leaf-node column. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\>[] + +#### Inherited from + +[`Column_Column`](Column_Column.md).[`getLeafColumns`](Column_Column.md#getleafcolumns) + +*** + +### id + +```ts +id: string; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L34) + +The resolved unique identifier for the column resolved in this priority: + - A manual `id` property from the column def + - The accessor key from the column def + - The header string from the column def + +#### Inherited from + +[`Column_Column`](Column_Column.md).[`id`](Column_Column.md#id) + +*** + +### parent? + +```ts +optional parent: Column; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L38) + +The parent column for this column. Will be undefined if this is a root column. + +#### Inherited from + +[`Column_Column`](Column_Column.md).[`parent`](Column_Column.md#parent) + +*** + +### table + +```ts +table: Table_Internal; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L42) + +Reference to the parent table instance. + +#### Inherited from + +[`Column_Column`](Column_Column.md).[`table`](Column_Column.md#table) diff --git a/docs/reference/interfaces/Column_CoreProperties.md b/docs/reference/interfaces/Column_CoreProperties.md new file mode 100644 index 0000000000..7fbb00c16d --- /dev/null +++ b/docs/reference/interfaces/Column_CoreProperties.md @@ -0,0 +1,113 @@ +--- +id: Column_CoreProperties +title: Column_CoreProperties +--- + +# Interface: Column\_CoreProperties\ + +Defined in: [core/columns/coreColumnsFeature.types.ts:7](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L7) + +## Extended by + +- [`Column_Column`](Column_Column.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) + +## Properties + +### accessorFn? + +```ts +optional accessorFn: AccessorFn; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L15) + +The resolved accessor function to use when extracting the value for the column from each row. Will only be defined if the column def has a valid accessor key or function defined. + +*** + +### columnDef + +```ts +columnDef: ColumnDef; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:19](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L19) + +The original column def used to create the column. + +*** + +### columns + +```ts +columns: Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L23) + +The child column (if the column is a group column). Will be an empty array if the column is not a group column. + +*** + +### depth + +```ts +depth: number; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L27) + +The depth of the column (if grouped) relative to the root column def array. + +*** + +### id + +```ts +id: string; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L34) + +The resolved unique identifier for the column resolved in this priority: + - A manual `id` property from the column def + - The accessor key from the column def + - The header string from the column def + +*** + +### parent? + +```ts +optional parent: Column; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L38) + +The parent column for this column. Will be undefined if this is a root column. + +*** + +### table + +```ts +table: Table_Internal; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L42) + +Reference to the parent table instance. diff --git a/docs/reference/interfaces/Column_GlobalFiltering.md b/docs/reference/interfaces/Column_GlobalFiltering.md new file mode 100644 index 0000000000..2f0e9d98b7 --- /dev/null +++ b/docs/reference/interfaces/Column_GlobalFiltering.md @@ -0,0 +1,24 @@ +--- +id: Column_GlobalFiltering +title: Column_GlobalFiltering +--- + +# Interface: Column\_GlobalFiltering + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:25](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L25) + +## Properties + +### getCanGlobalFilter() + +```ts +getCanGlobalFilter: () => boolean; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L29) + +Returns whether or not the column can be **globally** filtered. Set to `false` to disable a column from being scanned during global filtering. + +#### Returns + +`boolean` diff --git a/docs/reference/interfaces/Column_Plugins.md b/docs/reference/interfaces/Column_Plugins.md new file mode 100644 index 0000000000..1034f8f551 --- /dev/null +++ b/docs/reference/interfaces/Column_Plugins.md @@ -0,0 +1,25 @@ +--- +id: Column_Plugins +title: Column_Plugins +--- + +# Interface: Column\_Plugins\ + +Defined in: [types/Column.ts:20](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Column.ts#L20) + +Use this interface as a target for declaration merging to add your own plugin properties. +Note: This will affect the types of all tables in your project. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` = `unknown` diff --git a/docs/reference/interfaces/Column_RowSorting.md b/docs/reference/interfaces/Column_RowSorting.md new file mode 100644 index 0000000000..52460eb9af --- /dev/null +++ b/docs/reference/interfaces/Column_RowSorting.md @@ -0,0 +1,220 @@ +--- +id: Column_RowSorting +title: Column_RowSorting +--- + +# Interface: Column\_RowSorting\ + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:89](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L89) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### clearSorting() + +```ts +clearSorting: () => void; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:96](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L96) + +Removes this column from the table's sorting state + +#### Returns + +`void` + +*** + +### getAutoSortDir() + +```ts +getAutoSortDir: () => SortDirection; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:100](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L100) + +Returns a sort direction automatically inferred based on the columns values. + +#### Returns + +[`SortDirection`](../type-aliases/SortDirection.md) + +*** + +### getAutoSortFn() + +```ts +getAutoSortFn: () => SortFn; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:104](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L104) + +Returns a sorting function automatically inferred based on the columns values. + +#### Returns + +[`SortFn`](SortFn.md)\<`TFeatures`, `TData`\> + +*** + +### getCanMultiSort() + +```ts +getCanMultiSort: () => boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:108](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L108) + +Returns whether this column can be multi-sorted. + +#### Returns + +`boolean` + +*** + +### getCanSort() + +```ts +getCanSort: () => boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:112](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L112) + +Returns whether this column can be sorted. + +#### Returns + +`boolean` + +*** + +### getFirstSortDir() + +```ts +getFirstSortDir: () => SortDirection; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:116](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L116) + +Returns the first direction that should be used when sorting this column. + +#### Returns + +[`SortDirection`](../type-aliases/SortDirection.md) + +*** + +### getIsSorted() + +```ts +getIsSorted: () => false | SortDirection; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:120](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L120) + +Returns the current sort direction of this column. + +#### Returns + +`false` \| [`SortDirection`](../type-aliases/SortDirection.md) + +*** + +### getNextSortingOrder() + +```ts +getNextSortingOrder: () => false | SortDirection; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:124](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L124) + +Returns the next sorting order. + +#### Returns + +`false` \| [`SortDirection`](../type-aliases/SortDirection.md) + +*** + +### getSortFn() + +```ts +getSortFn: () => SortFn; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:132](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L132) + +Returns the resolved sorting function to be used for this column + +#### Returns + +[`SortFn`](SortFn.md)\<`TFeatures`, `TData`\> + +*** + +### getSortIndex() + +```ts +getSortIndex: () => number; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:128](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L128) + +Returns the index position of this column's sorting within the sorting state + +#### Returns + +`number` + +*** + +### getToggleSortingHandler() + +```ts +getToggleSortingHandler: () => (event) => void | undefined; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:136](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L136) + +Returns a function that can be used to toggle this column's sorting state. This is useful for attaching a click handler to the column header. + +#### Returns + +(`event`) => `void` \| `undefined` + +*** + +### toggleSorting() + +```ts +toggleSorting: (desc?, isMulti?) => void; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:140](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L140) + +Toggles this columns sorting state. If `desc` is provided, it will force the sort direction to that value. If `isMulti` is provided, it will additivity multi-sort the column (or toggle it if it is already sorted). + +#### Parameters + +##### desc? + +`boolean` + +##### isMulti? + +`boolean` + +#### Returns + +`void` diff --git a/docs/reference/interfaces/CoreFeatures.md b/docs/reference/interfaces/CoreFeatures.md new file mode 100644 index 0000000000..1491971a10 --- /dev/null +++ b/docs/reference/interfaces/CoreFeatures.md @@ -0,0 +1,68 @@ +--- +id: CoreFeatures +title: CoreFeatures +--- + +# Interface: CoreFeatures + +Defined in: [core/coreFeatures.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/coreFeatures.ts#L8) + +## Properties + +### coreCellsFeature + +```ts +coreCellsFeature: TableFeature>; +``` + +Defined in: [core/coreFeatures.ts:9](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/coreFeatures.ts#L9) + +*** + +### coreColumnsFeature + +```ts +coreColumnsFeature: TableFeature>; +``` + +Defined in: [core/coreFeatures.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/coreFeatures.ts#L10) + +*** + +### coreHeadersFeature + +```ts +coreHeadersFeature: TableFeature>; +``` + +Defined in: [core/coreFeatures.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/coreFeatures.ts#L11) + +*** + +### coreRowModelsFeature + +```ts +coreRowModelsFeature: TableFeature>; +``` + +Defined in: [core/coreFeatures.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/coreFeatures.ts#L12) + +*** + +### coreRowsFeature + +```ts +coreRowsFeature: TableFeature>; +``` + +Defined in: [core/coreFeatures.ts:13](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/coreFeatures.ts#L13) + +*** + +### coreTablesFeature + +```ts +coreTablesFeature: TableFeature>; +``` + +Defined in: [core/coreFeatures.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/coreFeatures.ts#L14) diff --git a/docs/reference/interfaces/CreateRowModel_Core.md b/docs/reference/interfaces/CreateRowModel_Core.md new file mode 100644 index 0000000000..0d1fae943c --- /dev/null +++ b/docs/reference/interfaces/CreateRowModel_Core.md @@ -0,0 +1,50 @@ +--- +id: CreateRowModel_Core +title: CreateRowModel_Core +--- + +# Interface: CreateRowModel\_Core\ + +Defined in: [core/row-models/coreRowModelsFeature.types.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.types.ts#L23) + +## Extends + +- [`CreateRowModel_Plugins`](CreateRowModel_Plugins.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### coreRowModel()? + +```ts +optional coreRowModel: (table) => () => RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.types.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.types.ts#L30) + +This required option is a factory for a function that computes and returns the core row model for the table. + +#### Parameters + +##### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +#### Returns + +```ts +(): RowModel; +``` + +##### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/CreateRowModel_Expanded.md b/docs/reference/interfaces/CreateRowModel_Expanded.md new file mode 100644 index 0000000000..727b7f8894 --- /dev/null +++ b/docs/reference/interfaces/CreateRowModel_Expanded.md @@ -0,0 +1,46 @@ +--- +id: CreateRowModel_Expanded +title: CreateRowModel_Expanded +--- + +# Interface: CreateRowModel\_Expanded\ + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:124](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L124) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### expandedRowModel()? + +```ts +optional expandedRowModel: (table) => () => RowModel; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:131](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L131) + +This function is responsible for returning the expanded row model. If this function is not provided, the table will not expand rows. You can use the default exported `getExpandedRowModel` function to get the expanded row model or implement your own. + +#### Parameters + +##### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +#### Returns + +```ts +(): RowModel; +``` + +##### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/CreateRowModel_Faceted.md b/docs/reference/interfaces/CreateRowModel_Faceted.md new file mode 100644 index 0000000000..a9f1bef027 --- /dev/null +++ b/docs/reference/interfaces/CreateRowModel_Faceted.md @@ -0,0 +1,114 @@ +--- +id: CreateRowModel_Faceted +title: CreateRowModel_Faceted +--- + +# Interface: CreateRowModel\_Faceted\ + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L45) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### facetedMinMaxValues()? + +```ts +optional facetedMinMaxValues: (table, columnId) => () => [number, number] | undefined; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:52](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L52) + +This function is used to retrieve the faceted min/max values. If using server-side faceting, this function is not required. To use client-side faceting, pass the exported `getFacetedMinMaxValues()` from your adapter to your table or implement your own. + +#### Parameters + +##### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +##### columnId + +`string` + +#### Returns + +```ts +(): [number, number] | undefined; +``` + +##### Returns + +\[`number`, `number`\] \| `undefined` + +*** + +### facetedRowModel()? + +```ts +optional facetedRowModel: (table, columnId) => () => RowModel; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:59](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L59) + +This function is used to retrieve the faceted row model. If using server-side faceting, this function is not required. To use client-side faceting, pass the exported `getFacetedRowModel()` from your adapter to your table or implement your own. + +#### Parameters + +##### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +##### columnId + +`string` + +#### Returns + +```ts +(): RowModel; +``` + +##### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### facetedUniqueValues()? + +```ts +optional facetedUniqueValues: (table, columnId) => () => Map; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:66](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L66) + +This function is used to retrieve the faceted unique values. If using server-side faceting, this function is not required. To use client-side faceting, pass the exported `getFacetedUniqueValues()` from your adapter to your table or implement your own. + +#### Parameters + +##### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +##### columnId + +`string` + +#### Returns + +```ts +(): Map; +``` + +##### Returns + +`Map`\<`any`, `number`\> diff --git a/docs/reference/interfaces/CreateRowModel_Filtered.md b/docs/reference/interfaces/CreateRowModel_Filtered.md new file mode 100644 index 0000000000..f7de330af1 --- /dev/null +++ b/docs/reference/interfaces/CreateRowModel_Filtered.md @@ -0,0 +1,48 @@ +--- +id: CreateRowModel_Filtered +title: CreateRowModel_Filtered +--- + +# Interface: CreateRowModel\_Filtered\ + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:200](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L200) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### filteredRowModel()? + +```ts +optional filteredRowModel: (table) => () => RowModel; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:209](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L209) + +If provided, this function is called **once** per table and should return a **new function** which will calculate and return the row model for the table when it's filtered. +- For server-side filtering, this function is unnecessary and can be ignored since the server should already return the filtered row model. +- For client-side filtering, this function is required. A default implementation is provided via any table adapter's `{ getFilteredRowModel }` export. + +#### Parameters + +##### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +#### Returns + +```ts +(): RowModel; +``` + +##### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/CreateRowModel_Grouped.md b/docs/reference/interfaces/CreateRowModel_Grouped.md new file mode 100644 index 0000000000..294cb33fa0 --- /dev/null +++ b/docs/reference/interfaces/CreateRowModel_Grouped.md @@ -0,0 +1,46 @@ +--- +id: CreateRowModel_Grouped +title: CreateRowModel_Grouped +--- + +# Interface: CreateRowModel\_Grouped\ + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:201](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L201) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### groupedRowModel()? + +```ts +optional groupedRowModel: (table) => () => RowModel; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:208](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L208) + +Returns the row model after grouping has taken place, but no further. + +#### Parameters + +##### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +#### Returns + +```ts +(): RowModel; +``` + +##### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/CreateRowModel_Paginated.md b/docs/reference/interfaces/CreateRowModel_Paginated.md new file mode 100644 index 0000000000..7a71b9d7f6 --- /dev/null +++ b/docs/reference/interfaces/CreateRowModel_Paginated.md @@ -0,0 +1,47 @@ +--- +id: CreateRowModel_Paginated +title: CreateRowModel_Paginated +--- + +# Interface: CreateRowModel\_Paginated\ + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:123](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L123) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### paginatedRowModel()? + +```ts +optional paginatedRowModel: (table) => () => RowModel; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:131](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L131) + +Returns the row model after pagination has taken place, but no further. +Pagination columns are automatically reordered by default to the start of the columns list. If you would rather remove them or leave them as-is, set the appropriate mode here. + +#### Parameters + +##### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +#### Returns + +```ts +(): RowModel; +``` + +##### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/CreateRowModel_Plugins.md b/docs/reference/interfaces/CreateRowModel_Plugins.md new file mode 100644 index 0000000000..d548153f1b --- /dev/null +++ b/docs/reference/interfaces/CreateRowModel_Plugins.md @@ -0,0 +1,12 @@ +--- +id: CreateRowModel_Plugins +title: CreateRowModel_Plugins +--- + +# Interface: CreateRowModel\_Plugins + +Defined in: [core/row-models/coreRowModelsFeature.types.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.types.ts#L21) + +## Extended by + +- [`CreateRowModel_Core`](CreateRowModel_Core.md) diff --git a/docs/reference/interfaces/CreateRowModel_Sorted.md b/docs/reference/interfaces/CreateRowModel_Sorted.md new file mode 100644 index 0000000000..49e2047721 --- /dev/null +++ b/docs/reference/interfaces/CreateRowModel_Sorted.md @@ -0,0 +1,46 @@ +--- +id: CreateRowModel_Sorted +title: CreateRowModel_Sorted +--- + +# Interface: CreateRowModel\_Sorted\ + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:212](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L212) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### sortedRowModel()? + +```ts +optional sortedRowModel: (table) => () => RowModel; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:219](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L219) + +This function is used to retrieve the sorted row model. If using server-side sorting, this function is not required. To use client-side sorting, pass the exported `getSortedRowModel()` from your adapter to your table or implement your own. + +#### Parameters + +##### table + +[`Table`](../type-aliases/Table.md)\<`TFeatures`, `TData`\> + +#### Returns + +```ts +(): RowModel; +``` + +##### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/CreateRowModels_Plugins.md b/docs/reference/interfaces/CreateRowModels_Plugins.md new file mode 100644 index 0000000000..6604e4bdfa --- /dev/null +++ b/docs/reference/interfaces/CreateRowModels_Plugins.md @@ -0,0 +1,21 @@ +--- +id: CreateRowModels_Plugins +title: CreateRowModels_Plugins +--- + +# Interface: CreateRowModels\_Plugins\ + +Defined in: [types/RowModel.ts:37](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/RowModel.ts#L37) + +Use this interface as a target for declaration merging to add your own plugin properties. +Note: This will affect the types of all tables in your project. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) diff --git a/docs/reference/interfaces/FilterFn.md b/docs/reference/interfaces/FilterFn.md new file mode 100644 index 0000000000..3bfeb7a15f --- /dev/null +++ b/docs/reference/interfaces/FilterFn.md @@ -0,0 +1,70 @@ +--- +id: FilterFn +title: FilterFn +--- + +# Interface: FilterFn()\ + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L45) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +```ts +FilterFn( + row, + columnId, + filterValue, + addMeta?): boolean; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:49](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L49) + +## Parameters + +### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +### columnId + +`string` + +### filterValue + +`any` + +### addMeta? + +(`meta`) => `void` + +## Returns + +`boolean` + +## Properties + +### autoRemove? + +```ts +optional autoRemove: ColumnFilterAutoRemoveTestFn; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:55](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L55) + +*** + +### resolveFilterValue? + +```ts +optional resolveFilterValue: TransformFilterValueFn; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:56](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L56) diff --git a/docs/reference/interfaces/FilterFns.md b/docs/reference/interfaces/FilterFns.md new file mode 100644 index 0000000000..48e1d51a89 --- /dev/null +++ b/docs/reference/interfaces/FilterFns.md @@ -0,0 +1,8 @@ +--- +id: FilterFns +title: FilterFns +--- + +# Interface: FilterFns + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L16) diff --git a/docs/reference/interfaces/FilterMeta.md b/docs/reference/interfaces/FilterMeta.md new file mode 100644 index 0000000000..75b2577be3 --- /dev/null +++ b/docs/reference/interfaces/FilterMeta.md @@ -0,0 +1,8 @@ +--- +id: FilterMeta +title: FilterMeta +--- + +# Interface: FilterMeta + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L14) diff --git a/docs/reference/interfaces/HeaderContext.md b/docs/reference/interfaces/HeaderContext.md new file mode 100644 index 0000000000..20f0236561 --- /dev/null +++ b/docs/reference/interfaces/HeaderContext.md @@ -0,0 +1,58 @@ +--- +id: HeaderContext +title: HeaderContext +--- + +# Interface: HeaderContext\ + +Defined in: [core/headers/coreHeadersFeature.types.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L30) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) + +## Properties + +### column + +```ts +column: Column; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L38) + +An instance of a column. + +*** + +### header + +```ts +header: Header; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L42) + +An instance of a header. + +*** + +### table + +```ts +table: Table; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:46](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L46) + +The table instance. diff --git a/docs/reference/interfaces/HeaderGroup_Core.md b/docs/reference/interfaces/HeaderGroup_Core.md new file mode 100644 index 0000000000..99cf395801 --- /dev/null +++ b/docs/reference/interfaces/HeaderGroup_Core.md @@ -0,0 +1,64 @@ +--- +id: HeaderGroup_Core +title: HeaderGroup_Core +--- + +# Interface: HeaderGroup\_Core\ + +Defined in: [types/HeaderGroup.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/HeaderGroup.ts#L14) + +## Extends + +- [`HeaderGroup_Header`](HeaderGroup_Header.md)\<`TFeatures`, `TData`\> + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### depth + +```ts +depth: number; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:120](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L120) + +#### Inherited from + +[`HeaderGroup_Header`](HeaderGroup_Header.md).[`depth`](HeaderGroup_Header.md#depth) + +*** + +### headers + +```ts +headers: Header[]; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:121](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L121) + +#### Inherited from + +[`HeaderGroup_Header`](HeaderGroup_Header.md).[`headers`](HeaderGroup_Header.md#headers) + +*** + +### id + +```ts +id: string; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:122](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L122) + +#### Inherited from + +[`HeaderGroup_Header`](HeaderGroup_Header.md).[`id`](HeaderGroup_Header.md#id) diff --git a/docs/reference/interfaces/HeaderGroup_Header.md b/docs/reference/interfaces/HeaderGroup_Header.md new file mode 100644 index 0000000000..5bd51a846d --- /dev/null +++ b/docs/reference/interfaces/HeaderGroup_Header.md @@ -0,0 +1,56 @@ +--- +id: HeaderGroup_Header +title: HeaderGroup_Header +--- + +# Interface: HeaderGroup\_Header\ + +Defined in: [core/headers/coreHeadersFeature.types.ts:115](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L115) + +## Extended by + +- [`HeaderGroup_Core`](HeaderGroup_Core.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) + +## Properties + +### depth + +```ts +depth: number; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:120](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L120) + +*** + +### headers + +```ts +headers: Header[]; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:121](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L121) + +*** + +### id + +```ts +id: string; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:122](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L122) diff --git a/docs/reference/interfaces/HeaderGroup_Plugins.md b/docs/reference/interfaces/HeaderGroup_Plugins.md new file mode 100644 index 0000000000..0852efdc72 --- /dev/null +++ b/docs/reference/interfaces/HeaderGroup_Plugins.md @@ -0,0 +1,21 @@ +--- +id: HeaderGroup_Plugins +title: HeaderGroup_Plugins +--- + +# Interface: HeaderGroup\_Plugins\ + +Defined in: [types/HeaderGroup.ts:9](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/HeaderGroup.ts#L9) + +Use this interface as a target for declaration merging to add your own plugin properties. +Note: This will affect the types of all tables in your project. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) diff --git a/docs/reference/interfaces/Header_ColumnResizing.md b/docs/reference/interfaces/Header_ColumnResizing.md new file mode 100644 index 0000000000..4ab017b240 --- /dev/null +++ b/docs/reference/interfaces/Header_ColumnResizing.md @@ -0,0 +1,45 @@ +--- +id: Header_ColumnResizing +title: Header_ColumnResizing +--- + +# Interface: Header\_ColumnResizing + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:73](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L73) + +## Properties + +### getResizeHandler() + +```ts +getResizeHandler: (context?) => (event) => void; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:80](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L80) + +Returns an event handler function that can be used to resize the header. It can be used as an: +- `onMouseDown` handler +- `onTouchStart` handler +The dragging and release events are automatically handled for you. + +#### Parameters + +##### context? + +`Document` + +#### Returns + +```ts +(event): void; +``` + +##### Parameters + +###### event + +`unknown` + +##### Returns + +`void` diff --git a/docs/reference/interfaces/Header_ColumnSizing.md b/docs/reference/interfaces/Header_ColumnSizing.md new file mode 100644 index 0000000000..d47d6cb662 --- /dev/null +++ b/docs/reference/interfaces/Header_ColumnSizing.md @@ -0,0 +1,46 @@ +--- +id: Header_ColumnSizing +title: Header_ColumnSizing +--- + +# Interface: Header\_ColumnSizing + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:83](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L83) + +## Properties + +### getSize() + +```ts +getSize: () => number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:87](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L87) + +Returns the current size of the header. + +#### Returns + +`number` + +*** + +### getStart() + +```ts +getStart: (position?) => number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:91](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L91) + +Returns the offset measurement along the row-axis (usually the x-axis for standard tables) for the header. This is effectively a sum of the offset measurements of all preceding headers. + +#### Parameters + +##### position? + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) + +#### Returns + +`number` diff --git a/docs/reference/interfaces/Header_Core.md b/docs/reference/interfaces/Header_Core.md new file mode 100644 index 0000000000..fd4980f9ba --- /dev/null +++ b/docs/reference/interfaces/Header_Core.md @@ -0,0 +1,244 @@ +--- +id: Header_Core +title: Header_Core +--- + +# Interface: Header\_Core\ + +Defined in: [types/Header.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Header.ts#L17) + +## Extends + +- [`Header_Header`](Header_Header.md)\<`TFeatures`, `TData`, `TValue`\> + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) + +## Properties + +### colSpan + +```ts +colSpan: number; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:57](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L57) + +The col-span for the header. + +#### Inherited from + +[`Header_Header`](Header_Header.md).[`colSpan`](Header_Header.md#colspan) + +*** + +### column + +```ts +column: Column; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:61](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L61) + +The header's associated column object. + +#### Inherited from + +[`Header_Header`](Header_Header.md).[`column`](Header_Header.md#column) + +*** + +### depth + +```ts +depth: number; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:65](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L65) + +The depth of the header, zero-indexed based. + +#### Inherited from + +[`Header_Header`](Header_Header.md).[`depth`](Header_Header.md#depth) + +*** + +### getContext() + +```ts +getContext: () => HeaderContext; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:108](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L108) + +Returns the rendering context (or props) for column-based components like headers, footers and filters. + +#### Returns + +[`HeaderContext`](HeaderContext.md)\<`TFeatures`, `TData`, `TValue`\> + +#### Inherited from + +[`Header_Header`](Header_Header.md).[`getContext`](Header_Header.md#getcontext) + +*** + +### getLeafHeaders() + +```ts +getLeafHeaders: () => Header[]; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:112](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L112) + +Returns the leaf headers hierarchically nested under this header. + +#### Returns + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `TValue`\>[] + +#### Inherited from + +[`Header_Header`](Header_Header.md).[`getLeafHeaders`](Header_Header.md#getleafheaders) + +*** + +### headerGroup + +```ts +headerGroup: + | HeaderGroup + | null; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:69](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L69) + +The header's associated header group object. + +#### Inherited from + +[`Header_Header`](Header_Header.md).[`headerGroup`](Header_Header.md#headergroup) + +*** + +### id + +```ts +id: string; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:73](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L73) + +The unique identifier for the header. + +#### Inherited from + +[`Header_Header`](Header_Header.md).[`id`](Header_Header.md#id) + +*** + +### index + +```ts +index: number; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:77](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L77) + +The index for the header within the header group. + +#### Inherited from + +[`Header_Header`](Header_Header.md).[`index`](Header_Header.md#index) + +*** + +### isPlaceholder + +```ts +isPlaceholder: boolean; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:81](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L81) + +A boolean denoting if the header is a placeholder header. + +#### Inherited from + +[`Header_Header`](Header_Header.md).[`isPlaceholder`](Header_Header.md#isplaceholder) + +*** + +### placeholderId? + +```ts +optional placeholderId: string; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:85](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L85) + +If the header is a placeholder header, this will be a unique header ID that does not conflict with any other headers across the table. + +#### Inherited from + +[`Header_Header`](Header_Header.md).[`placeholderId`](Header_Header.md#placeholderid) + +*** + +### rowSpan + +```ts +rowSpan: number; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:89](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L89) + +The row-span for the header. + +#### Inherited from + +[`Header_Header`](Header_Header.md).[`rowSpan`](Header_Header.md#rowspan) + +*** + +### subHeaders + +```ts +subHeaders: Header[]; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:93](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L93) + +The header's hierarchical sub/child headers. Will be empty if the header's associated column is a leaf-column. + +#### Inherited from + +[`Header_Header`](Header_Header.md).[`subHeaders`](Header_Header.md#subheaders) + +*** + +### table + +```ts +table: Table; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:97](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L97) + +Reference to the parent table instance. + +#### Inherited from + +[`Header_Header`](Header_Header.md).[`table`](Header_Header.md#table) diff --git a/docs/reference/interfaces/Header_CoreProperties.md b/docs/reference/interfaces/Header_CoreProperties.md new file mode 100644 index 0000000000..c9510471c6 --- /dev/null +++ b/docs/reference/interfaces/Header_CoreProperties.md @@ -0,0 +1,160 @@ +--- +id: Header_CoreProperties +title: Header_CoreProperties +--- + +# Interface: Header\_CoreProperties\ + +Defined in: [core/headers/coreHeadersFeature.types.ts:49](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L49) + +## Extended by + +- [`Header_Header`](Header_Header.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) + +## Properties + +### colSpan + +```ts +colSpan: number; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:57](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L57) + +The col-span for the header. + +*** + +### column + +```ts +column: Column; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:61](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L61) + +The header's associated column object. + +*** + +### depth + +```ts +depth: number; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:65](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L65) + +The depth of the header, zero-indexed based. + +*** + +### headerGroup + +```ts +headerGroup: + | HeaderGroup + | null; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:69](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L69) + +The header's associated header group object. + +*** + +### id + +```ts +id: string; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:73](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L73) + +The unique identifier for the header. + +*** + +### index + +```ts +index: number; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:77](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L77) + +The index for the header within the header group. + +*** + +### isPlaceholder + +```ts +isPlaceholder: boolean; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:81](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L81) + +A boolean denoting if the header is a placeholder header. + +*** + +### placeholderId? + +```ts +optional placeholderId: string; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:85](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L85) + +If the header is a placeholder header, this will be a unique header ID that does not conflict with any other headers across the table. + +*** + +### rowSpan + +```ts +rowSpan: number; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:89](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L89) + +The row-span for the header. + +*** + +### subHeaders + +```ts +subHeaders: Header[]; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:93](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L93) + +The header's hierarchical sub/child headers. Will be empty if the header's associated column is a leaf-column. + +*** + +### table + +```ts +table: Table; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:97](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L97) + +Reference to the parent table instance. diff --git a/docs/reference/interfaces/Header_Header.md b/docs/reference/interfaces/Header_Header.md new file mode 100644 index 0000000000..ce794fb2bb --- /dev/null +++ b/docs/reference/interfaces/Header_Header.md @@ -0,0 +1,240 @@ +--- +id: Header_Header +title: Header_Header +--- + +# Interface: Header\_Header\ + +Defined in: [core/headers/coreHeadersFeature.types.ts:100](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L100) + +## Extends + +- [`Header_CoreProperties`](Header_CoreProperties.md)\<`TFeatures`, `TData`, `TValue`\> + +## Extended by + +- [`Header_Core`](Header_Core.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) + +## Properties + +### colSpan + +```ts +colSpan: number; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:57](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L57) + +The col-span for the header. + +#### Inherited from + +[`Header_CoreProperties`](Header_CoreProperties.md).[`colSpan`](Header_CoreProperties.md#colspan) + +*** + +### column + +```ts +column: Column; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:61](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L61) + +The header's associated column object. + +#### Inherited from + +[`Header_CoreProperties`](Header_CoreProperties.md).[`column`](Header_CoreProperties.md#column) + +*** + +### depth + +```ts +depth: number; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:65](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L65) + +The depth of the header, zero-indexed based. + +#### Inherited from + +[`Header_CoreProperties`](Header_CoreProperties.md).[`depth`](Header_CoreProperties.md#depth) + +*** + +### getContext() + +```ts +getContext: () => HeaderContext; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:108](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L108) + +Returns the rendering context (or props) for column-based components like headers, footers and filters. + +#### Returns + +[`HeaderContext`](HeaderContext.md)\<`TFeatures`, `TData`, `TValue`\> + +*** + +### getLeafHeaders() + +```ts +getLeafHeaders: () => Header[]; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:112](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L112) + +Returns the leaf headers hierarchically nested under this header. + +#### Returns + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `TValue`\>[] + +*** + +### headerGroup + +```ts +headerGroup: + | HeaderGroup + | null; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:69](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L69) + +The header's associated header group object. + +#### Inherited from + +[`Header_CoreProperties`](Header_CoreProperties.md).[`headerGroup`](Header_CoreProperties.md#headergroup) + +*** + +### id + +```ts +id: string; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:73](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L73) + +The unique identifier for the header. + +#### Inherited from + +[`Header_CoreProperties`](Header_CoreProperties.md).[`id`](Header_CoreProperties.md#id) + +*** + +### index + +```ts +index: number; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:77](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L77) + +The index for the header within the header group. + +#### Inherited from + +[`Header_CoreProperties`](Header_CoreProperties.md).[`index`](Header_CoreProperties.md#index) + +*** + +### isPlaceholder + +```ts +isPlaceholder: boolean; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:81](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L81) + +A boolean denoting if the header is a placeholder header. + +#### Inherited from + +[`Header_CoreProperties`](Header_CoreProperties.md).[`isPlaceholder`](Header_CoreProperties.md#isplaceholder) + +*** + +### placeholderId? + +```ts +optional placeholderId: string; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:85](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L85) + +If the header is a placeholder header, this will be a unique header ID that does not conflict with any other headers across the table. + +#### Inherited from + +[`Header_CoreProperties`](Header_CoreProperties.md).[`placeholderId`](Header_CoreProperties.md#placeholderid) + +*** + +### rowSpan + +```ts +rowSpan: number; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:89](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L89) + +The row-span for the header. + +#### Inherited from + +[`Header_CoreProperties`](Header_CoreProperties.md).[`rowSpan`](Header_CoreProperties.md#rowspan) + +*** + +### subHeaders + +```ts +subHeaders: Header[]; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:93](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L93) + +The header's hierarchical sub/child headers. Will be empty if the header's associated column is a leaf-column. + +#### Inherited from + +[`Header_CoreProperties`](Header_CoreProperties.md).[`subHeaders`](Header_CoreProperties.md#subheaders) + +*** + +### table + +```ts +table: Table; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:97](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L97) + +Reference to the parent table instance. + +#### Inherited from + +[`Header_CoreProperties`](Header_CoreProperties.md).[`table`](Header_CoreProperties.md#table) diff --git a/docs/reference/interfaces/Header_Plugins.md b/docs/reference/interfaces/Header_Plugins.md new file mode 100644 index 0000000000..c1e09c4777 --- /dev/null +++ b/docs/reference/interfaces/Header_Plugins.md @@ -0,0 +1,25 @@ +--- +id: Header_Plugins +title: Header_Plugins +--- + +# Interface: Header\_Plugins\ + +Defined in: [types/Header.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Header.ts#L11) + +Use this interface as a target for declaration merging to add your own plugin properties. +Note: This will affect the types of all tables in your project. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) diff --git a/docs/reference/interfaces/IdIdentifier.md b/docs/reference/interfaces/IdIdentifier.md new file mode 100644 index 0000000000..49bb4140c3 --- /dev/null +++ b/docs/reference/interfaces/IdIdentifier.md @@ -0,0 +1,42 @@ +--- +id: IdIdentifier +title: IdIdentifier +--- + +# Interface: IdIdentifier\ + +Defined in: [types/ColumnDef.ts:50](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L50) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) + +## Properties + +### header? + +```ts +optional header: ColumnDefTemplate>; +``` + +Defined in: [types/ColumnDef.ts:56](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L56) + +*** + +### id + +```ts +id: string; +``` + +Defined in: [types/ColumnDef.ts:55](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L55) diff --git a/docs/reference/interfaces/PaginationDefaultOptions.md b/docs/reference/interfaces/PaginationDefaultOptions.md new file mode 100644 index 0000000000..8cd73c9c07 --- /dev/null +++ b/docs/reference/interfaces/PaginationDefaultOptions.md @@ -0,0 +1,18 @@ +--- +id: PaginationDefaultOptions +title: PaginationDefaultOptions +--- + +# Interface: PaginationDefaultOptions + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L38) + +## Properties + +### onPaginationChange + +```ts +onPaginationChange: OnChangeFn; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:39](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L39) diff --git a/docs/reference/interfaces/PaginationState.md b/docs/reference/interfaces/PaginationState.md new file mode 100644 index 0000000000..9b07030209 --- /dev/null +++ b/docs/reference/interfaces/PaginationState.md @@ -0,0 +1,28 @@ +--- +id: PaginationState +title: PaginationState +--- + +# Interface: PaginationState + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:6](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L6) + +## Properties + +### pageIndex + +```ts +pageIndex: number; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:7](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L7) + +*** + +### pageSize + +```ts +pageSize: number; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L8) diff --git a/docs/reference/interfaces/Plugins.md b/docs/reference/interfaces/Plugins.md new file mode 100644 index 0000000000..a923a8a653 --- /dev/null +++ b/docs/reference/interfaces/Plugins.md @@ -0,0 +1,8 @@ +--- +id: Plugins +title: Plugins +--- + +# Interface: Plugins + +Defined in: [types/TableFeatures.ts:40](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L40) diff --git a/docs/reference/interfaces/PrototypeAPI.md b/docs/reference/interfaces/PrototypeAPI.md new file mode 100644 index 0000000000..d20ace6d67 --- /dev/null +++ b/docs/reference/interfaces/PrototypeAPI.md @@ -0,0 +1,66 @@ +--- +id: PrototypeAPI +title: PrototypeAPI +--- + +# Interface: PrototypeAPI\ + +Defined in: [utils.ts:322](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L322) + +## Type Parameters + +### TDeps + +`TDeps` *extends* `ReadonlyArray`\<`any`\> + +### TDepArgs + +`TDepArgs` + +## Properties + +### fn() + +```ts +fn: (self, ...args) => any; +``` + +Defined in: [utils.ts:323](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L323) + +#### Parameters + +##### self + +`any` + +##### args + +...`any` + +#### Returns + +`any` + +*** + +### memoDeps()? + +```ts +optional memoDeps: (self, depArgs?) => any[] | undefined; +``` + +Defined in: [utils.ts:324](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L324) + +#### Parameters + +##### self + +`any` + +##### depArgs? + +`any` + +#### Returns + +`any`[] \| `undefined` diff --git a/docs/reference/interfaces/ResolvedColumnFilter.md b/docs/reference/interfaces/ResolvedColumnFilter.md new file mode 100644 index 0000000000..121659ae70 --- /dev/null +++ b/docs/reference/interfaces/ResolvedColumnFilter.md @@ -0,0 +1,48 @@ +--- +id: ResolvedColumnFilter +title: ResolvedColumnFilter +--- + +# Interface: ResolvedColumnFilter\ + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L29) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### filterFn + +```ts +filterFn: FilterFn; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:33](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L33) + +*** + +### id + +```ts +id: string; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L34) + +*** + +### resolvedValue + +```ts +resolvedValue: unknown; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:35](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L35) diff --git a/docs/reference/interfaces/RowModel.md b/docs/reference/interfaces/RowModel.md new file mode 100644 index 0000000000..299c831f98 --- /dev/null +++ b/docs/reference/interfaces/RowModel.md @@ -0,0 +1,48 @@ +--- +id: RowModel +title: RowModel +--- + +# Interface: RowModel\ + +Defined in: [core/row-models/coreRowModelsFeature.types.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.types.ts#L12) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### flatRows + +```ts +flatRows: Row[]; +``` + +Defined in: [core/row-models/coreRowModelsFeature.types.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.types.ts#L17) + +*** + +### rows + +```ts +rows: Row[]; +``` + +Defined in: [core/row-models/coreRowModelsFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.types.ts#L16) + +*** + +### rowsById + +```ts +rowsById: Record>; +``` + +Defined in: [core/row-models/coreRowModelsFeature.types.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.types.ts#L18) diff --git a/docs/reference/interfaces/RowModelFns_ColumnFiltering.md b/docs/reference/interfaces/RowModelFns_ColumnFiltering.md new file mode 100644 index 0000000000..e6d142dc70 --- /dev/null +++ b/docs/reference/interfaces/RowModelFns_ColumnFiltering.md @@ -0,0 +1,28 @@ +--- +id: RowModelFns_ColumnFiltering +title: RowModelFns_ColumnFiltering +--- + +# Interface: RowModelFns\_ColumnFiltering\ + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L38) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### filterFns + +```ts +filterFns: Record>; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L42) diff --git a/docs/reference/interfaces/RowModelFns_ColumnGrouping.md b/docs/reference/interfaces/RowModelFns_ColumnGrouping.md new file mode 100644 index 0000000000..cf44182b79 --- /dev/null +++ b/docs/reference/interfaces/RowModelFns_ColumnGrouping.md @@ -0,0 +1,28 @@ +--- +id: RowModelFns_ColumnGrouping +title: RowModelFns_ColumnGrouping +--- + +# Interface: RowModelFns\_ColumnGrouping\ + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L21) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### aggregationFns + +```ts +aggregationFns: Record>; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:25](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L25) diff --git a/docs/reference/interfaces/RowModelFns_Core.md b/docs/reference/interfaces/RowModelFns_Core.md new file mode 100644 index 0000000000..61bf61fa25 --- /dev/null +++ b/docs/reference/interfaces/RowModelFns_Core.md @@ -0,0 +1,8 @@ +--- +id: RowModelFns_Core +title: RowModelFns_Core +--- + +# Interface: RowModelFns\_Core + +Defined in: [types/RowModelFns.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/RowModelFns.ts#L16) diff --git a/docs/reference/interfaces/RowModelFns_Plugins.md b/docs/reference/interfaces/RowModelFns_Plugins.md new file mode 100644 index 0000000000..ea45a3438f --- /dev/null +++ b/docs/reference/interfaces/RowModelFns_Plugins.md @@ -0,0 +1,21 @@ +--- +id: RowModelFns_Plugins +title: RowModelFns_Plugins +--- + +# Interface: RowModelFns\_Plugins\ + +Defined in: [types/RowModelFns.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/RowModelFns.ts#L11) + +Use this interface as a target for declaration merging to add your own plugin properties. +Note: This will affect the types of all tables in your project. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) diff --git a/docs/reference/interfaces/RowModelFns_RowSorting.md b/docs/reference/interfaces/RowModelFns_RowSorting.md new file mode 100644 index 0000000000..4965e01c44 --- /dev/null +++ b/docs/reference/interfaces/RowModelFns_RowSorting.md @@ -0,0 +1,28 @@ +--- +id: RowModelFns_RowSorting +title: RowModelFns_RowSorting +--- + +# Interface: RowModelFns\_RowSorting\ + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L21) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### sortFns + +```ts +sortFns: Record>; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:25](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L25) diff --git a/docs/reference/interfaces/RowPinningDefaultOptions.md b/docs/reference/interfaces/RowPinningDefaultOptions.md new file mode 100644 index 0000000000..6af186806e --- /dev/null +++ b/docs/reference/interfaces/RowPinningDefaultOptions.md @@ -0,0 +1,18 @@ +--- +id: RowPinningDefaultOptions +title: RowPinningDefaultOptions +--- + +# Interface: RowPinningDefaultOptions + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L34) + +## Properties + +### onRowPinningChange + +```ts +onRowPinningChange: OnChangeFn; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:35](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L35) diff --git a/docs/reference/interfaces/RowPinningState.md b/docs/reference/interfaces/RowPinningState.md new file mode 100644 index 0000000000..05688d6664 --- /dev/null +++ b/docs/reference/interfaces/RowPinningState.md @@ -0,0 +1,28 @@ +--- +id: RowPinningState +title: RowPinningState +--- + +# Interface: RowPinningState + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:7](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L7) + +## Properties + +### bottom + +```ts +bottom: string[]; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L8) + +*** + +### top + +```ts +top: string[]; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:9](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L9) diff --git a/docs/reference/interfaces/Row_ColumnFiltering.md b/docs/reference/interfaces/Row_ColumnFiltering.md new file mode 100644 index 0000000000..8e1e31304b --- /dev/null +++ b/docs/reference/interfaces/Row_ColumnFiltering.md @@ -0,0 +1,42 @@ +--- +id: Row_ColumnFiltering +title: Row_ColumnFiltering +--- + +# Interface: Row\_ColumnFiltering\ + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:129](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L129) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### columnFilters + +```ts +columnFilters: Record; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:136](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L136) + +The column filters map for the row. This object tracks whether a row is passing/failing specific filters by their column ID. + +*** + +### columnFiltersMeta + +```ts +columnFiltersMeta: Record; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:140](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L140) + +The column filters meta map for the row. This object tracks any filter meta for a row as optionally provided during the filtering process. diff --git a/docs/reference/interfaces/Row_ColumnGrouping.md b/docs/reference/interfaces/Row_ColumnGrouping.md new file mode 100644 index 0000000000..b49d60f8ce --- /dev/null +++ b/docs/reference/interfaces/Row_ColumnGrouping.md @@ -0,0 +1,80 @@ +--- +id: Row_ColumnGrouping +title: Row_ColumnGrouping +--- + +# Interface: Row\_ColumnGrouping + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:112](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L112) + +## Properties + +### \_groupingValuesCache + +```ts +_groupingValuesCache: Record; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:113](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L113) + +*** + +### getGroupingValue() + +```ts +getGroupingValue: (columnId) => unknown; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:117](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L117) + +Returns the grouping value for any row and column (including leaf rows). + +#### Parameters + +##### columnId + +`string` + +#### Returns + +`unknown` + +*** + +### getIsGrouped() + +```ts +getIsGrouped: () => boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:121](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L121) + +Returns whether or not the row is currently grouped. + +#### Returns + +`boolean` + +*** + +### groupingColumnId? + +```ts +optional groupingColumnId: string; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:125](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L125) + +If this row is grouped, this is the id of the column that this row is grouped by. + +*** + +### groupingValue? + +```ts +optional groupingValue: unknown; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:129](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L129) + +If this row is grouped, this is the unique/shared value for the `groupingColumnId` for all of the rows in this group. diff --git a/docs/reference/interfaces/Row_ColumnPinning.md b/docs/reference/interfaces/Row_ColumnPinning.md new file mode 100644 index 0000000000..158bbfc663 --- /dev/null +++ b/docs/reference/interfaces/Row_ColumnPinning.md @@ -0,0 +1,66 @@ +--- +id: Row_ColumnPinning +title: Row_ColumnPinning +--- + +# Interface: Row\_ColumnPinning\ + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:60](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L60) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getCenterVisibleCells() + +```ts +getCenterVisibleCells: () => Cell[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:67](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L67) + +Returns all center pinned (unpinned) leaf cells in the row. + +#### Returns + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getLeftVisibleCells() + +```ts +getLeftVisibleCells: () => Cell[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:71](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L71) + +Returns all left pinned leaf cells in the row. + +#### Returns + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getRightVisibleCells() + +```ts +getRightVisibleCells: () => Cell[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:75](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L75) + +Returns all right pinned leaf cells in the row. + +#### Returns + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/interfaces/Row_ColumnVisibility.md b/docs/reference/interfaces/Row_ColumnVisibility.md new file mode 100644 index 0000000000..1f0217d418 --- /dev/null +++ b/docs/reference/interfaces/Row_ColumnVisibility.md @@ -0,0 +1,48 @@ +--- +id: Row_ColumnVisibility +title: Row_ColumnVisibility +--- + +# Interface: Row\_ColumnVisibility\ + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:73](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L73) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getAllVisibleCells() + +```ts +getAllVisibleCells: () => Cell[]; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:77](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L77) + +#### Returns + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getVisibleCells() + +```ts +getVisibleCells: () => Cell[]; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:81](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L81) + +Returns an array of cells that account for column visibility for the row. + +#### Returns + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/interfaces/Row_Core.md b/docs/reference/interfaces/Row_Core.md new file mode 100644 index 0000000000..2a10923465 --- /dev/null +++ b/docs/reference/interfaces/Row_Core.md @@ -0,0 +1,372 @@ +--- +id: Row_Core +title: Row_Core +--- + +# Interface: Row\_Core\ + +Defined in: [types/Row.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Row.ts#L21) + +## Extends + +- [`Row_Row`](Row_Row.md)\<`TFeatures`, `TData`\> + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### \_uniqueValuesCache + +```ts +_uniqueValuesCache: Record; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L11) + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`_uniqueValuesCache`](Row_Row.md#_uniquevaluescache) + +*** + +### \_valuesCache + +```ts +_valuesCache: Record; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L12) + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`_valuesCache`](Row_Row.md#_valuescache) + +*** + +### depth + +```ts +depth: number; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L16) + +The depth of the row (if nested or grouped) relative to the root row array. + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`depth`](Row_Row.md#depth) + +*** + +### getAllCells() + +```ts +getAllCells: () => Cell[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:55](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L55) + +Returns all of the cells for the row. + +#### Returns + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>[] + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`getAllCells`](Row_Row.md#getallcells) + +*** + +### getAllCellsByColumnId() + +```ts +getAllCellsByColumnId: () => Record>; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:51](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L51) + +#### Returns + +`Record`\<`string`, [`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>\> + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`getAllCellsByColumnId`](Row_Row.md#getallcellsbycolumnid) + +*** + +### getLeafRows() + +```ts +getLeafRows: () => Row[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:59](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L59) + +Returns the leaf rows for the row, not including any parent rows. + +#### Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`getLeafRows`](Row_Row.md#getleafrows) + +*** + +### getParentRow() + +```ts +getParentRow: () => Row | undefined; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:63](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L63) + +Returns the parent row for the row, if it exists. + +#### Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> \| `undefined` + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`getParentRow`](Row_Row.md#getparentrow) + +*** + +### getParentRows() + +```ts +getParentRows: () => Row[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:67](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L67) + +Returns the parent rows for the row, all the way up to a root row. + +#### Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`getParentRows`](Row_Row.md#getparentrows) + +*** + +### getUniqueValues() + +```ts +getUniqueValues: (columnId) => TValue[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:71](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L71) + +Returns a unique array of values from the row for a given columnId. + +#### Type Parameters + +##### TValue + +`TValue` + +#### Parameters + +##### columnId + +`string` + +#### Returns + +`TValue`[] + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`getUniqueValues`](Row_Row.md#getuniquevalues) + +*** + +### getValue() + +```ts +getValue: (columnId) => TValue; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:75](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L75) + +Returns the value from the row for a given columnId. + +#### Type Parameters + +##### TValue + +`TValue` + +#### Parameters + +##### columnId + +`string` + +#### Returns + +`TValue` + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`getValue`](Row_Row.md#getvalue) + +*** + +### id + +```ts +id: string; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:20](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L20) + +The resolved unique identifier for the row resolved via the `options.getRowId` option. Defaults to the row's index (or relative index if it is a subRow). + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`id`](Row_Row.md#id) + +*** + +### index + +```ts +index: number; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:24](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L24) + +The index of the row within its parent array (or the root data array). + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`index`](Row_Row.md#index) + +*** + +### original + +```ts +original: TData; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:28](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L28) + +The original row object provided to the table. If the row is a grouped row, the original row object will be the first original in the group. + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`original`](Row_Row.md#original) + +*** + +### originalSubRows? + +```ts +optional originalSubRows: readonly TData[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:32](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L32) + +An array of the original subRows as returned by the `options.getSubRows` option. + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`originalSubRows`](Row_Row.md#originalsubrows) + +*** + +### parentId? + +```ts +optional parentId: string; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:36](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L36) + +If nested, this row's parent row id. + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`parentId`](Row_Row.md#parentid) + +*** + +### renderValue() + +```ts +renderValue: (columnId) => TValue; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:79](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L79) + +Renders the value for the row in a given columnId the same as `getValue`, but will return the `renderFallbackValue` if no value is found. + +#### Type Parameters + +##### TValue + +`TValue` + +#### Parameters + +##### columnId + +`string` + +#### Returns + +`TValue` + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`renderValue`](Row_Row.md#rendervalue) + +*** + +### subRows + +```ts +subRows: Row[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:40](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L40) + +An array of subRows for the row as returned and created by the `options.getSubRows` option. + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`subRows`](Row_Row.md#subrows) + +*** + +### table + +```ts +table: Table_Internal; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:44](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L44) + +Reference to the parent table instance. + +#### Inherited from + +[`Row_Row`](Row_Row.md).[`table`](Row_Row.md#table) diff --git a/docs/reference/interfaces/Row_CoreProperties.md b/docs/reference/interfaces/Row_CoreProperties.md new file mode 100644 index 0000000000..9c3736a03f --- /dev/null +++ b/docs/reference/interfaces/Row_CoreProperties.md @@ -0,0 +1,138 @@ +--- +id: Row_CoreProperties +title: Row_CoreProperties +--- + +# Interface: Row\_CoreProperties\ + +Defined in: [core/rows/coreRowsFeature.types.ts:7](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L7) + +## Extended by + +- [`Row_Row`](Row_Row.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### \_uniqueValuesCache + +```ts +_uniqueValuesCache: Record; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L11) + +*** + +### \_valuesCache + +```ts +_valuesCache: Record; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L12) + +*** + +### depth + +```ts +depth: number; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L16) + +The depth of the row (if nested or grouped) relative to the root row array. + +*** + +### id + +```ts +id: string; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:20](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L20) + +The resolved unique identifier for the row resolved via the `options.getRowId` option. Defaults to the row's index (or relative index if it is a subRow). + +*** + +### index + +```ts +index: number; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:24](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L24) + +The index of the row within its parent array (or the root data array). + +*** + +### original + +```ts +original: TData; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:28](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L28) + +The original row object provided to the table. If the row is a grouped row, the original row object will be the first original in the group. + +*** + +### originalSubRows? + +```ts +optional originalSubRows: readonly TData[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:32](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L32) + +An array of the original subRows as returned by the `options.getSubRows` option. + +*** + +### parentId? + +```ts +optional parentId: string; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:36](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L36) + +If nested, this row's parent row id. + +*** + +### subRows + +```ts +subRows: Row[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:40](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L40) + +An array of subRows for the row as returned and created by the `options.getSubRows` option. + +*** + +### table + +```ts +table: Table_Internal; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:44](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L44) + +Reference to the parent table instance. diff --git a/docs/reference/interfaces/Row_Plugins.md b/docs/reference/interfaces/Row_Plugins.md new file mode 100644 index 0000000000..2c6aa8f40b --- /dev/null +++ b/docs/reference/interfaces/Row_Plugins.md @@ -0,0 +1,21 @@ +--- +id: Row_Plugins +title: Row_Plugins +--- + +# Interface: Row\_Plugins\ + +Defined in: [types/Row.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Row.ts#L16) + +Use this interface as a target for declaration merging to add your own plugin properties. +Note: This will affect the types of all tables in your project. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) diff --git a/docs/reference/interfaces/Row_Row.md b/docs/reference/interfaces/Row_Row.md new file mode 100644 index 0000000000..8cd051c2bd --- /dev/null +++ b/docs/reference/interfaces/Row_Row.md @@ -0,0 +1,344 @@ +--- +id: Row_Row +title: Row_Row +--- + +# Interface: Row\_Row\ + +Defined in: [core/rows/coreRowsFeature.types.ts:47](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L47) + +## Extends + +- [`Row_CoreProperties`](Row_CoreProperties.md)\<`TFeatures`, `TData`\> + +## Extended by + +- [`Row_Core`](Row_Core.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### \_uniqueValuesCache + +```ts +_uniqueValuesCache: Record; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L11) + +#### Inherited from + +[`Row_CoreProperties`](Row_CoreProperties.md).[`_uniqueValuesCache`](Row_CoreProperties.md#_uniquevaluescache) + +*** + +### \_valuesCache + +```ts +_valuesCache: Record; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L12) + +#### Inherited from + +[`Row_CoreProperties`](Row_CoreProperties.md).[`_valuesCache`](Row_CoreProperties.md#_valuescache) + +*** + +### depth + +```ts +depth: number; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L16) + +The depth of the row (if nested or grouped) relative to the root row array. + +#### Inherited from + +[`Row_CoreProperties`](Row_CoreProperties.md).[`depth`](Row_CoreProperties.md#depth) + +*** + +### getAllCells() + +```ts +getAllCells: () => Cell[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:55](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L55) + +Returns all of the cells for the row. + +#### Returns + +[`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getAllCellsByColumnId() + +```ts +getAllCellsByColumnId: () => Record>; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:51](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L51) + +#### Returns + +`Record`\<`string`, [`Cell`](../type-aliases/Cell.md)\<`TFeatures`, `TData`, `unknown`\>\> + +*** + +### getLeafRows() + +```ts +getLeafRows: () => Row[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:59](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L59) + +Returns the leaf rows for the row, not including any parent rows. + +#### Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] + +*** + +### getParentRow() + +```ts +getParentRow: () => Row | undefined; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:63](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L63) + +Returns the parent row for the row, if it exists. + +#### Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> \| `undefined` + +*** + +### getParentRows() + +```ts +getParentRows: () => Row[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:67](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L67) + +Returns the parent rows for the row, all the way up to a root row. + +#### Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] + +*** + +### getUniqueValues() + +```ts +getUniqueValues: (columnId) => TValue[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:71](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L71) + +Returns a unique array of values from the row for a given columnId. + +#### Type Parameters + +##### TValue + +`TValue` + +#### Parameters + +##### columnId + +`string` + +#### Returns + +`TValue`[] + +*** + +### getValue() + +```ts +getValue: (columnId) => TValue; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:75](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L75) + +Returns the value from the row for a given columnId. + +#### Type Parameters + +##### TValue + +`TValue` + +#### Parameters + +##### columnId + +`string` + +#### Returns + +`TValue` + +*** + +### id + +```ts +id: string; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:20](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L20) + +The resolved unique identifier for the row resolved via the `options.getRowId` option. Defaults to the row's index (or relative index if it is a subRow). + +#### Inherited from + +[`Row_CoreProperties`](Row_CoreProperties.md).[`id`](Row_CoreProperties.md#id) + +*** + +### index + +```ts +index: number; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:24](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L24) + +The index of the row within its parent array (or the root data array). + +#### Inherited from + +[`Row_CoreProperties`](Row_CoreProperties.md).[`index`](Row_CoreProperties.md#index) + +*** + +### original + +```ts +original: TData; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:28](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L28) + +The original row object provided to the table. If the row is a grouped row, the original row object will be the first original in the group. + +#### Inherited from + +[`Row_CoreProperties`](Row_CoreProperties.md).[`original`](Row_CoreProperties.md#original) + +*** + +### originalSubRows? + +```ts +optional originalSubRows: readonly TData[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:32](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L32) + +An array of the original subRows as returned by the `options.getSubRows` option. + +#### Inherited from + +[`Row_CoreProperties`](Row_CoreProperties.md).[`originalSubRows`](Row_CoreProperties.md#originalsubrows) + +*** + +### parentId? + +```ts +optional parentId: string; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:36](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L36) + +If nested, this row's parent row id. + +#### Inherited from + +[`Row_CoreProperties`](Row_CoreProperties.md).[`parentId`](Row_CoreProperties.md#parentid) + +*** + +### renderValue() + +```ts +renderValue: (columnId) => TValue; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:79](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L79) + +Renders the value for the row in a given columnId the same as `getValue`, but will return the `renderFallbackValue` if no value is found. + +#### Type Parameters + +##### TValue + +`TValue` + +#### Parameters + +##### columnId + +`string` + +#### Returns + +`TValue` + +*** + +### subRows + +```ts +subRows: Row[]; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:40](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L40) + +An array of subRows for the row as returned and created by the `options.getSubRows` option. + +#### Inherited from + +[`Row_CoreProperties`](Row_CoreProperties.md).[`subRows`](Row_CoreProperties.md#subrows) + +*** + +### table + +```ts +table: Table_Internal; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:44](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L44) + +Reference to the parent table instance. + +#### Inherited from + +[`Row_CoreProperties`](Row_CoreProperties.md).[`table`](Row_CoreProperties.md#table) diff --git a/docs/reference/interfaces/Row_RowExpanding.md b/docs/reference/interfaces/Row_RowExpanding.md new file mode 100644 index 0000000000..3f6cbb0431 --- /dev/null +++ b/docs/reference/interfaces/Row_RowExpanding.md @@ -0,0 +1,100 @@ +--- +id: Row_RowExpanding +title: Row_RowExpanding +--- + +# Interface: Row\_RowExpanding + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L14) + +## Properties + +### getCanExpand() + +```ts +getCanExpand: () => boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L18) + +Returns whether the row can be expanded. + +#### Returns + +`boolean` + +*** + +### getIsAllParentsExpanded() + +```ts +getIsAllParentsExpanded: () => boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L22) + +Returns whether all parent rows of the row are expanded. + +#### Returns + +`boolean` + +*** + +### getIsExpanded() + +```ts +getIsExpanded: () => boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L26) + +Returns whether the row is expanded. + +#### Returns + +`boolean` + +*** + +### getToggleExpandedHandler() + +```ts +getToggleExpandedHandler: () => () => void; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L30) + +Returns a function that can be used to toggle the expanded state of the row. This function can be used to bind to an event handler to a button. + +#### Returns + +```ts +(): void; +``` + +##### Returns + +`void` + +*** + +### toggleExpanded() + +```ts +toggleExpanded: (expanded?) => void; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L34) + +Toggles the expanded state (or sets it if `expanded` is provided) for the row. + +#### Parameters + +##### expanded? + +`boolean` + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Row_RowPinning.md b/docs/reference/interfaces/Row_RowPinning.md new file mode 100644 index 0000000000..3e0a282398 --- /dev/null +++ b/docs/reference/interfaces/Row_RowPinning.md @@ -0,0 +1,86 @@ +--- +id: Row_RowPinning +title: Row_RowPinning +--- + +# Interface: Row\_RowPinning + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L38) + +## Properties + +### getCanPin() + +```ts +getCanPin: () => boolean; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L42) + +Returns whether or not the row can be pinned. + +#### Returns + +`boolean` + +*** + +### getIsPinned() + +```ts +getIsPinned: () => RowPinningPosition; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:46](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L46) + +Returns the pinned position of the row. (`'top'`, `'bottom'` or `false`) + +#### Returns + +[`RowPinningPosition`](../type-aliases/RowPinningPosition.md) + +*** + +### getPinnedIndex() + +```ts +getPinnedIndex: () => number; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:50](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L50) + +Returns the numeric pinned index of the row within a pinned row group. + +#### Returns + +`number` + +*** + +### pin() + +```ts +pin: (position, includeLeafRows?, includeParentRows?) => void; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:54](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L54) + +Pins a row to the `'top'` or `'bottom'`, or unpins the row to the center if `false` is passed. + +#### Parameters + +##### position + +[`RowPinningPosition`](../type-aliases/RowPinningPosition.md) + +##### includeLeafRows? + +`boolean` + +##### includeParentRows? + +`boolean` + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Row_RowSelection.md b/docs/reference/interfaces/Row_RowSelection.md new file mode 100644 index 0000000000..2aaa594ae2 --- /dev/null +++ b/docs/reference/interfaces/Row_RowSelection.md @@ -0,0 +1,160 @@ +--- +id: Row_RowSelection +title: Row_RowSelection +--- + +# Interface: Row\_RowSelection + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:48](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L48) + +## Properties + +### getCanMultiSelect() + +```ts +getCanMultiSelect: () => boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:52](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L52) + +Returns whether or not the row can multi-select. + +#### Returns + +`boolean` + +*** + +### getCanSelect() + +```ts +getCanSelect: () => boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:56](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L56) + +Returns whether or not the row can be selected. + +#### Returns + +`boolean` + +*** + +### getCanSelectSubRows() + +```ts +getCanSelectSubRows: () => boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:60](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L60) + +Returns whether or not the row can select sub rows automatically when the parent row is selected. + +#### Returns + +`boolean` + +*** + +### getIsAllSubRowsSelected() + +```ts +getIsAllSubRowsSelected: () => boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:64](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L64) + +Returns whether or not all of the row's sub rows are selected. + +#### Returns + +`boolean` + +*** + +### getIsSelected() + +```ts +getIsSelected: () => boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:68](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L68) + +Returns whether or not the row is selected. + +#### Returns + +`boolean` + +*** + +### getIsSomeSelected() + +```ts +getIsSomeSelected: () => boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:72](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L72) + +Returns whether or not some of the row's sub rows are selected. + +#### Returns + +`boolean` + +*** + +### getToggleSelectedHandler() + +```ts +getToggleSelectedHandler: () => (event) => void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:76](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L76) + +Returns a handler that can be used to toggle the row. + +#### Returns + +```ts +(event): void; +``` + +##### Parameters + +###### event + +`unknown` + +##### Returns + +`void` + +*** + +### toggleSelected() + +```ts +toggleSelected: (value?, opts?) => void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:80](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L80) + +Selects/deselects the row. + +#### Parameters + +##### value? + +`boolean` + +##### opts? + +###### selectChildren? + +`boolean` + +#### Returns + +`void` diff --git a/docs/reference/interfaces/SortFn.md b/docs/reference/interfaces/SortFn.md new file mode 100644 index 0000000000..0b8acdf8f9 --- /dev/null +++ b/docs/reference/interfaces/SortFn.md @@ -0,0 +1,45 @@ +--- +id: SortFn +title: SortFn +--- + +# Interface: SortFn()\ + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L30) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +```ts +SortFn( + rowA, + rowB, + columnId): number; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L34) + +## Parameters + +### rowA + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +### rowB + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +### columnId + +`string` + +## Returns + +`number` diff --git a/docs/reference/interfaces/SortFns.md b/docs/reference/interfaces/SortFns.md new file mode 100644 index 0000000000..ded705adcf --- /dev/null +++ b/docs/reference/interfaces/SortFns.md @@ -0,0 +1,8 @@ +--- +id: SortFns +title: SortFns +--- + +# Interface: SortFns + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:28](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L28) diff --git a/docs/reference/interfaces/StockFeatures.md b/docs/reference/interfaces/StockFeatures.md new file mode 100644 index 0000000000..c8a8f99e48 --- /dev/null +++ b/docs/reference/interfaces/StockFeatures.md @@ -0,0 +1,148 @@ +--- +id: StockFeatures +title: StockFeatures +--- + +# Interface: StockFeatures + +Defined in: [features/stockFeatures.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L16) + +## Properties + +### columnFacetingFeature + +```ts +columnFacetingFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L17) + +*** + +### columnFilteringFeature + +```ts +columnFilteringFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L18) + +*** + +### columnGroupingFeature + +```ts +columnGroupingFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:19](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L19) + +*** + +### columnOrderingFeature + +```ts +columnOrderingFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:20](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L20) + +*** + +### columnPinningFeature + +```ts +columnPinningFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L21) + +*** + +### columnResizingFeature + +```ts +columnResizingFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L22) + +*** + +### columnSizingFeature + +```ts +columnSizingFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L23) + +*** + +### columnVisibilityFeature + +```ts +columnVisibilityFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:24](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L24) + +*** + +### globalFilteringFeature + +```ts +globalFilteringFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:25](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L25) + +*** + +### rowExpandingFeature + +```ts +rowExpandingFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L26) + +*** + +### rowPaginationFeature + +```ts +rowPaginationFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L27) + +*** + +### rowPinningFeature + +```ts +rowPinningFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:28](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L28) + +*** + +### rowSelectionFeature + +```ts +rowSelectionFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L29) + +*** + +### rowSortingFeature + +```ts +rowSortingFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L30) diff --git a/docs/reference/interfaces/StringHeaderIdentifier.md b/docs/reference/interfaces/StringHeaderIdentifier.md new file mode 100644 index 0000000000..6b5b0a6d8a --- /dev/null +++ b/docs/reference/interfaces/StringHeaderIdentifier.md @@ -0,0 +1,28 @@ +--- +id: StringHeaderIdentifier +title: StringHeaderIdentifier +--- + +# Interface: StringHeaderIdentifier + +Defined in: [types/ColumnDef.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L45) + +## Properties + +### header + +```ts +header: string; +``` + +Defined in: [types/ColumnDef.ts:46](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L46) + +*** + +### id? + +```ts +optional id: string; +``` + +Defined in: [types/ColumnDef.ts:47](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L47) diff --git a/docs/reference/interfaces/TableFeature.md b/docs/reference/interfaces/TableFeature.md new file mode 100644 index 0000000000..e8862f8205 --- /dev/null +++ b/docs/reference/interfaces/TableFeature.md @@ -0,0 +1,122 @@ +--- +id: TableFeature +title: TableFeature +--- + +# Interface: TableFeature\ + +Defined in: [types/TableFeatures.ts:116](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L116) + +## Type Parameters + +### TConstructors + +`TConstructors` *extends* `FeatureConstructors` + +## Properties + +### assignCellPrototype? + +```ts +optional assignCellPrototype: AssignCellPrototype; +``` + +Defined in: [types/TableFeatures.ts:121](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L121) + +Assigns Cell APIs to the cell prototype for memory-efficient method sharing. +This is called once per table to build a shared prototype for all cells. + +*** + +### assignColumnPrototype? + +```ts +optional assignColumnPrototype: AssignColumnPrototype; +``` + +Defined in: [types/TableFeatures.ts:126](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L126) + +Assigns Column APIs to the column prototype for memory-efficient method sharing. +This is called once per table to build a shared prototype for all columns. + +*** + +### assignHeaderPrototype? + +```ts +optional assignHeaderPrototype: AssignHeaderPrototype; +``` + +Defined in: [types/TableFeatures.ts:131](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L131) + +Assigns Header APIs to the header prototype for memory-efficient method sharing. +This is called once per table to build a shared prototype for all headers. + +*** + +### assignRowPrototype? + +```ts +optional assignRowPrototype: AssignRowPrototype; +``` + +Defined in: [types/TableFeatures.ts:136](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L136) + +Assigns Row APIs to the row prototype for memory-efficient method sharing. +This is called once per table to build a shared prototype for all rows. + +*** + +### constructTableAPIs? + +```ts +optional constructTableAPIs: ConstructTableAPIs; +``` + +Defined in: [types/TableFeatures.ts:141](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L141) + +Assigns Table APIs to the table instance. +Unlike row/cell/column/header, the table is a singleton so methods are assigned directly. + +*** + +### getDefaultColumnDef? + +```ts +optional getDefaultColumnDef: GetDefaultColumnDef; +``` + +Defined in: [types/TableFeatures.ts:142](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L142) + +*** + +### getDefaultTableOptions? + +```ts +optional getDefaultTableOptions: GetDefaultTableOptions; +``` + +Defined in: [types/TableFeatures.ts:143](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L143) + +*** + +### getInitialState? + +```ts +optional getInitialState: GetInitialState; +``` + +Defined in: [types/TableFeatures.ts:144](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L144) + +*** + +### initRowInstanceData? + +```ts +optional initRowInstanceData: InitRowInstanceData; +``` + +Defined in: [types/TableFeatures.ts:149](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L149) + +Initializes instance-specific data on each row (e.g., caches). +Methods should be assigned via assignRowPrototype instead. diff --git a/docs/reference/interfaces/TableFeatures.md b/docs/reference/interfaces/TableFeatures.md new file mode 100644 index 0000000000..5d052fa608 --- /dev/null +++ b/docs/reference/interfaces/TableFeatures.md @@ -0,0 +1,292 @@ +--- +id: TableFeatures +title: TableFeatures +--- + +# Interface: TableFeatures + +Defined in: [types/TableFeatures.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L42) + +## Extends + +- `Partial`\<[`CoreFeatures`](CoreFeatures.md)\>.`Partial`\<[`StockFeatures`](StockFeatures.md)\>.`Partial`\<[`Plugins`](Plugins.md)\> + +## Properties + +### columnFacetingFeature? + +```ts +optional columnFacetingFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L17) + +#### Inherited from + +[`StockFeatures`](StockFeatures.md).[`columnFacetingFeature`](StockFeatures.md#columnfacetingfeature) + +*** + +### columnFilteringFeature? + +```ts +optional columnFilteringFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L18) + +#### Inherited from + +[`StockFeatures`](StockFeatures.md).[`columnFilteringFeature`](StockFeatures.md#columnfilteringfeature) + +*** + +### columnGroupingFeature? + +```ts +optional columnGroupingFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:19](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L19) + +#### Inherited from + +[`StockFeatures`](StockFeatures.md).[`columnGroupingFeature`](StockFeatures.md#columngroupingfeature) + +*** + +### columnOrderingFeature? + +```ts +optional columnOrderingFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:20](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L20) + +#### Inherited from + +[`StockFeatures`](StockFeatures.md).[`columnOrderingFeature`](StockFeatures.md#columnorderingfeature) + +*** + +### columnPinningFeature? + +```ts +optional columnPinningFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L21) + +#### Inherited from + +[`StockFeatures`](StockFeatures.md).[`columnPinningFeature`](StockFeatures.md#columnpinningfeature) + +*** + +### columnResizingFeature? + +```ts +optional columnResizingFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L22) + +#### Inherited from + +[`StockFeatures`](StockFeatures.md).[`columnResizingFeature`](StockFeatures.md#columnresizingfeature) + +*** + +### columnSizingFeature? + +```ts +optional columnSizingFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L23) + +#### Inherited from + +[`StockFeatures`](StockFeatures.md).[`columnSizingFeature`](StockFeatures.md#columnsizingfeature) + +*** + +### columnVisibilityFeature? + +```ts +optional columnVisibilityFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:24](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L24) + +#### Inherited from + +[`StockFeatures`](StockFeatures.md).[`columnVisibilityFeature`](StockFeatures.md#columnvisibilityfeature) + +*** + +### coreCellsFeature? + +```ts +optional coreCellsFeature: TableFeature>; +``` + +Defined in: [core/coreFeatures.ts:9](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/coreFeatures.ts#L9) + +#### Inherited from + +[`CoreFeatures`](CoreFeatures.md).[`coreCellsFeature`](CoreFeatures.md#corecellsfeature) + +*** + +### coreColumnsFeature? + +```ts +optional coreColumnsFeature: TableFeature>; +``` + +Defined in: [core/coreFeatures.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/coreFeatures.ts#L10) + +#### Inherited from + +[`CoreFeatures`](CoreFeatures.md).[`coreColumnsFeature`](CoreFeatures.md#corecolumnsfeature) + +*** + +### coreHeadersFeature? + +```ts +optional coreHeadersFeature: TableFeature>; +``` + +Defined in: [core/coreFeatures.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/coreFeatures.ts#L11) + +#### Inherited from + +[`CoreFeatures`](CoreFeatures.md).[`coreHeadersFeature`](CoreFeatures.md#coreheadersfeature) + +*** + +### coreRowModelsFeature? + +```ts +optional coreRowModelsFeature: TableFeature>; +``` + +Defined in: [core/coreFeatures.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/coreFeatures.ts#L12) + +#### Inherited from + +[`CoreFeatures`](CoreFeatures.md).[`coreRowModelsFeature`](CoreFeatures.md#corerowmodelsfeature) + +*** + +### coreRowsFeature? + +```ts +optional coreRowsFeature: TableFeature>; +``` + +Defined in: [core/coreFeatures.ts:13](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/coreFeatures.ts#L13) + +#### Inherited from + +[`CoreFeatures`](CoreFeatures.md).[`coreRowsFeature`](CoreFeatures.md#corerowsfeature) + +*** + +### coreTablesFeature? + +```ts +optional coreTablesFeature: TableFeature>; +``` + +Defined in: [core/coreFeatures.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/coreFeatures.ts#L14) + +#### Inherited from + +[`CoreFeatures`](CoreFeatures.md).[`coreTablesFeature`](CoreFeatures.md#coretablesfeature) + +*** + +### globalFilteringFeature? + +```ts +optional globalFilteringFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:25](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L25) + +#### Inherited from + +[`StockFeatures`](StockFeatures.md).[`globalFilteringFeature`](StockFeatures.md#globalfilteringfeature) + +*** + +### rowExpandingFeature? + +```ts +optional rowExpandingFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L26) + +#### Inherited from + +[`StockFeatures`](StockFeatures.md).[`rowExpandingFeature`](StockFeatures.md#rowexpandingfeature) + +*** + +### rowPaginationFeature? + +```ts +optional rowPaginationFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L27) + +#### Inherited from + +[`StockFeatures`](StockFeatures.md).[`rowPaginationFeature`](StockFeatures.md#rowpaginationfeature) + +*** + +### rowPinningFeature? + +```ts +optional rowPinningFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:28](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L28) + +#### Inherited from + +[`StockFeatures`](StockFeatures.md).[`rowPinningFeature`](StockFeatures.md#rowpinningfeature) + +*** + +### rowSelectionFeature? + +```ts +optional rowSelectionFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L29) + +#### Inherited from + +[`StockFeatures`](StockFeatures.md).[`rowSelectionFeature`](StockFeatures.md#rowselectionfeature) + +*** + +### rowSortingFeature? + +```ts +optional rowSortingFeature: TableFeature>; +``` + +Defined in: [features/stockFeatures.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L30) + +#### Inherited from + +[`StockFeatures`](StockFeatures.md).[`rowSortingFeature`](StockFeatures.md#rowsortingfeature) diff --git a/docs/reference/interfaces/TableMeta.md b/docs/reference/interfaces/TableMeta.md new file mode 100644 index 0000000000..97579c5732 --- /dev/null +++ b/docs/reference/interfaces/TableMeta.md @@ -0,0 +1,18 @@ +--- +id: TableMeta +title: TableMeta +--- + +# Interface: TableMeta\ + +Defined in: [core/table/coreTablesFeature.types.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L10) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) diff --git a/docs/reference/interfaces/TableOptions_Cell.md b/docs/reference/interfaces/TableOptions_Cell.md new file mode 100644 index 0000000000..6846124858 --- /dev/null +++ b/docs/reference/interfaces/TableOptions_Cell.md @@ -0,0 +1,24 @@ +--- +id: TableOptions_Cell +title: TableOptions_Cell +--- + +# Interface: TableOptions\_Cell + +Defined in: [core/cells/coreCellsFeature.types.ts:63](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L63) + +## Extended by + +- [`TableOptions_Core`](TableOptions_Core.md) + +## Properties + +### renderFallbackValue? + +```ts +optional renderFallbackValue: any; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:67](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L67) + +Value used when the desired value is not found in the data. diff --git a/docs/reference/interfaces/TableOptions_ColumnFiltering.md b/docs/reference/interfaces/TableOptions_ColumnFiltering.md new file mode 100644 index 0000000000..a30779d166 --- /dev/null +++ b/docs/reference/interfaces/TableOptions_ColumnFiltering.md @@ -0,0 +1,92 @@ +--- +id: TableOptions_ColumnFiltering +title: TableOptions_ColumnFiltering +--- + +# Interface: TableOptions\_ColumnFiltering\ + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:143](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L143) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### enableColumnFilters? + +```ts +optional enableColumnFilters: boolean; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:150](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L150) + +Enables/disables **column** filtering for all columns. + +*** + +### enableFilters? + +```ts +optional enableFilters: boolean; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:154](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L154) + +Enables/disables all filtering for the table. + +*** + +### filterFromLeafRows? + +```ts +optional filterFromLeafRows: boolean; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:158](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L158) + +By default, filtering is done from parent rows down (so if a parent row is filtered out, all of its children will be filtered out as well). Setting this option to `true` will cause filtering to be done from leaf rows up (which means parent rows will be included so long as one of their child or grand-child rows is also included). + +*** + +### manualFiltering? + +```ts +optional manualFiltering: boolean; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:162](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L162) + +Disables the `getFilteredRowModel` from being used to filter data. This may be useful if your table needs to dynamically support both client-side and server-side filtering. + +*** + +### maxLeafRowFilterDepth? + +```ts +optional maxLeafRowFilterDepth: number; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:168](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L168) + +By default, filtering is done for all rows (max depth of 100), no matter if they are root level parent rows or the child leaf rows of a parent row. Setting this option to `0` will cause filtering to only be applied to the root level parent rows, with all sub-rows remaining unfiltered. Similarly, setting this option to `1` will cause filtering to only be applied to child leaf rows 1 level deep, and so on. + +This is useful for situations where you want a row's entire child hierarchy to be visible regardless of the applied filter. + +*** + +### onColumnFiltersChange? + +```ts +optional onColumnFiltersChange: OnChangeFn; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:172](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L172) + +If provided, this function will be called with an `updaterFn` when `state.columnFilters` changes. This overrides the default internal state management, so you will need to persist the state change either fully or partially outside of the table. diff --git a/docs/reference/interfaces/TableOptions_ColumnGrouping.md b/docs/reference/interfaces/TableOptions_ColumnGrouping.md new file mode 100644 index 0000000000..115314b992 --- /dev/null +++ b/docs/reference/interfaces/TableOptions_ColumnGrouping.md @@ -0,0 +1,56 @@ +--- +id: TableOptions_ColumnGrouping +title: TableOptions_ColumnGrouping +--- + +# Interface: TableOptions\_ColumnGrouping + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:152](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L152) + +## Properties + +### enableGrouping? + +```ts +optional enableGrouping: boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:156](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L156) + +Enables/disables grouping for the table. + +*** + +### groupedColumnMode? + +```ts +optional groupedColumnMode: false | "reorder" | "remove"; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:160](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L160) + +Grouping columns are automatically reordered by default to the start of the columns list. If you would rather remove them or leave them as-is, set the appropriate mode here. + +*** + +### manualGrouping? + +```ts +optional manualGrouping: boolean; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:164](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L164) + +Enables manual grouping. If this option is set to `true`, the table will not automatically group rows using `getGroupedRowModel()` and instead will expect you to manually group the rows before passing them to the table. This is useful if you are doing server-side grouping and aggregation. + +*** + +### onGroupingChange? + +```ts +optional onGroupingChange: OnChangeFn; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:168](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L168) + +If this function is provided, it will be called when the grouping state changes and you will be expected to manage the state yourself. You can pass the managed state back to the table via the `tableOptions.state.grouping` option. diff --git a/docs/reference/interfaces/TableOptions_ColumnOrdering.md b/docs/reference/interfaces/TableOptions_ColumnOrdering.md new file mode 100644 index 0000000000..ce1dc62dae --- /dev/null +++ b/docs/reference/interfaces/TableOptions_ColumnOrdering.md @@ -0,0 +1,20 @@ +--- +id: TableOptions_ColumnOrdering +title: TableOptions_ColumnOrdering +--- + +# Interface: TableOptions\_ColumnOrdering + +Defined in: [features/column-ordering/columnOrderingFeature.types.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.types.ts#L11) + +## Properties + +### onColumnOrderChange? + +```ts +optional onColumnOrderChange: OnChangeFn; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.types.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.types.ts#L15) + +If provided, this function will be called with an `updaterFn` when `state.columnOrder` changes. This overrides the default internal state management, so you will need to persist the state change either fully or partially outside of the table. diff --git a/docs/reference/interfaces/TableOptions_ColumnPinning.md b/docs/reference/interfaces/TableOptions_ColumnPinning.md new file mode 100644 index 0000000000..7ddef6e6aa --- /dev/null +++ b/docs/reference/interfaces/TableOptions_ColumnPinning.md @@ -0,0 +1,32 @@ +--- +id: TableOptions_ColumnPinning +title: TableOptions_ColumnPinning +--- + +# Interface: TableOptions\_ColumnPinning + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:19](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L19) + +## Properties + +### enableColumnPinning? + +```ts +optional enableColumnPinning: boolean; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L23) + +Enables/disables column pinning for the table. Defaults to `true`. + +*** + +### onColumnPinningChange? + +```ts +optional onColumnPinningChange: OnChangeFn; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L27) + +If provided, this function will be called with an `updaterFn` when `state.columnPinning` changes. This overrides the default internal state management, so you will also need to supply `state.columnPinning` from your own managed state. diff --git a/docs/reference/interfaces/TableOptions_ColumnResizing.md b/docs/reference/interfaces/TableOptions_ColumnResizing.md new file mode 100644 index 0000000000..604e4b99e1 --- /dev/null +++ b/docs/reference/interfaces/TableOptions_ColumnResizing.md @@ -0,0 +1,56 @@ +--- +id: TableOptions_ColumnResizing +title: TableOptions_ColumnResizing +--- + +# Interface: TableOptions\_ColumnResizing + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:20](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L20) + +## Properties + +### columnResizeDirection? + +```ts +optional columnResizeDirection: ColumnResizeDirection; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:32](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L32) + +Enables or disables right-to-left support for resizing the column. defaults to 'ltr'. + +*** + +### columnResizeMode? + +```ts +optional columnResizeMode: ColumnResizeMode; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:24](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L24) + +Determines when the columnSizing state is updated. `onChange` updates the state when the user is dragging the resize handle. `onEnd` updates the state when the user releases the resize handle. + +*** + +### enableColumnResizing? + +```ts +optional enableColumnResizing: boolean; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:28](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L28) + +Enables or disables column resizing for the column. + +*** + +### onColumnResizingChange? + +```ts +optional onColumnResizingChange: OnChangeFn; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:36](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L36) + +If provided, this function will be called with an `updaterFn` when `state.columnResizing` changes. This overrides the default internal state management, so you will also need to supply `state.columnResizing` from your own managed state. diff --git a/docs/reference/interfaces/TableOptions_ColumnSizing.md b/docs/reference/interfaces/TableOptions_ColumnSizing.md new file mode 100644 index 0000000000..9793c4722e --- /dev/null +++ b/docs/reference/interfaces/TableOptions_ColumnSizing.md @@ -0,0 +1,20 @@ +--- +id: TableOptions_ColumnSizing +title: TableOptions_ColumnSizing +--- + +# Interface: TableOptions\_ColumnSizing + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L10) + +## Properties + +### onColumnSizingChange? + +```ts +optional onColumnSizingChange: OnChangeFn; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L14) + +If provided, this function will be called with an `updaterFn` when `state.columnSizing` changes. This overrides the default internal state management, so you will also need to supply `state.columnSizing` from your own managed state. diff --git a/docs/reference/interfaces/TableOptions_ColumnVisibility.md b/docs/reference/interfaces/TableOptions_ColumnVisibility.md new file mode 100644 index 0000000000..8732dc8407 --- /dev/null +++ b/docs/reference/interfaces/TableOptions_ColumnVisibility.md @@ -0,0 +1,32 @@ +--- +id: TableOptions_ColumnVisibility +title: TableOptions_ColumnVisibility +--- + +# Interface: TableOptions\_ColumnVisibility + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L12) + +## Properties + +### enableHiding? + +```ts +optional enableHiding: boolean; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L16) + +Whether to enable column hiding. Defaults to `true`. + +*** + +### onColumnVisibilityChange? + +```ts +optional onColumnVisibilityChange: OnChangeFn; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:20](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L20) + +If provided, this function will be called with an `updaterFn` when `state.columnVisibility` changes. This overrides the default internal state management, so you will need to persist the state change either fully or partially outside of the table. diff --git a/docs/reference/interfaces/TableOptions_Columns.md b/docs/reference/interfaces/TableOptions_Columns.md new file mode 100644 index 0000000000..45ae5215df --- /dev/null +++ b/docs/reference/interfaces/TableOptions_Columns.md @@ -0,0 +1,50 @@ +--- +id: TableOptions_Columns +title: TableOptions_Columns +--- + +# Interface: TableOptions\_Columns\ + +Defined in: [core/columns/coreColumnsFeature.types.ts:60](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L60) + +## Extended by + +- [`TableOptions_Core`](TableOptions_Core.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](../type-aliases/CellData.md) = [`CellData`](../type-aliases/CellData.md) + +## Properties + +### columns + +```ts +columns: readonly ColumnDef[]; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:68](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L68) + +The array of column defs to use for the table. + +*** + +### defaultColumn? + +```ts +optional defaultColumn: Partial>; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:72](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L72) + +Default column options to use for all column defs supplied to the table. diff --git a/docs/reference/interfaces/TableOptions_Core.md b/docs/reference/interfaces/TableOptions_Core.md new file mode 100644 index 0000000000..fc93daeec1 --- /dev/null +++ b/docs/reference/interfaces/TableOptions_Core.md @@ -0,0 +1,305 @@ +--- +id: TableOptions_Core +title: TableOptions_Core +--- + +# Interface: TableOptions\_Core\ + +Defined in: [types/TableOptions.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableOptions.ts#L27) + +## Extends + +- [`TableOptions_Table`](TableOptions_Table.md)\<`TFeatures`, `TData`\>.[`TableOptions_Cell`](TableOptions_Cell.md).[`TableOptions_Columns`](TableOptions_Columns.md)\<`TFeatures`, `TData`\>.[`TableOptions_Rows`](TableOptions_Rows.md)\<`TFeatures`, `TData`\> + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### \_features + +```ts +_features: TFeatures; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L22) + +The features that you want to enable for the table. + +#### Inherited from + +[`TableOptions_Table`](TableOptions_Table.md).[`_features`](TableOptions_Table.md#_features) + +*** + +### \_rowModels? + +```ts +optional _rowModels: CreateRowModels_All; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L26) + +The row model options that you want to enable for the table. + +#### Inherited from + +[`TableOptions_Table`](TableOptions_Table.md).[`_rowModels`](TableOptions_Table.md#_rowmodels) + +*** + +### autoResetAll? + +```ts +optional autoResetAll: boolean; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L30) + +Set this option to override any of the `autoReset...` feature options. + +#### Inherited from + +[`TableOptions_Table`](TableOptions_Table.md).[`autoResetAll`](TableOptions_Table.md#autoresetall) + +*** + +### columns + +```ts +columns: readonly ColumnDef[]; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:68](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L68) + +The array of column defs to use for the table. + +#### Inherited from + +[`TableOptions_Columns`](TableOptions_Columns.md).[`columns`](TableOptions_Columns.md#columns) + +*** + +### data + +```ts +data: readonly TData[]; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L34) + +The data for the table to display. When the `data` option changes reference, the table will reprocess the data. + +#### Inherited from + +[`TableOptions_Table`](TableOptions_Table.md).[`data`](TableOptions_Table.md#data) + +*** + +### defaultColumn? + +```ts +optional defaultColumn: Partial>; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:72](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L72) + +Default column options to use for all column defs supplied to the table. + +#### Inherited from + +[`TableOptions_Columns`](TableOptions_Columns.md).[`defaultColumn`](TableOptions_Columns.md#defaultcolumn) + +*** + +### getRowId()? + +```ts +optional getRowId: (originalRow, index, parent?) => string; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:90](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L90) + +This optional function is used to derive a unique ID for any given row. If not provided the rows index is used (nested rows join together with `.` using their grandparents' index eg. `index.index.index`). If you need to identify individual rows that are originating from any server-side operations, it's suggested you use this function to return an ID that makes sense regardless of network IO/ambiguity eg. a userId, taskId, database ID field, etc. + +#### Parameters + +##### originalRow + +`TData` + +##### index + +`number` + +##### parent? + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +#### Returns + +`string` + +#### Example + +```ts +getRowId: row => row.userId +``` + +#### Inherited from + +[`TableOptions_Rows`](TableOptions_Rows.md).[`getRowId`](TableOptions_Rows.md#getrowid) + +*** + +### getSubRows()? + +```ts +optional getSubRows: (originalRow, index) => readonly TData[] | undefined; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:99](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L99) + +This optional function is used to access the sub rows for any given row. If you are using nested rows, you will need to use this function to return the sub rows object (or undefined) from the row. + +#### Parameters + +##### originalRow + +`TData` + +##### index + +`number` + +#### Returns + +readonly `TData`[] \| `undefined` + +#### Example + +```ts +getSubRows: row => row.subRows +``` + +#### Inherited from + +[`TableOptions_Rows`](TableOptions_Rows.md).[`getSubRows`](TableOptions_Rows.md#getsubrows) + +*** + +### initialState? + +```ts +optional initialState: Partial>; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:39](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L39) + +Use this option to optionally pass initial state to the table. This state will be used when resetting various table states either automatically by the table (eg. `options.autoResetPageIndex`) or via functions like `table.resetRowSelection()`. Most reset function allow you optionally pass a flag to reset to a blank/default state instead of the initial state. +Table state will not be reset when this object changes, which also means that the initial state object does not need to be stable. + +#### Inherited from + +[`TableOptions_Table`](TableOptions_Table.md).[`initialState`](TableOptions_Table.md#initialstate) + +*** + +### mergeOptions()? + +```ts +optional mergeOptions: (defaultOptions, options) => TableOptions; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:43](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L43) + +This option is used to optionally implement the merging of table options. + +#### Parameters + +##### defaultOptions + +[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\> + +##### options + +`Partial`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>\> + +#### Returns + +[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\> + +#### Inherited from + +[`TableOptions_Table`](TableOptions_Table.md).[`mergeOptions`](TableOptions_Table.md#mergeoptions) + +*** + +### meta? + +```ts +optional meta: TableMeta; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:50](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L50) + +You can pass any object to `options.meta` and access it anywhere the `table` is available via `table.options.meta`. + +#### Inherited from + +[`TableOptions_Table`](TableOptions_Table.md).[`meta`](TableOptions_Table.md#meta) + +*** + +### renderFallbackValue? + +```ts +optional renderFallbackValue: any; +``` + +Defined in: [core/cells/coreCellsFeature.types.ts:67](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.types.ts#L67) + +Value used when the desired value is not found in the data. + +#### Inherited from + +[`TableOptions_Cell`](TableOptions_Cell.md).[`renderFallbackValue`](TableOptions_Cell.md#renderfallbackvalue) + +*** + +### state? + +```ts +optional state: Partial>; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:54](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L54) + +Pass in individual self-managed state to the table. + +#### Inherited from + +[`TableOptions_Table`](TableOptions_Table.md).[`state`](TableOptions_Table.md#state) + +*** + +### store? + +```ts +optional store: Store>; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:58](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L58) + +Optionally, provide your own external TanStack Store instance if you want to manage the table state externally. + +#### Inherited from + +[`TableOptions_Table`](TableOptions_Table.md).[`store`](TableOptions_Table.md#store) diff --git a/docs/reference/interfaces/TableOptions_GlobalFiltering.md b/docs/reference/interfaces/TableOptions_GlobalFiltering.md new file mode 100644 index 0000000000..72f179ead5 --- /dev/null +++ b/docs/reference/interfaces/TableOptions_GlobalFiltering.md @@ -0,0 +1,94 @@ +--- +id: TableOptions_GlobalFiltering +title: TableOptions_GlobalFiltering +--- + +# Interface: TableOptions\_GlobalFiltering\ + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:32](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L32) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### enableGlobalFilter? + +```ts +optional enableGlobalFilter: boolean; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:39](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L39) + +Enables/disables **global** filtering for all columns. + +*** + +### getColumnCanGlobalFilter()? + +```ts +optional getColumnCanGlobalFilter: (column) => boolean; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:44](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L44) + +If provided, this function will be called with the column and should return `true` or `false` to indicate whether this column should be used for global filtering. +This is useful if the column can contain data that is not `string` or `number` (i.e. `undefined`). + +#### Type Parameters + +##### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +##### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +##### TValue + +`TValue` *extends* `unknown` = `unknown` + +#### Parameters + +##### column + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `TValue`\> + +#### Returns + +`boolean` + +*** + +### globalFilterFn? + +```ts +optional globalFilterFn: FilterFnOption; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:57](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L57) + +The filter function to use for global filtering. +- A `string` referencing a built-in filter function +- A `string` that references a custom filter functions provided via the `tableOptions.filterFns` option +- A custom filter function + +*** + +### onGlobalFilterChange? + +```ts +optional onGlobalFilterChange: OnChangeFn; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:61](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L61) + +If provided, this function will be called with an `updaterFn` when `state.globalFilter` changes. This overrides the default internal state management, so you will need to persist the state change either fully or partially outside of the table. diff --git a/docs/reference/interfaces/TableOptions_Plugins.md b/docs/reference/interfaces/TableOptions_Plugins.md new file mode 100644 index 0000000000..a5efa5289b --- /dev/null +++ b/docs/reference/interfaces/TableOptions_Plugins.md @@ -0,0 +1,18 @@ +--- +id: TableOptions_Plugins +title: TableOptions_Plugins +--- + +# Interface: TableOptions\_Plugins\ + +Defined in: [types/TableOptions.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableOptions.ts#L22) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) diff --git a/docs/reference/interfaces/TableOptions_RowExpanding.md b/docs/reference/interfaces/TableOptions_RowExpanding.md new file mode 100644 index 0000000000..14e411901f --- /dev/null +++ b/docs/reference/interfaces/TableOptions_RowExpanding.md @@ -0,0 +1,122 @@ +--- +id: TableOptions_RowExpanding +title: TableOptions_RowExpanding +--- + +# Interface: TableOptions\_RowExpanding\ + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:37](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L37) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### autoResetExpanded? + +```ts +optional autoResetExpanded: boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:44](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L44) + +Enable this setting to automatically reset the expanded state of the table when expanding state changes. + +*** + +### enableExpanding? + +```ts +optional enableExpanding: boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:48](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L48) + +Enable/disable expanding for all rows. + +*** + +### getIsRowExpanded()? + +```ts +optional getIsRowExpanded: (row) => boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:52](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L52) + +If provided, allows you to override the default behavior of determining whether a row is currently expanded. + +#### Parameters + +##### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +#### Returns + +`boolean` + +*** + +### getRowCanExpand()? + +```ts +optional getRowCanExpand: (row) => boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:56](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L56) + +If provided, allows you to override the default behavior of determining whether a row can be expanded. + +#### Parameters + +##### row + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +#### Returns + +`boolean` + +*** + +### manualExpanding? + +```ts +optional manualExpanding: boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:60](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L60) + +Enables manual row expansion. If this is set to `true`, `getExpandedRowModel` will not be used to expand rows and you would be expected to perform the expansion in your own data model. This is useful if you are doing server-side expansion. + +*** + +### onExpandedChange? + +```ts +optional onExpandedChange: OnChangeFn; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:64](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L64) + +This function is called when the `expanded` table state changes. If a function is provided, you will be responsible for managing this state on your own. To pass the managed state back to the table, use the `tableOptions.state.expanded` option. + +*** + +### paginateExpandedRows? + +```ts +optional paginateExpandedRows: boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:68](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L68) + +If `true` expanded rows will be paginated along with the rest of the table (which means expanded rows may span multiple pages). If `false` expanded rows will not be considered for pagination (which means expanded rows will always render on their parents page. This also means more rows will be rendered than the set page size) diff --git a/docs/reference/interfaces/TableOptions_RowPagination.md b/docs/reference/interfaces/TableOptions_RowPagination.md new file mode 100644 index 0000000000..faf7c8dda7 --- /dev/null +++ b/docs/reference/interfaces/TableOptions_RowPagination.md @@ -0,0 +1,68 @@ +--- +id: TableOptions_RowPagination +title: TableOptions_RowPagination +--- + +# Interface: TableOptions\_RowPagination + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L15) + +## Properties + +### autoResetPageIndex? + +```ts +optional autoResetPageIndex: boolean; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:19](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L19) + +If set to `true`, pagination will be reset to the first page when page-altering state changes eg. `data` is updated, filters change, grouping changes, etc. + +*** + +### manualPagination? + +```ts +optional manualPagination: boolean; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L23) + +Enables manual pagination. If this option is set to `true`, the table will not automatically paginate rows using `getPaginatedRowModel()` and instead will expect you to manually paginate the rows before passing them to the table. This is useful if you are doing server-side pagination and aggregation. + +*** + +### onPaginationChange? + +```ts +optional onPaginationChange: OnChangeFn; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L27) + +If this function is provided, it will be called when the pagination state changes and you will be expected to manage the state yourself. You can pass the managed state back to the table via the `tableOptions.state.pagination` option. + +*** + +### pageCount? + +```ts +optional pageCount: number; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:31](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L31) + +When manually controlling pagination, you can supply a total `pageCount` value to the table if you know it (Or supply a `rowCount` and `pageCount` will be calculated). If you do not know how many pages there are, you can set this to `-1`. + +*** + +### rowCount? + +```ts +optional rowCount: number; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:35](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L35) + +When manually controlling pagination, you can supply a total `rowCount` value to the table if you know it. The `pageCount` can be calculated from this value and the `pageSize`. diff --git a/docs/reference/interfaces/TableOptions_RowPinning.md b/docs/reference/interfaces/TableOptions_RowPinning.md new file mode 100644 index 0000000000..fdaec54fc9 --- /dev/null +++ b/docs/reference/interfaces/TableOptions_RowPinning.md @@ -0,0 +1,54 @@ +--- +id: TableOptions_RowPinning +title: TableOptions_RowPinning +--- + +# Interface: TableOptions\_RowPinning\ + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L16) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### enableRowPinning? + +```ts +optional enableRowPinning: boolean | (row) => boolean; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L23) + +Enables/disables row pinning for the table. Defaults to `true`. + +*** + +### keepPinnedRows? + +```ts +optional keepPinnedRows: boolean; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L27) + +When `false`, pinned rows will not be visible if they are filtered or paginated out of the table. When `true`, pinned rows will always be visible regardless of filtering or pagination. Defaults to `true`. + +*** + +### onRowPinningChange? + +```ts +optional onRowPinningChange: OnChangeFn; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:31](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L31) + +If provided, this function will be called with an `updaterFn` when `state.rowPinning` changes. This overrides the default internal state management, so you will also need to supply `state.rowPinning` from your own managed state. diff --git a/docs/reference/interfaces/TableOptions_RowSelection.md b/docs/reference/interfaces/TableOptions_RowSelection.md new file mode 100644 index 0000000000..ceecea0860 --- /dev/null +++ b/docs/reference/interfaces/TableOptions_RowSelection.md @@ -0,0 +1,69 @@ +--- +id: TableOptions_RowSelection +title: TableOptions_RowSelection +--- + +# Interface: TableOptions\_RowSelection\ + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L12) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### enableMultiRowSelection? + +```ts +optional enableMultiRowSelection: boolean | (row) => boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:20](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L20) + +- Enables/disables multiple row selection for all rows in the table OR +- A function that given a row, returns whether to enable/disable multiple row selection for that row's children/grandchildren + +*** + +### enableRowSelection? + +```ts +optional enableRowSelection: boolean | (row) => boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:25](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L25) + +- Enables/disables row selection for all rows in the table OR +- A function that given a row, returns whether to enable/disable row selection for that row + +*** + +### enableSubRowSelection? + +```ts +optional enableSubRowSelection: boolean | (row) => boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L30) + +Enables/disables automatic sub-row selection when a parent row is selected, or a function that enables/disables automatic sub-row selection for each row. +(Use in combination with expanding or grouping features) + +*** + +### onRowSelectionChange? + +```ts +optional onRowSelectionChange: OnChangeFn; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L34) + +If provided, this function will be called with an `updaterFn` when `state.rowSelection` changes. This overrides the default internal state management, so you will need to persist the state change either fully or partially outside of the table. diff --git a/docs/reference/interfaces/TableOptions_RowSorting.md b/docs/reference/interfaces/TableOptions_RowSorting.md new file mode 100644 index 0000000000..3a9bb53eb5 --- /dev/null +++ b/docs/reference/interfaces/TableOptions_RowSorting.md @@ -0,0 +1,128 @@ +--- +id: TableOptions_RowSorting +title: TableOptions_RowSorting +--- + +# Interface: TableOptions\_RowSorting + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:143](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L143) + +## Properties + +### enableMultiRemove? + +```ts +optional enableMultiRemove: boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:147](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L147) + +Enables/disables the ability to remove multi-sorts + +*** + +### enableMultiSort? + +```ts +optional enableMultiSort: boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:151](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L151) + +Enables/Disables multi-sorting for the table. + +*** + +### enableSorting? + +```ts +optional enableSorting: boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:155](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L155) + +Enables/Disables sorting for the table. + +*** + +### enableSortingRemoval? + +```ts +optional enableSortingRemoval: boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:161](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L161) + +Enables/Disables the ability to remove sorting for the table. +- If `true` then changing sort order will circle like: 'none' -> 'desc' -> 'asc' -> 'none' -> ... +- If `false` then changing sort order will circle like: 'none' -> 'desc' -> 'asc' -> 'desc' -> 'asc' -> ... + +*** + +### isMultiSortEvent()? + +```ts +optional isMultiSortEvent: (e) => boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:165](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L165) + +Pass a custom function that will be used to determine if a multi-sort event should be triggered. It is passed the event from the sort toggle handler and should return `true` if the event should trigger a multi-sort. + +#### Parameters + +##### e + +`unknown` + +#### Returns + +`boolean` + +*** + +### manualSorting? + +```ts +optional manualSorting: boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:169](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L169) + +Enables manual sorting for the table. If this is `true`, you will be expected to sort your data before it is passed to the table. This is useful if you are doing server-side sorting. + +*** + +### maxMultiSortColCount? + +```ts +optional maxMultiSortColCount: number; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:173](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L173) + +Set a maximum number of columns that can be multi-sorted. + +*** + +### onSortingChange? + +```ts +optional onSortingChange: OnChangeFn; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:177](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L177) + +If provided, this function will be called with an `updaterFn` when `state.sorting` changes. This overrides the default internal state management, so you will need to persist the state change either fully or partially outside of the table. + +*** + +### sortDescFirst? + +```ts +optional sortDescFirst: boolean; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:181](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L181) + +If `true`, all sorts will default to descending as their first toggle state. diff --git a/docs/reference/interfaces/TableOptions_Rows.md b/docs/reference/interfaces/TableOptions_Rows.md new file mode 100644 index 0000000000..232a3fa0d1 --- /dev/null +++ b/docs/reference/interfaces/TableOptions_Rows.md @@ -0,0 +1,90 @@ +--- +id: TableOptions_Rows +title: TableOptions_Rows +--- + +# Interface: TableOptions\_Rows\ + +Defined in: [core/rows/coreRowsFeature.types.ts:82](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L82) + +## Extended by + +- [`TableOptions_Core`](TableOptions_Core.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getRowId()? + +```ts +optional getRowId: (originalRow, index, parent?) => string; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:90](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L90) + +This optional function is used to derive a unique ID for any given row. If not provided the rows index is used (nested rows join together with `.` using their grandparents' index eg. `index.index.index`). If you need to identify individual rows that are originating from any server-side operations, it's suggested you use this function to return an ID that makes sense regardless of network IO/ambiguity eg. a userId, taskId, database ID field, etc. + +#### Parameters + +##### originalRow + +`TData` + +##### index + +`number` + +##### parent? + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +#### Returns + +`string` + +#### Example + +```ts +getRowId: row => row.userId +``` + +*** + +### getSubRows()? + +```ts +optional getSubRows: (originalRow, index) => readonly TData[] | undefined; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:99](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L99) + +This optional function is used to access the sub rows for any given row. If you are using nested rows, you will need to use this function to return the sub rows object (or undefined) from the row. + +#### Parameters + +##### originalRow + +`TData` + +##### index + +`number` + +#### Returns + +readonly `TData`[] \| `undefined` + +#### Example + +```ts +getSubRows: row => row.subRows +``` diff --git a/docs/reference/interfaces/TableOptions_Table.md b/docs/reference/interfaces/TableOptions_Table.md new file mode 100644 index 0000000000..5914559720 --- /dev/null +++ b/docs/reference/interfaces/TableOptions_Table.md @@ -0,0 +1,145 @@ +--- +id: TableOptions_Table +title: TableOptions_Table +--- + +# Interface: TableOptions\_Table\ + +Defined in: [core/table/coreTablesFeature.types.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L15) + +## Extended by + +- [`TableOptions_Core`](TableOptions_Core.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### \_features + +```ts +_features: TFeatures; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L22) + +The features that you want to enable for the table. + +*** + +### \_rowModels? + +```ts +optional _rowModels: CreateRowModels_All; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L26) + +The row model options that you want to enable for the table. + +*** + +### autoResetAll? + +```ts +optional autoResetAll: boolean; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L30) + +Set this option to override any of the `autoReset...` feature options. + +*** + +### data + +```ts +data: readonly TData[]; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L34) + +The data for the table to display. When the `data` option changes reference, the table will reprocess the data. + +*** + +### initialState? + +```ts +optional initialState: Partial>; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:39](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L39) + +Use this option to optionally pass initial state to the table. This state will be used when resetting various table states either automatically by the table (eg. `options.autoResetPageIndex`) or via functions like `table.resetRowSelection()`. Most reset function allow you optionally pass a flag to reset to a blank/default state instead of the initial state. +Table state will not be reset when this object changes, which also means that the initial state object does not need to be stable. + +*** + +### mergeOptions()? + +```ts +optional mergeOptions: (defaultOptions, options) => TableOptions; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:43](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L43) + +This option is used to optionally implement the merging of table options. + +#### Parameters + +##### defaultOptions + +[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\> + +##### options + +`Partial`\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>\> + +#### Returns + +[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\> + +*** + +### meta? + +```ts +optional meta: TableMeta; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:50](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L50) + +You can pass any object to `options.meta` and access it anywhere the `table` is available via `table.options.meta`. + +*** + +### state? + +```ts +optional state: Partial>; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:54](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L54) + +Pass in individual self-managed state to the table. + +*** + +### store? + +```ts +optional store: Store>; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:58](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L58) + +Optionally, provide your own external TanStack Store instance if you want to manage the table state externally. diff --git a/docs/reference/interfaces/TableState_ColumnFiltering.md b/docs/reference/interfaces/TableState_ColumnFiltering.md new file mode 100644 index 0000000000..16e4146660 --- /dev/null +++ b/docs/reference/interfaces/TableState_ColumnFiltering.md @@ -0,0 +1,18 @@ +--- +id: TableState_ColumnFiltering +title: TableState_ColumnFiltering +--- + +# Interface: TableState\_ColumnFiltering + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L18) + +## Properties + +### columnFilters + +```ts +columnFilters: ColumnFiltersState; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:19](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L19) diff --git a/docs/reference/interfaces/TableState_ColumnGrouping.md b/docs/reference/interfaces/TableState_ColumnGrouping.md new file mode 100644 index 0000000000..ab7605d5ef --- /dev/null +++ b/docs/reference/interfaces/TableState_ColumnGrouping.md @@ -0,0 +1,18 @@ +--- +id: TableState_ColumnGrouping +title: TableState_ColumnGrouping +--- + +# Interface: TableState\_ColumnGrouping + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L17) + +## Properties + +### grouping + +```ts +grouping: GroupingState; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L18) diff --git a/docs/reference/interfaces/TableState_ColumnOrdering.md b/docs/reference/interfaces/TableState_ColumnOrdering.md new file mode 100644 index 0000000000..805e587675 --- /dev/null +++ b/docs/reference/interfaces/TableState_ColumnOrdering.md @@ -0,0 +1,18 @@ +--- +id: TableState_ColumnOrdering +title: TableState_ColumnOrdering +--- + +# Interface: TableState\_ColumnOrdering + +Defined in: [features/column-ordering/columnOrderingFeature.types.ts:7](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.types.ts#L7) + +## Properties + +### columnOrder + +```ts +columnOrder: ColumnOrderState; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.types.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.types.ts#L8) diff --git a/docs/reference/interfaces/TableState_ColumnPinning.md b/docs/reference/interfaces/TableState_ColumnPinning.md new file mode 100644 index 0000000000..305207947d --- /dev/null +++ b/docs/reference/interfaces/TableState_ColumnPinning.md @@ -0,0 +1,18 @@ +--- +id: TableState_ColumnPinning +title: TableState_ColumnPinning +--- + +# Interface: TableState\_ColumnPinning + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L15) + +## Properties + +### columnPinning + +```ts +columnPinning: ColumnPinningState; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L16) diff --git a/docs/reference/interfaces/TableState_ColumnResizing.md b/docs/reference/interfaces/TableState_ColumnResizing.md new file mode 100644 index 0000000000..3a5119ade5 --- /dev/null +++ b/docs/reference/interfaces/TableState_ColumnResizing.md @@ -0,0 +1,18 @@ +--- +id: TableState_ColumnResizing +title: TableState_ColumnResizing +--- + +# Interface: TableState\_ColumnResizing + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:3](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L3) + +## Properties + +### columnResizing + +```ts +columnResizing: columnResizingState; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:4](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L4) diff --git a/docs/reference/interfaces/TableState_ColumnSizing.md b/docs/reference/interfaces/TableState_ColumnSizing.md new file mode 100644 index 0000000000..ec1ca1803a --- /dev/null +++ b/docs/reference/interfaces/TableState_ColumnSizing.md @@ -0,0 +1,18 @@ +--- +id: TableState_ColumnSizing +title: TableState_ColumnSizing +--- + +# Interface: TableState\_ColumnSizing + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:4](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L4) + +## Properties + +### columnSizing + +```ts +columnSizing: ColumnSizingState; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:5](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L5) diff --git a/docs/reference/interfaces/TableState_ColumnVisibility.md b/docs/reference/interfaces/TableState_ColumnVisibility.md new file mode 100644 index 0000000000..398c53102c --- /dev/null +++ b/docs/reference/interfaces/TableState_ColumnVisibility.md @@ -0,0 +1,18 @@ +--- +id: TableState_ColumnVisibility +title: TableState_ColumnVisibility +--- + +# Interface: TableState\_ColumnVisibility + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L8) + +## Properties + +### columnVisibility + +```ts +columnVisibility: ColumnVisibilityState; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:9](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L9) diff --git a/docs/reference/interfaces/TableState_GlobalFiltering.md b/docs/reference/interfaces/TableState_GlobalFiltering.md new file mode 100644 index 0000000000..743bd69f0c --- /dev/null +++ b/docs/reference/interfaces/TableState_GlobalFiltering.md @@ -0,0 +1,18 @@ +--- +id: TableState_GlobalFiltering +title: TableState_GlobalFiltering +--- + +# Interface: TableState\_GlobalFiltering + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L14) + +## Properties + +### globalFilter + +```ts +globalFilter: any; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L15) diff --git a/docs/reference/interfaces/TableState_Plugins.md b/docs/reference/interfaces/TableState_Plugins.md new file mode 100644 index 0000000000..ba298669ee --- /dev/null +++ b/docs/reference/interfaces/TableState_Plugins.md @@ -0,0 +1,17 @@ +--- +id: TableState_Plugins +title: TableState_Plugins +--- + +# Interface: TableState\_Plugins\ + +Defined in: [types/TableState.ts:21](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableState.ts#L21) + +Use this interface as a target for declaration merging to add your own state properties. +Note: This will affect the types of all tables in your project. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) diff --git a/docs/reference/interfaces/TableState_RowExpanding.md b/docs/reference/interfaces/TableState_RowExpanding.md new file mode 100644 index 0000000000..f644139305 --- /dev/null +++ b/docs/reference/interfaces/TableState_RowExpanding.md @@ -0,0 +1,18 @@ +--- +id: TableState_RowExpanding +title: TableState_RowExpanding +--- + +# Interface: TableState\_RowExpanding + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L10) + +## Properties + +### expanded + +```ts +expanded: ExpandedState; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L11) diff --git a/docs/reference/interfaces/TableState_RowPagination.md b/docs/reference/interfaces/TableState_RowPagination.md new file mode 100644 index 0000000000..d7581a58e8 --- /dev/null +++ b/docs/reference/interfaces/TableState_RowPagination.md @@ -0,0 +1,18 @@ +--- +id: TableState_RowPagination +title: TableState_RowPagination +--- + +# Interface: TableState\_RowPagination + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L11) + +## Properties + +### pagination + +```ts +pagination: PaginationState; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L12) diff --git a/docs/reference/interfaces/TableState_RowPinning.md b/docs/reference/interfaces/TableState_RowPinning.md new file mode 100644 index 0000000000..5a88ccec43 --- /dev/null +++ b/docs/reference/interfaces/TableState_RowPinning.md @@ -0,0 +1,18 @@ +--- +id: TableState_RowPinning +title: TableState_RowPinning +--- + +# Interface: TableState\_RowPinning + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L12) + +## Properties + +### rowPinning + +```ts +rowPinning: RowPinningState; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:13](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L13) diff --git a/docs/reference/interfaces/TableState_RowSelection.md b/docs/reference/interfaces/TableState_RowSelection.md new file mode 100644 index 0000000000..eb3ea16b29 --- /dev/null +++ b/docs/reference/interfaces/TableState_RowSelection.md @@ -0,0 +1,18 @@ +--- +id: TableState_RowSelection +title: TableState_RowSelection +--- + +# Interface: TableState\_RowSelection + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L8) + +## Properties + +### rowSelection + +```ts +rowSelection: RowSelectionState; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:9](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L9) diff --git a/docs/reference/interfaces/TableState_RowSorting.md b/docs/reference/interfaces/TableState_RowSorting.md new file mode 100644 index 0000000000..252d9a7611 --- /dev/null +++ b/docs/reference/interfaces/TableState_RowSorting.md @@ -0,0 +1,18 @@ +--- +id: TableState_RowSorting +title: TableState_RowSorting +--- + +# Interface: TableState\_RowSorting + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L17) + +## Properties + +### sorting + +```ts +sorting: SortingState; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L18) diff --git a/docs/reference/interfaces/Table_ColumnFaceting.md b/docs/reference/interfaces/Table_ColumnFaceting.md new file mode 100644 index 0000000000..0f8385afea --- /dev/null +++ b/docs/reference/interfaces/Table_ColumnFaceting.md @@ -0,0 +1,66 @@ +--- +id: Table_ColumnFaceting +title: Table_ColumnFaceting +--- + +# Interface: Table\_ColumnFaceting\ + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:81](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L81) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getGlobalFacetedMinMaxValues() + +```ts +getGlobalFacetedMinMaxValues: () => [number, number] | undefined; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:88](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L88) + +Returns the min and max values for the global filter. + +#### Returns + +\[`number`, `number`\] \| `undefined` + +*** + +### getGlobalFacetedRowModel() + +```ts +getGlobalFacetedRowModel: () => RowModel; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:92](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L92) + +Returns the row model for the table after **global** filtering has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### getGlobalFacetedUniqueValues() + +```ts +getGlobalFacetedUniqueValues: () => Map; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:96](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L96) + +Returns the faceted unique values for the global filter. + +#### Returns + +`Map`\<`any`, `number`\> diff --git a/docs/reference/interfaces/Table_ColumnFiltering.md b/docs/reference/interfaces/Table_ColumnFiltering.md new file mode 100644 index 0000000000..193d6f9ce5 --- /dev/null +++ b/docs/reference/interfaces/Table_ColumnFiltering.md @@ -0,0 +1,52 @@ +--- +id: Table_ColumnFiltering +title: Table_ColumnFiltering +--- + +# Interface: Table\_ColumnFiltering + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:175](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L175) + +## Properties + +### resetColumnFilters() + +```ts +resetColumnFilters: (defaultState?) => void; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:179](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L179) + +Resets the **columnFilters** state to `initialState.columnFilters`, or `true` can be passed to force a default blank state reset to `[]`. + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### setColumnFilters() + +```ts +setColumnFilters: (updater) => void; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:183](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L183) + +Sets or updates the `state.columnFilters` state. + +#### Parameters + +##### updater + +[`Updater`](../type-aliases/Updater.md)\<[`ColumnFiltersState`](../type-aliases/ColumnFiltersState.md)\> + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Table_ColumnGrouping.md b/docs/reference/interfaces/Table_ColumnGrouping.md new file mode 100644 index 0000000000..efcec9ca0d --- /dev/null +++ b/docs/reference/interfaces/Table_ColumnGrouping.md @@ -0,0 +1,62 @@ +--- +id: Table_ColumnGrouping +title: Table_ColumnGrouping +--- + +# Interface: Table\_ColumnGrouping\ + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:173](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L173) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### resetGrouping() + +```ts +resetGrouping: (defaultState?) => void; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:180](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L180) + +Resets the **grouping** state to `initialState.grouping`, or `true` can be passed to force a default blank state reset to `[]`. + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### setGrouping() + +```ts +setGrouping: (updater) => void; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:184](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L184) + +Updates the grouping state of the table via an update function or value. + +#### Parameters + +##### updater + +[`Updater`](../type-aliases/Updater.md)\<[`GroupingState`](../type-aliases/GroupingState.md)\> + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Table_ColumnOrdering.md b/docs/reference/interfaces/Table_ColumnOrdering.md new file mode 100644 index 0000000000..7a3367bae3 --- /dev/null +++ b/docs/reference/interfaces/Table_ColumnOrdering.md @@ -0,0 +1,62 @@ +--- +id: Table_ColumnOrdering +title: Table_ColumnOrdering +--- + +# Interface: Table\_ColumnOrdering\ + +Defined in: [features/column-ordering/columnOrderingFeature.types.ts:37](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.types.ts#L37) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### resetColumnOrder() + +```ts +resetColumnOrder: (defaultState?) => void; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.types.ts:44](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.types.ts#L44) + +Resets the **columnOrder** state to `initialState.columnOrder`, or `true` can be passed to force a default blank state reset to `[]`. + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### setColumnOrder() + +```ts +setColumnOrder: (updater) => void; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.types.ts:48](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.types.ts#L48) + +Sets or updates the `state.columnOrder` state. + +#### Parameters + +##### updater + +[`Updater`](../type-aliases/Updater.md)\<[`ColumnOrderState`](../type-aliases/ColumnOrderState.md)\> + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Table_ColumnPinning.md b/docs/reference/interfaces/Table_ColumnPinning.md new file mode 100644 index 0000000000..578ab0fe66 --- /dev/null +++ b/docs/reference/interfaces/Table_ColumnPinning.md @@ -0,0 +1,412 @@ +--- +id: Table_ColumnPinning +title: Table_ColumnPinning +--- + +# Interface: Table\_ColumnPinning\ + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:78](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L78) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getCenterFlatHeaders() + +```ts +getCenterFlatHeaders: () => Header[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:85](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L85) + +If pinning, returns headers for all columns that are not pinned, including parent headers. + +#### Returns + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getCenterFooterGroups() + +```ts +getCenterFooterGroups: () => HeaderGroup[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:89](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L89) + +If pinning, returns the footer groups for columns that are not pinned. + +#### Returns + +[`HeaderGroup`](../type-aliases/HeaderGroup.md)\<`TFeatures`, `TData`\>[] + +*** + +### getCenterHeaderGroups() + +```ts +getCenterHeaderGroups: () => HeaderGroup[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:93](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L93) + +If pinning, returns the header groups for columns that are not pinned. + +#### Returns + +[`HeaderGroup`](../type-aliases/HeaderGroup.md)\<`TFeatures`, `TData`\>[] + +*** + +### getCenterLeafColumns() + +```ts +getCenterLeafColumns: () => Column[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:97](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L97) + +Returns all center pinned (unpinned) leaf columns. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getCenterLeafHeaders() + +```ts +getCenterLeafHeaders: () => Header[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:101](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L101) + +If pinning, returns headers for all columns that are not pinned, (not including parent headers). + +#### Returns + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getCenterVisibleLeafColumns() + +```ts +getCenterVisibleLeafColumns: () => Column[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:105](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L105) + +If column pinning, returns a flat array of leaf-node columns that are visible in the unpinned/center portion of the table. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getIsSomeColumnsPinned() + +```ts +getIsSomeColumnsPinned: (position?) => boolean; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:109](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L109) + +Returns whether or not any columns are pinned. Optionally specify to only check for pinned columns in either the `left` or `right` position. + +#### Parameters + +##### position? + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) + +#### Returns + +`boolean` + +*** + +### getLeftFlatHeaders() + +```ts +getLeftFlatHeaders: () => Header[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:113](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L113) + +If pinning, returns headers for all left pinned columns in the table, including parent headers. + +#### Returns + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getLeftFooterGroups() + +```ts +getLeftFooterGroups: () => HeaderGroup[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:117](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L117) + +If pinning, returns the footer groups for the left pinned columns. + +#### Returns + +[`HeaderGroup`](../type-aliases/HeaderGroup.md)\<`TFeatures`, `TData`\>[] + +*** + +### getLeftHeaderGroups() + +```ts +getLeftHeaderGroups: () => HeaderGroup[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:121](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L121) + +If pinning, returns the header groups for the left pinned columns. + +#### Returns + +[`HeaderGroup`](../type-aliases/HeaderGroup.md)\<`TFeatures`, `TData`\>[] + +*** + +### getLeftLeafColumns() + +```ts +getLeftLeafColumns: () => Column[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:125](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L125) + +Returns all left pinned leaf columns. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getLeftLeafHeaders() + +```ts +getLeftLeafHeaders: () => Header[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:129](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L129) + +If pinning, returns headers for all left pinned leaf columns in the table, (not including parent headers). + +#### Returns + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getLeftVisibleLeafColumns() + +```ts +getLeftVisibleLeafColumns: () => Column[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:133](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L133) + +If column pinning, returns a flat array of leaf-node columns that are visible in the left portion of the table. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getPinnedLeafColumns() + +```ts +getPinnedLeafColumns: (position) => Column[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:168](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L168) + +#### Parameters + +##### position + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) | `"center"` + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getPinnedVisibleLeafColumns() + +```ts +getPinnedVisibleLeafColumns: (position) => Column[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:173](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L173) + +#### Parameters + +##### position + +[`ColumnPinningPosition`](../type-aliases/ColumnPinningPosition.md) | `"center"` + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getRightFlatHeaders() + +```ts +getRightFlatHeaders: () => Header[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:137](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L137) + +If pinning, returns headers for all right pinned columns in the table, including parent headers. + +#### Returns + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getRightFooterGroups() + +```ts +getRightFooterGroups: () => HeaderGroup[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:141](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L141) + +If pinning, returns the footer groups for the right pinned columns. + +#### Returns + +[`HeaderGroup`](../type-aliases/HeaderGroup.md)\<`TFeatures`, `TData`\>[] + +*** + +### getRightHeaderGroups() + +```ts +getRightHeaderGroups: () => HeaderGroup[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:145](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L145) + +If pinning, returns the header groups for the right pinned columns. + +#### Returns + +[`HeaderGroup`](../type-aliases/HeaderGroup.md)\<`TFeatures`, `TData`\>[] + +*** + +### getRightLeafColumns() + +```ts +getRightLeafColumns: () => Column[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:149](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L149) + +Returns all right pinned leaf columns. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getRightLeafHeaders() + +```ts +getRightLeafHeaders: () => Header[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:153](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L153) + +If pinning, returns headers for all right pinned leaf columns in the table, (not including parent headers). + +#### Returns + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getRightVisibleLeafColumns() + +```ts +getRightVisibleLeafColumns: () => Column[]; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:157](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L157) + +If column pinning, returns a flat array of leaf-node columns that are visible in the right portion of the table. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### resetColumnPinning() + +```ts +resetColumnPinning: (defaultState?) => void; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:161](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L161) + +Resets the **columnPinning** state to `initialState.columnPinning`, or `true` can be passed to force a default blank state reset to `{ left: [], right: [], }`. + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### setColumnPinning() + +```ts +setColumnPinning: (updater) => void; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:165](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L165) + +Sets or updates the `state.columnPinning` state. + +#### Parameters + +##### updater + +[`Updater`](../type-aliases/Updater.md)\<[`ColumnPinningState`](ColumnPinningState.md)\> + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Table_ColumnResizing.md b/docs/reference/interfaces/Table_ColumnResizing.md new file mode 100644 index 0000000000..efaa8d8786 --- /dev/null +++ b/docs/reference/interfaces/Table_ColumnResizing.md @@ -0,0 +1,52 @@ +--- +id: Table_ColumnResizing +title: Table_ColumnResizing +--- + +# Interface: Table\_ColumnResizing + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:44](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L44) + +## Properties + +### resetHeaderSizeInfo() + +```ts +resetHeaderSizeInfo: (defaultState?) => void; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:48](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L48) + +Resets column sizing info to its initial state. If `defaultState` is `true`, the default state for the table will be used instead of the initialValue provided to the table. + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### setcolumnResizing() + +```ts +setcolumnResizing: (updater) => void; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:52](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L52) + +Sets the column sizing info state using an updater function or a value. This will trigger the underlying `oncolumnResizingChange` function if one is passed to the table options, otherwise the state will be managed automatically by the table. + +#### Parameters + +##### updater + +[`Updater`](../type-aliases/Updater.md)\<[`columnResizingState`](columnResizingState.md)\> + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Table_ColumnSizing.md b/docs/reference/interfaces/Table_ColumnSizing.md new file mode 100644 index 0000000000..b5fdf4cdbb --- /dev/null +++ b/docs/reference/interfaces/Table_ColumnSizing.md @@ -0,0 +1,116 @@ +--- +id: Table_ColumnSizing +title: Table_ColumnSizing +--- + +# Interface: Table\_ColumnSizing + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L22) + +## Properties + +### getCenterTotalSize() + +```ts +getCenterTotalSize: () => number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L26) + +If pinning, returns the total size of the center portion of the table by calculating the sum of the sizes of all unpinned/center leaf-columns. + +#### Returns + +`number` + +*** + +### getLeftTotalSize() + +```ts +getLeftTotalSize: () => number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L30) + +Returns the total size of the left portion of the table by calculating the sum of the sizes of all left leaf-columns. + +#### Returns + +`number` + +*** + +### getRightTotalSize() + +```ts +getRightTotalSize: () => number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:34](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L34) + +Returns the total size of the right portion of the table by calculating the sum of the sizes of all right leaf-columns. + +#### Returns + +`number` + +*** + +### getTotalSize() + +```ts +getTotalSize: () => number; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L38) + +Returns the total size of the table by calculating the sum of the sizes of all leaf-columns. + +#### Returns + +`number` + +*** + +### resetColumnSizing() + +```ts +resetColumnSizing: (defaultState?) => void; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L42) + +Resets column sizing to its initial state. If `defaultState` is `true`, the default state for the table will be used instead of the initialValue provided to the table. + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### setColumnSizing() + +```ts +setColumnSizing: (updater) => void; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:46](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L46) + +Sets the column sizing state using an updater function or a value. This will trigger the underlying `onColumnSizingChange` function if one is passed to the table options, otherwise the state will be managed automatically by the table. + +#### Parameters + +##### updater + +[`Updater`](../type-aliases/Updater.md)\<[`ColumnSizingState`](../type-aliases/ColumnSizingState.md)\> + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Table_ColumnVisibility.md b/docs/reference/interfaces/Table_ColumnVisibility.md new file mode 100644 index 0000000000..0308854161 --- /dev/null +++ b/docs/reference/interfaces/Table_ColumnVisibility.md @@ -0,0 +1,176 @@ +--- +id: Table_ColumnVisibility +title: Table_ColumnVisibility +--- + +# Interface: Table\_ColumnVisibility\ + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:28](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L28) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getIsAllColumnsVisible() + +```ts +getIsAllColumnsVisible: () => boolean; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:35](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L35) + +Returns whether all columns are visible + +#### Returns + +`boolean` + +*** + +### getIsSomeColumnsVisible() + +```ts +getIsSomeColumnsVisible: () => boolean; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:39](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L39) + +Returns whether any columns are visible + +#### Returns + +`boolean` + +*** + +### getToggleAllColumnsVisibilityHandler() + +```ts +getToggleAllColumnsVisibilityHandler: () => (event) => void; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:43](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L43) + +Returns a handler for toggling the visibility of all columns, meant to be bound to a `input[type=checkbox]` element. + +#### Returns + +```ts +(event): void; +``` + +##### Parameters + +###### event + +`unknown` + +##### Returns + +`void` + +*** + +### getVisibleFlatColumns() + +```ts +getVisibleFlatColumns: () => Column[]; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:47](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L47) + +Returns a flat array of columns that are visible, including parent columns. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getVisibleLeafColumns() + +```ts +getVisibleLeafColumns: () => Column[]; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:51](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L51) + +Returns a flat array of leaf-node columns that are visible. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### resetColumnVisibility() + +```ts +resetColumnVisibility: (defaultState?) => void; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:55](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L55) + +Resets the column visibility state to the initial state. If `defaultState` is provided, the state will be reset to `{}` + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### setColumnVisibility() + +```ts +setColumnVisibility: (updater) => void; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:59](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L59) + +Sets or updates the `state.columnVisibility` state. + +#### Parameters + +##### updater + +[`Updater`](../type-aliases/Updater.md)\<[`ColumnVisibilityState`](../type-aliases/ColumnVisibilityState.md)\> + +#### Returns + +`void` + +*** + +### toggleAllColumnsVisible() + +```ts +toggleAllColumnsVisible: (value?) => void; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:63](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L63) + +Toggles the visibility of all columns. + +#### Parameters + +##### value? + +`boolean` + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Table_Columns.md b/docs/reference/interfaces/Table_Columns.md new file mode 100644 index 0000000000..e337a16245 --- /dev/null +++ b/docs/reference/interfaces/Table_Columns.md @@ -0,0 +1,123 @@ +--- +id: Table_Columns +title: Table_Columns +--- + +# Interface: Table\_Columns\ + +Defined in: [core/columns/coreColumnsFeature.types.ts:75](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L75) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getAllColumns() + +```ts +getAllColumns: () => Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:90](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L90) + +Returns all columns in the table in their normalized and nested hierarchy. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getAllFlatColumns() + +```ts +getAllFlatColumns: () => Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:94](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L94) + +Returns all columns in the table flattened to a single level. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getAllFlatColumnsById() + +```ts +getAllFlatColumnsById: () => Record>; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:82](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L82) + +Returns a map of all flat columns by their ID. + +#### Returns + +`Record`\<`string`, [`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>\> + +*** + +### getAllLeafColumns() + +```ts +getAllLeafColumns: () => Column[]; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:98](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L98) + +Returns all leaf-node columns in the table flattened to a single level. This does not include parent columns. + +#### Returns + +[`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getColumn() + +```ts +getColumn: (columnId) => + | Column + | undefined; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:102](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L102) + +Returns a single column by its ID. + +#### Parameters + +##### columnId + +`string` + +#### Returns + + \| [`Column`](../type-aliases/Column.md)\<`TFeatures`, `TData`, `unknown`\> + \| `undefined` + +*** + +### getDefaultColumnDef() + +```ts +getDefaultColumnDef: () => Partial>; +``` + +Defined in: [core/columns/coreColumnsFeature.types.ts:86](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.types.ts#L86) + +Returns the default column options to use for all column defs supplied to the table. + +#### Returns + +`Partial`\<[`ColumnDef`](../type-aliases/ColumnDef.md)\<`TFeatures`, `TData`, `unknown`\>\> diff --git a/docs/reference/interfaces/Table_CoreProperties.md b/docs/reference/interfaces/Table_CoreProperties.md new file mode 100644 index 0000000000..7da3c32ffd --- /dev/null +++ b/docs/reference/interfaces/Table_CoreProperties.md @@ -0,0 +1,154 @@ +--- +id: Table_CoreProperties +title: Table_CoreProperties +--- + +# Interface: Table\_CoreProperties\ + +Defined in: [core/table/coreTablesFeature.types.ts:61](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L61) + +## Extended by + +- [`Table_Table`](Table_Table.md) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### \_cellPrototype? + +```ts +optional _cellPrototype: object; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:72](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L72) + +Prototype cache for Cell objects - shared by all cells in this table + +*** + +### \_columnPrototype? + +```ts +optional _columnPrototype: object; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:76](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L76) + +Prototype cache for Column objects - shared by all columns in this table + +*** + +### \_features + +```ts +_features: Partial & TFeatures; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:68](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L68) + +The features that are enabled for the table. + +*** + +### \_headerPrototype? + +```ts +optional _headerPrototype: object; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:80](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L80) + +Prototype cache for Header objects - shared by all headers in this table + +*** + +### \_rowModelFns + +```ts +_rowModelFns: RowModelFns; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:84](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L84) + +The row model processing functions that are used to process the data by features. + +*** + +### \_rowModels + +```ts +_rowModels: CachedRowModels; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:88](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L88) + +The row models that are enabled for the table. + +*** + +### \_rowPrototype? + +```ts +optional _rowPrototype: object; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:92](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L92) + +Prototype cache for Row objects - shared by all rows in this table + +*** + +### baseStore + +```ts +baseStore: Store>; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:96](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L96) + +The base store for the table. This can be used to write to the table state. + +*** + +### initialState + +```ts +initialState: TableState; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:100](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L100) + +This is the resolved initial state of the table. + +*** + +### options + +```ts +options: TableOptions; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:104](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L104) + +A read-only reference to the table's current options. + +*** + +### store + +```ts +store: ReadonlyStore>; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:108](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L108) + +Where the table state is stored. diff --git a/docs/reference/interfaces/Table_GlobalFiltering.md b/docs/reference/interfaces/Table_GlobalFiltering.md new file mode 100644 index 0000000000..3b31be486c --- /dev/null +++ b/docs/reference/interfaces/Table_GlobalFiltering.md @@ -0,0 +1,94 @@ +--- +id: Table_GlobalFiltering +title: Table_GlobalFiltering +--- + +# Interface: Table\_GlobalFiltering\ + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:64](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L64) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getGlobalAutoFilterFn() + +```ts +getGlobalAutoFilterFn: () => FilterFn | undefined; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:71](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L71) + +Currently, this function returns the built-in `includesString` filter function. In future releases, it may return more dynamic filter functions based on the nature of the data provided. + +#### Returns + +[`FilterFn`](FilterFn.md)\<`TFeatures`, `TData`\> \| `undefined` + +*** + +### getGlobalFilterFn() + +```ts +getGlobalFilterFn: () => FilterFn | undefined; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:75](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L75) + +Returns the filter function (either user-defined or automatic, depending on configuration) for the global filter. + +#### Returns + +[`FilterFn`](FilterFn.md)\<`TFeatures`, `TData`\> \| `undefined` + +*** + +### resetGlobalFilter() + +```ts +resetGlobalFilter: (defaultState?) => void; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:79](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L79) + +Resets the **globalFilter** state to `initialState.globalFilter`, or `true` can be passed to force a default blank state reset to `undefined`. + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### setGlobalFilter() + +```ts +setGlobalFilter: (updater) => void; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.types.ts:83](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.types.ts#L83) + +Sets or updates the `state.globalFilter` state. + +#### Parameters + +##### updater + +`any` + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Table_Headers.md b/docs/reference/interfaces/Table_Headers.md new file mode 100644 index 0000000000..96cd15bf66 --- /dev/null +++ b/docs/reference/interfaces/Table_Headers.md @@ -0,0 +1,82 @@ +--- +id: Table_Headers +title: Table_Headers +--- + +# Interface: Table\_Headers\ + +Defined in: [core/headers/coreHeadersFeature.types.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L8) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getFlatHeaders() + +```ts +getFlatHeaders: () => Header[]; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L23) + +Returns headers for all columns in the table, including parent headers. + +#### Returns + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `unknown`\>[] + +*** + +### getFooterGroups() + +```ts +getFooterGroups: () => HeaderGroup[]; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:19](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L19) + +Returns the footer groups for the table. + +#### Returns + +[`HeaderGroup`](../type-aliases/HeaderGroup.md)\<`TFeatures`, `TData`\>[] + +*** + +### getHeaderGroups() + +```ts +getHeaderGroups: () => HeaderGroup[]; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L15) + +Returns all header groups for the table. + +#### Returns + +[`HeaderGroup`](../type-aliases/HeaderGroup.md)\<`TFeatures`, `TData`\>[] + +*** + +### getLeafHeaders() + +```ts +getLeafHeaders: () => Header[]; +``` + +Defined in: [core/headers/coreHeadersFeature.types.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.types.ts#L27) + +Returns headers for all leaf columns in the table, (not including parent headers). + +#### Returns + +[`Header`](../type-aliases/Header.md)\<`TFeatures`, `TData`, `unknown`\>[] diff --git a/docs/reference/interfaces/Table_Plugins.md b/docs/reference/interfaces/Table_Plugins.md new file mode 100644 index 0000000000..7bf41ce48f --- /dev/null +++ b/docs/reference/interfaces/Table_Plugins.md @@ -0,0 +1,21 @@ +--- +id: Table_Plugins +title: Table_Plugins +--- + +# Interface: Table\_Plugins\ + +Defined in: [types/Table.ts:32](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Table.ts#L32) + +Use this interface as a target for declaration merging to add your own plugin properties. +Note: This will affect the types of all tables in your project. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) diff --git a/docs/reference/interfaces/Table_RowExpanding.md b/docs/reference/interfaces/Table_RowExpanding.md new file mode 100644 index 0000000000..2f1f09dd02 --- /dev/null +++ b/docs/reference/interfaces/Table_RowExpanding.md @@ -0,0 +1,190 @@ +--- +id: Table_RowExpanding +title: Table_RowExpanding +--- + +# Interface: Table\_RowExpanding\ + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:71](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L71) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### autoResetExpanded() + +```ts +autoResetExpanded: () => void; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:75](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L75) + +#### Returns + +`void` + +*** + +### getCanSomeRowsExpand() + +```ts +getCanSomeRowsExpand: () => boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:79](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L79) + +Returns whether there are any rows that can be expanded. + +#### Returns + +`boolean` + +*** + +### getExpandedDepth() + +```ts +getExpandedDepth: () => number; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:83](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L83) + +Returns the maximum depth of the expanded rows. + +#### Returns + +`number` + +*** + +### getIsAllRowsExpanded() + +```ts +getIsAllRowsExpanded: () => boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:87](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L87) + +Returns whether all rows are currently expanded. + +#### Returns + +`boolean` + +*** + +### getIsSomeRowsExpanded() + +```ts +getIsSomeRowsExpanded: () => boolean; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:91](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L91) + +Returns whether there are any rows that are currently expanded. + +#### Returns + +`boolean` + +*** + +### getToggleAllRowsExpandedHandler() + +```ts +getToggleAllRowsExpandedHandler: () => (event) => void; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:95](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L95) + +Returns a handler that can be used to toggle the expanded state of all rows. This handler is meant to be used with an `input[type=checkbox]` element. + +#### Returns + +```ts +(event): void; +``` + +##### Parameters + +###### event + +`unknown` + +##### Returns + +`void` + +*** + +### resetExpanded() + +```ts +resetExpanded: (defaultState?) => void; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:99](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L99) + +Resets the expanded state of the table to the initial state. + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### setExpanded() + +```ts +setExpanded: (updater) => void; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:103](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L103) + +Updates the expanded state of the table via an update function or value. + +#### Parameters + +##### updater + +[`Updater`](../type-aliases/Updater.md)\<[`ExpandedState`](../type-aliases/ExpandedState.md)\> + +#### Returns + +`void` + +*** + +### toggleAllRowsExpanded() + +```ts +toggleAllRowsExpanded: (expanded?) => void; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:107](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L107) + +Toggles the expanded state for all rows. + +#### Parameters + +##### expanded? + +`boolean` + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Table_RowModels_Core.md b/docs/reference/interfaces/Table_RowModels_Core.md new file mode 100644 index 0000000000..acf2760368 --- /dev/null +++ b/docs/reference/interfaces/Table_RowModels_Core.md @@ -0,0 +1,50 @@ +--- +id: Table_RowModels_Core +title: Table_RowModels_Core +--- + +# Interface: Table\_RowModels\_Core\ + +Defined in: [core/row-models/coreRowModelsFeature.types.ts:44](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.types.ts#L44) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getCoreRowModel() + +```ts +getCoreRowModel: () => RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.types.ts:51](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.types.ts#L51) + +Returns the core row model before any processing has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### getRowModel() + +```ts +getRowModel: () => RowModel; +``` + +Defined in: [core/row-models/coreRowModelsFeature.types.ts:55](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.types.ts#L55) + +Returns the final model after all processing from other used features has been applied. This is the row model that is most commonly used for rendering. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/Table_RowModels_Expanded.md b/docs/reference/interfaces/Table_RowModels_Expanded.md new file mode 100644 index 0000000000..7772a76758 --- /dev/null +++ b/docs/reference/interfaces/Table_RowModels_Expanded.md @@ -0,0 +1,50 @@ +--- +id: Table_RowModels_Expanded +title: Table_RowModels_Expanded +--- + +# Interface: Table\_RowModels\_Expanded\ + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:110](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L110) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getExpandedRowModel() + +```ts +getExpandedRowModel: () => RowModel; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:117](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L117) + +Returns the row model after expansion has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### getPreExpandedRowModel() + +```ts +getPreExpandedRowModel: () => RowModel; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:121](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L121) + +Returns the row model before expansion has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/Table_RowModels_Faceted.md b/docs/reference/interfaces/Table_RowModels_Faceted.md new file mode 100644 index 0000000000..b376c6548b --- /dev/null +++ b/docs/reference/interfaces/Table_RowModels_Faceted.md @@ -0,0 +1,69 @@ +--- +id: Table_RowModels_Faceted +title: Table_RowModels_Faceted +--- + +# Interface: Table\_RowModels\_Faceted\ + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:24](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L24) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getFacetedMinMaxValues() + +```ts +getFacetedMinMaxValues: () => [number, number] | undefined; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:32](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L32) + +A function that **computes and returns** a min/max tuple derived from `column.getFacetedRowModel`. Useful for displaying faceted result values. +> ⚠️ Requires that you pass a valid `getFacetedMinMaxValues` function to `options.getFacetedMinMaxValues`. A default implementation is provided via the exported `getFacetedMinMaxValues` function. + +#### Returns + +\[`number`, `number`\] \| `undefined` + +*** + +### getFacetedRowModel() + +```ts +getFacetedRowModel: () => RowModel; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:37](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L37) + +Returns the row model with all other column filters applied, excluding its own filter. Useful for displaying faceted result counts. +> ⚠️ Requires that you pass a valid `getFacetedRowModel` function to `options.facetedRowModel`. A default implementation is provided via the exported `getFacetedRowModel` function. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### getFacetedUniqueValues() + +```ts +getFacetedUniqueValues: () => Map; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.types.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.types.ts#L42) + +A function that **computes and returns** a `Map` of unique values and their occurrences derived from `column.getFacetedRowModel`. Useful for displaying faceted result values. +> ⚠️ Requires that you pass a valid `getFacetedUniqueValues` function to `options.getFacetedUniqueValues`. A default implementation is provided via the exported `getFacetedUniqueValues` function. + +#### Returns + +`Map`\<`any`, `number`\> diff --git a/docs/reference/interfaces/Table_RowModels_Filtered.md b/docs/reference/interfaces/Table_RowModels_Filtered.md new file mode 100644 index 0000000000..2f4d312791 --- /dev/null +++ b/docs/reference/interfaces/Table_RowModels_Filtered.md @@ -0,0 +1,50 @@ +--- +id: Table_RowModels_Filtered +title: Table_RowModels_Filtered +--- + +# Interface: Table\_RowModels\_Filtered\ + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:186](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L186) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getFilteredRowModel() + +```ts +getFilteredRowModel: () => RowModel; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:193](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L193) + +Returns the row model for the table after **column** filtering has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### getPreFilteredRowModel() + +```ts +getPreFilteredRowModel: () => RowModel; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:197](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L197) + +Returns the row model for the table before any **column** filtering has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/Table_RowModels_Grouped.md b/docs/reference/interfaces/Table_RowModels_Grouped.md new file mode 100644 index 0000000000..3a70c84409 --- /dev/null +++ b/docs/reference/interfaces/Table_RowModels_Grouped.md @@ -0,0 +1,50 @@ +--- +id: Table_RowModels_Grouped +title: Table_RowModels_Grouped +--- + +# Interface: Table\_RowModels\_Grouped\ + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:187](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L187) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getGroupedRowModel() + +```ts +getGroupedRowModel: () => RowModel; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:194](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L194) + +Returns the row model for the table after grouping has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### getPreGroupedRowModel() + +```ts +getPreGroupedRowModel: () => RowModel; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:198](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L198) + +Returns the row model for the table before any grouping has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/Table_RowModels_Paginated.md b/docs/reference/interfaces/Table_RowModels_Paginated.md new file mode 100644 index 0000000000..738a2a81d5 --- /dev/null +++ b/docs/reference/interfaces/Table_RowModels_Paginated.md @@ -0,0 +1,50 @@ +--- +id: Table_RowModels_Paginated +title: Table_RowModels_Paginated +--- + +# Interface: Table\_RowModels\_Paginated\ + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:109](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L109) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getPaginatedRowModel() + +```ts +getPaginatedRowModel: () => RowModel; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:116](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L116) + +Returns the row model for the table after pagination has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### getPrePaginatedRowModel() + +```ts +getPrePaginatedRowModel: () => RowModel; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:120](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L120) + +Returns the row model for the table before any pagination has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/Table_RowModels_Sorted.md b/docs/reference/interfaces/Table_RowModels_Sorted.md new file mode 100644 index 0000000000..f8727300b6 --- /dev/null +++ b/docs/reference/interfaces/Table_RowModels_Sorted.md @@ -0,0 +1,50 @@ +--- +id: Table_RowModels_Sorted +title: Table_RowModels_Sorted +--- + +# Interface: Table\_RowModels\_Sorted\ + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:198](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L198) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getPreSortedRowModel() + +```ts +getPreSortedRowModel: () => RowModel; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:205](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L205) + +Returns the row model for the table before any sorting has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### getSortedRowModel() + +```ts +getSortedRowModel: () => RowModel; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:209](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L209) + +Returns the row model for the table after sorting has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/interfaces/Table_RowPagination.md b/docs/reference/interfaces/Table_RowPagination.md new file mode 100644 index 0000000000..4336d44e22 --- /dev/null +++ b/docs/reference/interfaces/Table_RowPagination.md @@ -0,0 +1,308 @@ +--- +id: Table_RowPagination +title: Table_RowPagination +--- + +# Interface: Table\_RowPagination\ + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L42) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### \_autoResetPageIndex() + +```ts +_autoResetPageIndex: () => void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:46](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L46) + +#### Returns + +`void` + +*** + +### firstPage() + +```ts +firstPage: () => void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:78](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L78) + +Sets the page index to `0`. + +#### Returns + +`void` + +*** + +### getCanNextPage() + +```ts +getCanNextPage: () => boolean; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:50](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L50) + +Returns whether the table can go to the next page. + +#### Returns + +`boolean` + +*** + +### getCanPreviousPage() + +```ts +getCanPreviousPage: () => boolean; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:54](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L54) + +Returns whether the table can go to the previous page. + +#### Returns + +`boolean` + +*** + +### getPageCount() + +```ts +getPageCount: () => number; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:58](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L58) + +Returns the page count. If manually paginating or controlling the pagination state, this will come directly from the `options.pageCount` table option, otherwise it will be calculated from the table data using the total row count and current page size. + +#### Returns + +`number` + +*** + +### getPageOptions() + +```ts +getPageOptions: () => number[]; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:66](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L66) + +Returns an array of page options (zero-index-based) for the current page size. + +#### Returns + +`number`[] + +*** + +### getRowCount() + +```ts +getRowCount: () => number; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:62](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L62) + +Returns the row count. If manually paginating or controlling the pagination state, this will come directly from the `options.rowCount` table option, otherwise it will be calculated from the table data. + +#### Returns + +`number` + +*** + +### lastPage() + +```ts +lastPage: () => void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:82](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L82) + +Sets the page index to the last page. + +#### Returns + +`void` + +*** + +### nextPage() + +```ts +nextPage: () => void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:70](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L70) + +Increments the page index by one, if possible. + +#### Returns + +`void` + +*** + +### previousPage() + +```ts +previousPage: () => void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:74](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L74) + +Decrements the page index by one, if possible. + +#### Returns + +`void` + +*** + +### resetPageIndex() + +```ts +resetPageIndex: (defaultState?) => void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:86](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L86) + +Resets the page index to its initial state. If `defaultState` is `true`, the page index will be reset to `0` regardless of initial state. + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### resetPageSize() + +```ts +resetPageSize: (defaultState?) => void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:90](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L90) + +Resets the page size to its initial state. If `defaultState` is `true`, the page size will be reset to `10` regardless of initial state. + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### resetPagination() + +```ts +resetPagination: (defaultState?) => void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:94](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L94) + +Resets the **pagination** state to `initialState.pagination`, or `true` can be passed to force a default blank state reset to `[]`. + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### setPageIndex() + +```ts +setPageIndex: (updater) => void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:98](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L98) + +Updates the page index using the provided function or value in the `state.pagination.pageIndex` state. + +#### Parameters + +##### updater + +[`Updater`](../type-aliases/Updater.md)\<`number`\> + +#### Returns + +`void` + +*** + +### setPageSize() + +```ts +setPageSize: (updater) => void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:102](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L102) + +Updates the page size using the provided function or value in the `state.pagination.pageSize` state. + +#### Parameters + +##### updater + +[`Updater`](../type-aliases/Updater.md)\<`number`\> + +#### Returns + +`void` + +*** + +### setPagination() + +```ts +setPagination: (updater) => void; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.types.ts:106](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.types.ts#L106) + +Sets or updates the `state.pagination` state. + +#### Parameters + +##### updater + +[`Updater`](../type-aliases/Updater.md)\<[`PaginationState`](PaginationState.md)\> + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Table_RowPinning.md b/docs/reference/interfaces/Table_RowPinning.md new file mode 100644 index 0000000000..b8907f46c4 --- /dev/null +++ b/docs/reference/interfaces/Table_RowPinning.md @@ -0,0 +1,132 @@ +--- +id: Table_RowPinning +title: Table_RowPinning +--- + +# Interface: Table\_RowPinning\ + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:61](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L61) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getBottomRows() + +```ts +getBottomRows: () => Row[]; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:68](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L68) + +Returns all bottom pinned rows. + +#### Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] + +*** + +### getCenterRows() + +```ts +getCenterRows: () => Row[]; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:72](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L72) + +Returns all rows that are not pinned to the top or bottom. + +#### Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] + +*** + +### getIsSomeRowsPinned() + +```ts +getIsSomeRowsPinned: (position?) => boolean; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:76](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L76) + +Returns whether or not any rows are pinned. Optionally specify to only check for pinned rows in either the `top` or `bottom` position. + +#### Parameters + +##### position? + +[`RowPinningPosition`](../type-aliases/RowPinningPosition.md) + +#### Returns + +`boolean` + +*** + +### getTopRows() + +```ts +getTopRows: () => Row[]; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:80](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L80) + +Returns all top pinned rows. + +#### Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\>[] + +*** + +### resetRowPinning() + +```ts +resetRowPinning: (defaultState?) => void; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:84](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L84) + +Resets the **rowPinning** state to `initialState.rowPinning`, or `true` can be passed to force a default blank state reset to `{ top: [], bottom: [], }`. + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### setRowPinning() + +```ts +setRowPinning: (updater) => void; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:88](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L88) + +Sets or updates the `state.rowPinning` state. + +#### Parameters + +##### updater + +[`Updater`](../type-aliases/Updater.md)\<[`RowPinningState`](RowPinningState.md)\> + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Table_RowSelection.md b/docs/reference/interfaces/Table_RowSelection.md new file mode 100644 index 0000000000..fdb97bb530 --- /dev/null +++ b/docs/reference/interfaces/Table_RowSelection.md @@ -0,0 +1,290 @@ +--- +id: Table_RowSelection +title: Table_RowSelection +--- + +# Interface: Table\_RowSelection\ + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:83](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L83) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getFilteredSelectedRowModel() + +```ts +getFilteredSelectedRowModel: () => RowModel; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:90](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L90) + +Returns the row model of all rows that are selected after filtering has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### getGroupedSelectedRowModel() + +```ts +getGroupedSelectedRowModel: () => RowModel; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:94](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L94) + +Returns the row model of all rows that are selected after grouping has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### getIsAllPageRowsSelected() + +```ts +getIsAllPageRowsSelected: () => boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:98](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L98) + +Returns whether or not all rows on the current page are selected. + +#### Returns + +`boolean` + +*** + +### getIsAllRowsSelected() + +```ts +getIsAllRowsSelected: () => boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:102](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L102) + +Returns whether or not all rows in the table are selected. + +#### Returns + +`boolean` + +*** + +### getIsSomePageRowsSelected() + +```ts +getIsSomePageRowsSelected: () => boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:106](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L106) + +Returns whether or not any rows on the current page are selected. + +#### Returns + +`boolean` + +*** + +### getIsSomeRowsSelected() + +```ts +getIsSomeRowsSelected: () => boolean; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:110](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L110) + +Returns whether or not any rows in the table are selected. + +#### Returns + +`boolean` + +*** + +### getPreSelectedRowModel() + +```ts +getPreSelectedRowModel: () => RowModel; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:114](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L114) + +Returns the core row model of all rows before row selection has been applied. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### getSelectedRowModel() + +```ts +getSelectedRowModel: () => RowModel; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:118](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L118) + +Returns the row model of all rows that are selected. + +#### Returns + +[`RowModel`](RowModel.md)\<`TFeatures`, `TData`\> + +*** + +### getToggleAllPageRowsSelectedHandler() + +```ts +getToggleAllPageRowsSelectedHandler: () => (event) => void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:122](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L122) + +Returns a handler that can be used to toggle all rows on the current page. + +#### Returns + +```ts +(event): void; +``` + +##### Parameters + +###### event + +`unknown` + +##### Returns + +`void` + +*** + +### getToggleAllRowsSelectedHandler() + +```ts +getToggleAllRowsSelectedHandler: () => (event) => void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:126](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L126) + +Returns a handler that can be used to toggle all rows in the table. + +#### Returns + +```ts +(event): void; +``` + +##### Parameters + +###### event + +`unknown` + +##### Returns + +`void` + +*** + +### resetRowSelection() + +```ts +resetRowSelection: (defaultState?) => void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:130](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L130) + +Resets the **rowSelection** state to the `initialState.rowSelection`, or `true` can be passed to force a default blank state reset to `{}`. + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### setRowSelection() + +```ts +setRowSelection: (updater) => void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:134](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L134) + +Sets or updates the `state.rowSelection` state. + +#### Parameters + +##### updater + +[`Updater`](../type-aliases/Updater.md)\<[`RowSelectionState`](../type-aliases/RowSelectionState.md)\> + +#### Returns + +`void` + +*** + +### toggleAllPageRowsSelected() + +```ts +toggleAllPageRowsSelected: (value?) => void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:138](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L138) + +Selects/deselects all rows on the current page. + +#### Parameters + +##### value? + +`boolean` + +#### Returns + +`void` + +*** + +### toggleAllRowsSelected() + +```ts +toggleAllRowsSelected: (value?) => void; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:142](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L142) + +Selects/deselects all rows in the table. + +#### Parameters + +##### value? + +`boolean` + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Table_RowSorting.md b/docs/reference/interfaces/Table_RowSorting.md new file mode 100644 index 0000000000..4bc09bafe4 --- /dev/null +++ b/docs/reference/interfaces/Table_RowSorting.md @@ -0,0 +1,62 @@ +--- +id: Table_RowSorting +title: Table_RowSorting +--- + +# Interface: Table\_RowSorting\ + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:184](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L184) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### resetSorting() + +```ts +resetSorting: (defaultState?) => void; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:191](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L191) + +Resets the **sorting** state to `initialState.sorting`, or `true` can be passed to force a default blank state reset to `[]`. + +#### Parameters + +##### defaultState? + +`boolean` + +#### Returns + +`void` + +*** + +### setSorting() + +```ts +setSorting: (updater) => void; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:195](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L195) + +Sets or updates the `state.sorting` state. + +#### Parameters + +##### updater + +[`Updater`](../type-aliases/Updater.md)\<[`SortingState`](../type-aliases/SortingState.md)\> + +#### Returns + +`void` diff --git a/docs/reference/interfaces/Table_Rows.md b/docs/reference/interfaces/Table_Rows.md new file mode 100644 index 0000000000..94dddefb98 --- /dev/null +++ b/docs/reference/interfaces/Table_Rows.md @@ -0,0 +1,72 @@ +--- +id: Table_Rows +title: Table_Rows +--- + +# Interface: Table\_Rows\ + +Defined in: [core/rows/coreRowsFeature.types.ts:105](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L105) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### getRow() + +```ts +getRow: (id, searchAll?) => Row; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:113](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L113) + +Returns the row with the given ID. + +#### Parameters + +##### id + +`string` + +##### searchAll? + +`boolean` + +#### Returns + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +*** + +### getRowId() + +```ts +getRowId: (_, index, parent?) => string; +``` + +Defined in: [core/rows/coreRowsFeature.types.ts:109](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.types.ts#L109) + +#### Parameters + +##### \_ + +`TData` + +##### index + +`number` + +##### parent? + +[`Row`](../type-aliases/Row.md)\<`TFeatures`, `TData`\> + +#### Returns + +`string` diff --git a/docs/reference/interfaces/Table_Table.md b/docs/reference/interfaces/Table_Table.md new file mode 100644 index 0000000000..419b93a808 --- /dev/null +++ b/docs/reference/interfaces/Table_Table.md @@ -0,0 +1,236 @@ +--- +id: Table_Table +title: Table_Table +--- + +# Interface: Table\_Table\ + +Defined in: [core/table/coreTablesFeature.types.ts:111](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L111) + +## Extends + +- [`Table_CoreProperties`](Table_CoreProperties.md)\<`TFeatures`, `TData`\> + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](../type-aliases/RowData.md) + +## Properties + +### \_cellPrototype? + +```ts +optional _cellPrototype: object; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:72](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L72) + +Prototype cache for Cell objects - shared by all cells in this table + +#### Inherited from + +[`Table_CoreProperties`](Table_CoreProperties.md).[`_cellPrototype`](Table_CoreProperties.md#_cellprototype) + +*** + +### \_columnPrototype? + +```ts +optional _columnPrototype: object; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:76](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L76) + +Prototype cache for Column objects - shared by all columns in this table + +#### Inherited from + +[`Table_CoreProperties`](Table_CoreProperties.md).[`_columnPrototype`](Table_CoreProperties.md#_columnprototype) + +*** + +### \_features + +```ts +_features: Partial & TFeatures; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:68](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L68) + +The features that are enabled for the table. + +#### Inherited from + +[`Table_CoreProperties`](Table_CoreProperties.md).[`_features`](Table_CoreProperties.md#_features) + +*** + +### \_headerPrototype? + +```ts +optional _headerPrototype: object; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:80](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L80) + +Prototype cache for Header objects - shared by all headers in this table + +#### Inherited from + +[`Table_CoreProperties`](Table_CoreProperties.md).[`_headerPrototype`](Table_CoreProperties.md#_headerprototype) + +*** + +### \_rowModelFns + +```ts +_rowModelFns: RowModelFns; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:84](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L84) + +The row model processing functions that are used to process the data by features. + +#### Inherited from + +[`Table_CoreProperties`](Table_CoreProperties.md).[`_rowModelFns`](Table_CoreProperties.md#_rowmodelfns) + +*** + +### \_rowModels + +```ts +_rowModels: CachedRowModels; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:88](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L88) + +The row models that are enabled for the table. + +#### Inherited from + +[`Table_CoreProperties`](Table_CoreProperties.md).[`_rowModels`](Table_CoreProperties.md#_rowmodels) + +*** + +### \_rowPrototype? + +```ts +optional _rowPrototype: object; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:92](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L92) + +Prototype cache for Row objects - shared by all rows in this table + +#### Inherited from + +[`Table_CoreProperties`](Table_CoreProperties.md).[`_rowPrototype`](Table_CoreProperties.md#_rowprototype) + +*** + +### baseStore + +```ts +baseStore: Store>; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:96](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L96) + +The base store for the table. This can be used to write to the table state. + +#### Inherited from + +[`Table_CoreProperties`](Table_CoreProperties.md).[`baseStore`](Table_CoreProperties.md#basestore) + +*** + +### initialState + +```ts +initialState: TableState; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:100](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L100) + +This is the resolved initial state of the table. + +#### Inherited from + +[`Table_CoreProperties`](Table_CoreProperties.md).[`initialState`](Table_CoreProperties.md#initialstate) + +*** + +### options + +```ts +options: TableOptions; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:104](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L104) + +A read-only reference to the table's current options. + +#### Inherited from + +[`Table_CoreProperties`](Table_CoreProperties.md).[`options`](Table_CoreProperties.md#options) + +*** + +### reset() + +```ts +reset: () => void; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:118](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L118) + +Call this function to reset the table state to the initial state. + +#### Returns + +`void` + +*** + +### setOptions() + +```ts +setOptions: (newOptions) => void; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:122](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L122) + +This function can be used to update the table options. + +#### Parameters + +##### newOptions + +[`Updater`](../type-aliases/Updater.md)\<[`TableOptions`](../type-aliases/TableOptions.md)\<`TFeatures`, `TData`\>\> + +#### Returns + +`void` + +*** + +### store + +```ts +store: ReadonlyStore>; +``` + +Defined in: [core/table/coreTablesFeature.types.ts:108](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.types.ts#L108) + +Where the table state is stored. + +#### Inherited from + +[`Table_CoreProperties`](Table_CoreProperties.md).[`store`](Table_CoreProperties.md#store) diff --git a/docs/reference/interfaces/columnResizingState.md b/docs/reference/interfaces/columnResizingState.md new file mode 100644 index 0000000000..b38d9badf9 --- /dev/null +++ b/docs/reference/interfaces/columnResizingState.md @@ -0,0 +1,68 @@ +--- +id: columnResizingState +title: columnResizingState +--- + +# Interface: columnResizingState + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:7](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L7) + +## Properties + +### columnSizingStart + +```ts +columnSizingStart: [string, number][]; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L8) + +*** + +### deltaOffset + +```ts +deltaOffset: number | null; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:9](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L9) + +*** + +### deltaPercentage + +```ts +deltaPercentage: number | null; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L10) + +*** + +### isResizingColumn + +```ts +isResizingColumn: string | false; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L11) + +*** + +### startOffset + +```ts +startOffset: number | null; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L12) + +*** + +### startSize + +```ts +startSize: number | null; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:13](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L13) diff --git a/docs/reference/type-aliases/APIObject.md b/docs/reference/type-aliases/APIObject.md new file mode 100644 index 0000000000..937884aa0e --- /dev/null +++ b/docs/reference/type-aliases/APIObject.md @@ -0,0 +1,22 @@ +--- +id: APIObject +title: APIObject +--- + +# Type Alias: APIObject\ + +```ts +type APIObject = Record>; +``` + +Defined in: [utils.ts:272](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L272) + +## Type Parameters + +### TDeps + +`TDeps` *extends* `ReadonlyArray`\<`any`\> + +### TDepArgs + +`TDepArgs` diff --git a/docs/reference/type-aliases/AccessorColumnDef.md b/docs/reference/type-aliases/AccessorColumnDef.md new file mode 100644 index 0000000000..2aef75707b --- /dev/null +++ b/docs/reference/type-aliases/AccessorColumnDef.md @@ -0,0 +1,28 @@ +--- +id: AccessorColumnDef +title: AccessorColumnDef +--- + +# Type Alias: AccessorColumnDef\ + +```ts +type AccessorColumnDef = + | AccessorKeyColumnDef +| AccessorFnColumnDef; +``` + +Defined in: [types/ColumnDef.ts:194](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L194) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/AccessorFn.md b/docs/reference/type-aliases/AccessorFn.md new file mode 100644 index 0000000000..c66ac0af96 --- /dev/null +++ b/docs/reference/type-aliases/AccessorFn.md @@ -0,0 +1,36 @@ +--- +id: AccessorFn +title: AccessorFn +--- + +# Type Alias: AccessorFn()\ + +```ts +type AccessorFn = (originalRow, index) => TValue; +``` + +Defined in: [types/ColumnDef.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L30) + +## Type Parameters + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) + +## Parameters + +### originalRow + +`TData` + +### index + +`number` + +## Returns + +`TValue` diff --git a/docs/reference/type-aliases/AccessorFnColumnDef.md b/docs/reference/type-aliases/AccessorFnColumnDef.md new file mode 100644 index 0000000000..bb77da4e78 --- /dev/null +++ b/docs/reference/type-aliases/AccessorFnColumnDef.md @@ -0,0 +1,26 @@ +--- +id: AccessorFnColumnDef +title: AccessorFnColumnDef +--- + +# Type Alias: AccessorFnColumnDef\ + +```ts +type AccessorFnColumnDef = AccessorFnColumnDefBase & ColumnIdentifiers; +``` + +Defined in: [types/ColumnDef.ts:171](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L171) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/AccessorFnColumnDefBase.md b/docs/reference/type-aliases/AccessorFnColumnDefBase.md new file mode 100644 index 0000000000..0949ba3710 --- /dev/null +++ b/docs/reference/type-aliases/AccessorFnColumnDefBase.md @@ -0,0 +1,34 @@ +--- +id: AccessorFnColumnDefBase +title: AccessorFnColumnDefBase +--- + +# Type Alias: AccessorFnColumnDefBase\ + +```ts +type AccessorFnColumnDefBase = ColumnDefBase & object; +``` + +Defined in: [types/ColumnDef.ts:163](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L163) + +## Type Declaration + +### accessorFn + +```ts +accessorFn: AccessorFn; +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/AccessorKeyColumnDef.md b/docs/reference/type-aliases/AccessorKeyColumnDef.md new file mode 100644 index 0000000000..c60f4368cd --- /dev/null +++ b/docs/reference/type-aliases/AccessorKeyColumnDef.md @@ -0,0 +1,26 @@ +--- +id: AccessorKeyColumnDef +title: AccessorKeyColumnDef +--- + +# Type Alias: AccessorKeyColumnDef\ + +```ts +type AccessorKeyColumnDef = AccessorKeyColumnDefBase & Partial>; +``` + +Defined in: [types/ColumnDef.ts:187](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L187) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/AccessorKeyColumnDefBase.md b/docs/reference/type-aliases/AccessorKeyColumnDefBase.md new file mode 100644 index 0000000000..8a180c439f --- /dev/null +++ b/docs/reference/type-aliases/AccessorKeyColumnDefBase.md @@ -0,0 +1,40 @@ +--- +id: AccessorKeyColumnDefBase +title: AccessorKeyColumnDefBase +--- + +# Type Alias: AccessorKeyColumnDefBase\ + +```ts +type AccessorKeyColumnDefBase = ColumnDefBase & object; +``` + +Defined in: [types/ColumnDef.ts:178](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L178) + +## Type Declaration + +### accessorKey + +```ts +accessorKey: string & object | keyof TData; +``` + +### id? + +```ts +optional id: string; +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/AggregationFn.md b/docs/reference/type-aliases/AggregationFn.md new file mode 100644 index 0000000000..4b6026e99a --- /dev/null +++ b/docs/reference/type-aliases/AggregationFn.md @@ -0,0 +1,40 @@ +--- +id: AggregationFn +title: AggregationFn +--- + +# Type Alias: AggregationFn()\ + +```ts +type AggregationFn = (columnId, leafRows, childRows) => any; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:30](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L30) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +## Parameters + +### columnId + +`string` + +### leafRows + +[`Row`](Row.md)\<`TFeatures`, `TData`\>[] + +### childRows + +[`Row`](Row.md)\<`TFeatures`, `TData`\>[] + +## Returns + +`any` diff --git a/docs/reference/type-aliases/AggregationFnOption.md b/docs/reference/type-aliases/AggregationFnOption.md new file mode 100644 index 0000000000..e769ff8947 --- /dev/null +++ b/docs/reference/type-aliases/AggregationFnOption.md @@ -0,0 +1,26 @@ +--- +id: AggregationFnOption +title: AggregationFnOption +--- + +# Type Alias: AggregationFnOption\ + +```ts +type AggregationFnOption = + | "auto" + | keyof AggregationFns + | BuiltInAggregationFn +| AggregationFn; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:44](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L44) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/AssignCellPrototype.md b/docs/reference/type-aliases/AssignCellPrototype.md new file mode 100644 index 0000000000..7a556f6829 --- /dev/null +++ b/docs/reference/type-aliases/AssignCellPrototype.md @@ -0,0 +1,42 @@ +--- +id: AssignCellPrototype +title: AssignCellPrototype +--- + +# Type Alias: AssignCellPrototype()\ + +```ts +type AssignCellPrototype = (prototype, table) => void; +``` + +Defined in: [types/TableFeatures.ts:77](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L77) + +## Type Parameters + +### TConstructors + +`TConstructors` *extends* `FeatureConstructors` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +## Parameters + +### prototype + +`Record`\<`string`, `any`\> + +### table + +[`Table_Internal`](Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`void` diff --git a/docs/reference/type-aliases/AssignColumnPrototype.md b/docs/reference/type-aliases/AssignColumnPrototype.md new file mode 100644 index 0000000000..fbd1bcf59a --- /dev/null +++ b/docs/reference/type-aliases/AssignColumnPrototype.md @@ -0,0 +1,42 @@ +--- +id: AssignColumnPrototype +title: AssignColumnPrototype +--- + +# Type Alias: AssignColumnPrototype()\ + +```ts +type AssignColumnPrototype = (prototype, table) => void; +``` + +Defined in: [types/TableFeatures.ts:85](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L85) + +## Type Parameters + +### TConstructors + +`TConstructors` *extends* `FeatureConstructors` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +## Parameters + +### prototype + +`Record`\<`string`, `any`\> + +### table + +[`Table_Internal`](Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`void` diff --git a/docs/reference/type-aliases/AssignHeaderPrototype.md b/docs/reference/type-aliases/AssignHeaderPrototype.md new file mode 100644 index 0000000000..809e45096e --- /dev/null +++ b/docs/reference/type-aliases/AssignHeaderPrototype.md @@ -0,0 +1,42 @@ +--- +id: AssignHeaderPrototype +title: AssignHeaderPrototype +--- + +# Type Alias: AssignHeaderPrototype()\ + +```ts +type AssignHeaderPrototype = (prototype, table) => void; +``` + +Defined in: [types/TableFeatures.ts:93](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L93) + +## Type Parameters + +### TConstructors + +`TConstructors` *extends* `FeatureConstructors` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +## Parameters + +### prototype + +`Record`\<`string`, `any`\> + +### table + +[`Table_Internal`](Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`void` diff --git a/docs/reference/type-aliases/AssignRowPrototype.md b/docs/reference/type-aliases/AssignRowPrototype.md new file mode 100644 index 0000000000..7d3180f2a3 --- /dev/null +++ b/docs/reference/type-aliases/AssignRowPrototype.md @@ -0,0 +1,42 @@ +--- +id: AssignRowPrototype +title: AssignRowPrototype +--- + +# Type Alias: AssignRowPrototype()\ + +```ts +type AssignRowPrototype = (prototype, table) => void; +``` + +Defined in: [types/TableFeatures.ts:101](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L101) + +## Type Parameters + +### TConstructors + +`TConstructors` *extends* `FeatureConstructors` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +## Parameters + +### prototype + +`Record`\<`string`, `any`\> + +### table + +[`Table_Internal`](Table_Internal.md)\<`TFeatures`, `TData`\> + +## Returns + +`void` diff --git a/docs/reference/type-aliases/BuiltInAggregationFn.md b/docs/reference/type-aliases/BuiltInAggregationFn.md new file mode 100644 index 0000000000..154c0ecdc0 --- /dev/null +++ b/docs/reference/type-aliases/BuiltInAggregationFn.md @@ -0,0 +1,12 @@ +--- +id: BuiltInAggregationFn +title: BuiltInAggregationFn +--- + +# Type Alias: BuiltInAggregationFn + +```ts +type BuiltInAggregationFn = keyof typeof aggregationFns; +``` + +Defined in: [fns/aggregationFns.ts:220](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/aggregationFns.ts#L220) diff --git a/docs/reference/type-aliases/BuiltInFilterFn.md b/docs/reference/type-aliases/BuiltInFilterFn.md new file mode 100644 index 0000000000..fd771c36b3 --- /dev/null +++ b/docs/reference/type-aliases/BuiltInFilterFn.md @@ -0,0 +1,12 @@ +--- +id: BuiltInFilterFn +title: BuiltInFilterFn +--- + +# Type Alias: BuiltInFilterFn + +```ts +type BuiltInFilterFn = keyof typeof filterFns; +``` + +Defined in: [fns/filterFns.ts:373](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L373) diff --git a/docs/reference/type-aliases/BuiltInSortFn.md b/docs/reference/type-aliases/BuiltInSortFn.md new file mode 100644 index 0000000000..5ccf24d131 --- /dev/null +++ b/docs/reference/type-aliases/BuiltInSortFn.md @@ -0,0 +1,12 @@ +--- +id: BuiltInSortFn +title: BuiltInSortFn +--- + +# Type Alias: BuiltInSortFn + +```ts +type BuiltInSortFn = keyof typeof sortFns; +``` + +Defined in: [fns/sortFns.ts:173](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/sortFns.ts#L173) diff --git a/docs/reference/type-aliases/CachedRowModel_All.md b/docs/reference/type-aliases/CachedRowModel_All.md new file mode 100644 index 0000000000..7c88b96722 --- /dev/null +++ b/docs/reference/type-aliases/CachedRowModel_All.md @@ -0,0 +1,22 @@ +--- +id: CachedRowModel_All +title: CachedRowModel_All +--- + +# Type Alias: CachedRowModel\_All\ + +```ts +type CachedRowModel_All = Partial & CachedRowModel_Expanded & CachedRowModel_Faceted & CachedRowModel_Filtered & CachedRowModel_Grouped & CachedRowModel_Paginated & CachedRowModel_Sorted>; +``` + +Defined in: [types/RowModel.ts:126](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/RowModel.ts#L126) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) = `any` diff --git a/docs/reference/type-aliases/CachedRowModels.md b/docs/reference/type-aliases/CachedRowModels.md new file mode 100644 index 0000000000..346ef4da2f --- /dev/null +++ b/docs/reference/type-aliases/CachedRowModels.md @@ -0,0 +1,40 @@ +--- +id: CachedRowModels +title: CachedRowModels +--- + +# Type Alias: CachedRowModels\ + +```ts +type CachedRowModels = object & UnionToIntersection< + | "columnFacetingFeature" extends keyof TFeatures ? CachedRowModel_Faceted : never + | "columnFilteringFeature" extends keyof TFeatures ? CachedRowModel_Filtered : never + | "rowExpandingFeature" extends keyof TFeatures ? CachedRowModel_Expanded : never + | "columnGroupingFeature" extends keyof TFeatures ? CachedRowModel_Grouped : never + | "rowPaginationFeature" extends keyof TFeatures ? CachedRowModel_Paginated : never +| "rowSortingFeature" extends keyof TFeatures ? CachedRowModel_Sorted : never> & ExtractFeatureTypes<"CachedRowModel", TFeatures> & CachedRowModels_Plugins; +``` + +Defined in: [types/RowModel.ts:92](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/RowModel.ts#L92) + +## Type Declaration + +### CachedRowModel\_Core() + +```ts +CachedRowModel_Core: () => RowModel; +``` + +#### Returns + +[`RowModel`](../interfaces/RowModel.md)\<`TFeatures`, `TData`\> + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/Cell.md b/docs/reference/type-aliases/Cell.md new file mode 100644 index 0000000000..d502b45063 --- /dev/null +++ b/docs/reference/type-aliases/Cell.md @@ -0,0 +1,26 @@ +--- +id: Cell +title: Cell +--- + +# Type Alias: Cell\ + +```ts +type Cell = Cell_Cell & UnionToIntersection<"columnGroupingFeature" extends keyof TFeatures ? Cell_ColumnGrouping : never> & ExtractFeatureTypes<"Cell", TFeatures> & Cell_Plugins; +``` + +Defined in: [types/Cell.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Cell.ts#L22) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/CellData.md b/docs/reference/type-aliases/CellData.md new file mode 100644 index 0000000000..b87bbfc760 --- /dev/null +++ b/docs/reference/type-aliases/CellData.md @@ -0,0 +1,12 @@ +--- +id: CellData +title: CellData +--- + +# Type Alias: CellData + +```ts +type CellData = unknown; +``` + +Defined in: [types/type-utils.ts:7](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/type-utils.ts#L7) diff --git a/docs/reference/type-aliases/Column.md b/docs/reference/type-aliases/Column.md new file mode 100644 index 0000000000..37c74859af --- /dev/null +++ b/docs/reference/type-aliases/Column.md @@ -0,0 +1,36 @@ +--- +id: Column +title: Column +--- + +# Type Alias: Column\ + +```ts +type Column = Column_Core & UnionToIntersection< + | "columnFacetingFeature" extends keyof TFeatures ? Column_ColumnFaceting : never + | "columnFilteringFeature" extends keyof TFeatures ? Column_ColumnFiltering : never + | "columnGroupingFeature" extends keyof TFeatures ? Column_ColumnGrouping : never + | "columnOrderingFeature" extends keyof TFeatures ? Column_ColumnOrdering : never + | "columnPinningFeature" extends keyof TFeatures ? Column_ColumnPinning : never + | "columnResizingFeature" extends keyof TFeatures ? Column_ColumnResizing : never + | "columnSizingFeature" extends keyof TFeatures ? Column_ColumnSizing : never + | "columnVisibilityFeature" extends keyof TFeatures ? Column_ColumnVisibility : never + | "globalFilteringFeature" extends keyof TFeatures ? Column_GlobalFiltering : never +| "rowSortingFeature" extends keyof TFeatures ? Column_RowSorting : never> & ExtractFeatureTypes<"Column", TFeatures> & Column_Plugins; +``` + +Defined in: [types/Column.ts:32](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Column.ts#L32) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` = `unknown` diff --git a/docs/reference/type-aliases/ColumnDef.md b/docs/reference/type-aliases/ColumnDef.md new file mode 100644 index 0000000000..3afd463a1c --- /dev/null +++ b/docs/reference/type-aliases/ColumnDef.md @@ -0,0 +1,29 @@ +--- +id: ColumnDef +title: ColumnDef +--- + +# Type Alias: ColumnDef\ + +```ts +type ColumnDef = + | DisplayColumnDef + | GroupColumnDef +| AccessorColumnDef; +``` + +Defined in: [types/ColumnDef.ts:202](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L202) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/ColumnDefBase.md b/docs/reference/type-aliases/ColumnDefBase.md new file mode 100644 index 0000000000..1c291b5ff8 --- /dev/null +++ b/docs/reference/type-aliases/ColumnDefBase.md @@ -0,0 +1,34 @@ +--- +id: ColumnDefBase +title: ColumnDefBase +--- + +# Type Alias: ColumnDefBase\ + +```ts +type ColumnDefBase = ColumnDefBase_Core & UnionToIntersection< + | "columnVisibilityFeature" extends keyof TFeatures ? ColumnDef_ColumnVisibility : never + | "columnPinningFeature" extends keyof TFeatures ? ColumnDef_ColumnPinning : never + | "columnFilteringFeature" extends keyof TFeatures ? ColumnDef_ColumnFiltering : never + | "globalFilteringFeature" extends keyof TFeatures ? ColumnDef_GlobalFiltering : never + | "rowSortingFeature" extends keyof TFeatures ? ColumnDef_RowSorting : never + | "columnGroupingFeature" extends keyof TFeatures ? ColumnDef_ColumnGrouping : never + | "columnSizingFeature" extends keyof TFeatures ? ColumnDef_ColumnSizing : never +| "columnResizingFeature" extends keyof TFeatures ? ColumnDef_ColumnResizing : never> & ExtractFeatureTypes<"ColumnDef", TFeatures> & ColumnDef_Plugins; +``` + +Defined in: [types/ColumnDef.ts:75](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L75) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/ColumnDefBase_All.md b/docs/reference/type-aliases/ColumnDefBase_All.md new file mode 100644 index 0000000000..b1428ac707 --- /dev/null +++ b/docs/reference/type-aliases/ColumnDefBase_All.md @@ -0,0 +1,26 @@ +--- +id: ColumnDefBase_All +title: ColumnDefBase_All +--- + +# Type Alias: ColumnDefBase\_All\ + +```ts +type ColumnDefBase_All = ColumnDefBase_Core & Partial & ColumnDef_GlobalFiltering & ColumnDef_RowSorting & ColumnDef_ColumnGrouping & ColumnDef_ColumnSizing & ColumnDef_ColumnResizing>; +``` + +Defined in: [types/ColumnDef.ts:117](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L117) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/ColumnDefResolved.md b/docs/reference/type-aliases/ColumnDefResolved.md new file mode 100644 index 0000000000..f475f890a7 --- /dev/null +++ b/docs/reference/type-aliases/ColumnDefResolved.md @@ -0,0 +1,34 @@ +--- +id: ColumnDefResolved +title: ColumnDefResolved +--- + +# Type Alias: ColumnDefResolved\ + +```ts +type ColumnDefResolved = Partial>> & object; +``` + +Defined in: [types/ColumnDef.ts:211](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L211) + +## Type Declaration + +### accessorKey? + +```ts +optional accessorKey: string; +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/ColumnDefTemplate.md b/docs/reference/type-aliases/ColumnDefTemplate.md new file mode 100644 index 0000000000..2f3f105ce0 --- /dev/null +++ b/docs/reference/type-aliases/ColumnDefTemplate.md @@ -0,0 +1,18 @@ +--- +id: ColumnDefTemplate +title: ColumnDefTemplate +--- + +# Type Alias: ColumnDefTemplate\ + +```ts +type ColumnDefTemplate = string | (props) => any; +``` + +Defined in: [types/ColumnDef.ts:35](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L35) + +## Type Parameters + +### TProps + +`TProps` *extends* `object` diff --git a/docs/reference/type-aliases/ColumnFilterAutoRemoveTestFn.md b/docs/reference/type-aliases/ColumnFilterAutoRemoveTestFn.md new file mode 100644 index 0000000000..2842393bc1 --- /dev/null +++ b/docs/reference/type-aliases/ColumnFilterAutoRemoveTestFn.md @@ -0,0 +1,40 @@ +--- +id: ColumnFilterAutoRemoveTestFn +title: ColumnFilterAutoRemoveTestFn +--- + +# Type Alias: ColumnFilterAutoRemoveTestFn()\ + +```ts +type ColumnFilterAutoRemoveTestFn = (value, column?) => boolean; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:65](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L65) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) + +## Parameters + +### value + +`any` + +### column? + +[`Column`](Column.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`boolean` diff --git a/docs/reference/type-aliases/ColumnFiltersState.md b/docs/reference/type-aliases/ColumnFiltersState.md new file mode 100644 index 0000000000..5e48d56e9d --- /dev/null +++ b/docs/reference/type-aliases/ColumnFiltersState.md @@ -0,0 +1,12 @@ +--- +id: ColumnFiltersState +title: ColumnFiltersState +--- + +# Type Alias: ColumnFiltersState + +```ts +type ColumnFiltersState = ColumnFilter[]; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L22) diff --git a/docs/reference/type-aliases/ColumnHelper.md b/docs/reference/type-aliases/ColumnHelper.md new file mode 100644 index 0000000000..f083e53397 --- /dev/null +++ b/docs/reference/type-aliases/ColumnHelper.md @@ -0,0 +1,165 @@ +--- +id: ColumnHelper +title: ColumnHelper +--- + +# Type Alias: ColumnHelper\ + +```ts +type ColumnHelper = object; +``` + +Defined in: [helpers/columnHelper.ts:13](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/columnHelper.ts#L13) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +## Properties + +### accessor() + +```ts +accessor: (accessor, column) => TAccessor extends AccessorFn ? AccessorFnColumnDef : AccessorKeyColumnDef; +``` + +Defined in: [helpers/columnHelper.ts:25](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/columnHelper.ts#L25) + +Creates a data column definition with an accessor key or function to extract the cell value. + +#### Type Parameters + +##### TAccessor + +`TAccessor` *extends* + \| [`AccessorFn`](AccessorFn.md)\<`TData`\> + \| [`DeepKeys`](DeepKeys.md)\<`TData`\> + +##### TValue + +`TValue` *extends* `TAccessor` *extends* [`AccessorFn`](AccessorFn.md)\<`TData`, infer TReturn\> ? `TReturn` : `TAccessor` *extends* [`DeepKeys`](DeepKeys.md)\<`TData`\> ? [`DeepValue`](DeepValue.md)\<`TData`, `TAccessor`\> : `never` + +#### Parameters + +##### accessor + +`TAccessor` + +##### column + +`TAccessor` *extends* [`AccessorFn`](AccessorFn.md)\<`TData`\> ? [`DisplayColumnDef`](DisplayColumnDef.md)\<`TFeatures`, `TData`, `TValue`\> : [`IdentifiedColumnDef`](IdentifiedColumnDef.md)\<`TFeatures`, `TData`, `TValue`\> + +#### Returns + +`TAccessor` *extends* [`AccessorFn`](AccessorFn.md)\<`TData`\> ? [`AccessorFnColumnDef`](AccessorFnColumnDef.md)\<`TFeatures`, `TData`, `TValue`\> : [`AccessorKeyColumnDef`](AccessorKeyColumnDef.md)\<`TFeatures`, `TData`, `TValue`\> + +#### Example + +```ts +helper.accessor('firstName', { cell: (info) => info.getValue() }) +helper.accessor((row) => row.lastName, { id: 'lastName' }) +``` + +*** + +### columns() + +```ts +columns: (columns) => ColumnDef[] & [...TColumns]; +``` + +Defined in: [helpers/columnHelper.ts:48](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/columnHelper.ts#L48) + +Wraps an array of column definitions to preserve each column's individual TValue type. +Uses variadic tuple types to infer element types before checking constraints, preventing type widening. + +#### Type Parameters + +##### TColumns + +`TColumns` *extends* `ReadonlyArray`\<[`ColumnDef`](ColumnDef.md)\<`TFeatures`, `TData`, `any`\>\> + +#### Parameters + +##### columns + +\[`...TColumns`\] + +#### Returns + +[`ColumnDef`](ColumnDef.md)\<`TFeatures`, `TData`, `any`\>[] & \[`...TColumns`\] + +#### Example + +```ts +helper.columns([helper.accessor('firstName', {}), helper.accessor('age', {})]) +``` + +*** + +### display() + +```ts +display: (column) => DisplayColumnDef; +``` + +Defined in: [helpers/columnHelper.ts:58](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/columnHelper.ts#L58) + +Creates a display column definition for non-data columns like actions or row selection. + +#### Parameters + +##### column + +[`DisplayColumnDef`](DisplayColumnDef.md)\<`TFeatures`, `TData`\> + +#### Returns + +[`DisplayColumnDef`](DisplayColumnDef.md)\<`TFeatures`, `TData`, `unknown`\> + +#### Example + +```ts +helper.display({ id: 'actions', header: 'Actions', cell: () => }) +``` + +*** + +### group() + +```ts +group: (column) => GroupColumnDef; +``` + +Defined in: [helpers/columnHelper.ts:75](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/columnHelper.ts#L75) + +Creates a group column definition that contains nested child columns. + +#### Parameters + +##### column + +[`GroupColumnDef`](GroupColumnDef.md)\<`TFeatures`, `TData`, `unknown`\> + +#### Returns + +[`GroupColumnDef`](GroupColumnDef.md)\<`TFeatures`, `TData`, `unknown`\> + +#### Example + +```ts +helper.group({ + id: 'name', + header: 'Name', + columns: helper.columns([ + helper.accessor('firstName', {}), + helper.accessor('lastName', { id: 'lastName' }), + ]), +}) +``` diff --git a/docs/reference/type-aliases/ColumnOrderState.md b/docs/reference/type-aliases/ColumnOrderState.md new file mode 100644 index 0000000000..462a70f464 --- /dev/null +++ b/docs/reference/type-aliases/ColumnOrderState.md @@ -0,0 +1,12 @@ +--- +id: ColumnOrderState +title: ColumnOrderState +--- + +# Type Alias: ColumnOrderState + +```ts +type ColumnOrderState = string[]; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.types.ts:5](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.types.ts#L5) diff --git a/docs/reference/type-aliases/ColumnPinningPosition.md b/docs/reference/type-aliases/ColumnPinningPosition.md new file mode 100644 index 0000000000..c95fdc43e8 --- /dev/null +++ b/docs/reference/type-aliases/ColumnPinningPosition.md @@ -0,0 +1,12 @@ +--- +id: ColumnPinningPosition +title: ColumnPinningPosition +--- + +# Type Alias: ColumnPinningPosition + +```ts +type ColumnPinningPosition = false | "left" | "right"; +``` + +Defined in: [features/column-pinning/columnPinningFeature.types.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.types.ts#L8) diff --git a/docs/reference/type-aliases/ColumnResizeDirection.md b/docs/reference/type-aliases/ColumnResizeDirection.md new file mode 100644 index 0000000000..89df72023b --- /dev/null +++ b/docs/reference/type-aliases/ColumnResizeDirection.md @@ -0,0 +1,12 @@ +--- +id: ColumnResizeDirection +title: ColumnResizeDirection +--- + +# Type Alias: ColumnResizeDirection + +```ts +type ColumnResizeDirection = "ltr" | "rtl"; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L18) diff --git a/docs/reference/type-aliases/ColumnResizeMode.md b/docs/reference/type-aliases/ColumnResizeMode.md new file mode 100644 index 0000000000..b9367fcfd0 --- /dev/null +++ b/docs/reference/type-aliases/ColumnResizeMode.md @@ -0,0 +1,12 @@ +--- +id: ColumnResizeMode +title: ColumnResizeMode +--- + +# Type Alias: ColumnResizeMode + +```ts +type ColumnResizeMode = "onChange" | "onEnd"; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:16](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L16) diff --git a/docs/reference/type-aliases/ColumnResizingDefaultOptions.md b/docs/reference/type-aliases/ColumnResizingDefaultOptions.md new file mode 100644 index 0000000000..58e7bdad4a --- /dev/null +++ b/docs/reference/type-aliases/ColumnResizingDefaultOptions.md @@ -0,0 +1,15 @@ +--- +id: ColumnResizingDefaultOptions +title: ColumnResizingDefaultOptions +--- + +# Type Alias: ColumnResizingDefaultOptions + +```ts +type ColumnResizingDefaultOptions = Pick; +``` + +Defined in: [features/column-resizing/columnResizingFeature.types.ts:39](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.types.ts#L39) diff --git a/docs/reference/type-aliases/ColumnSizingDefaultOptions.md b/docs/reference/type-aliases/ColumnSizingDefaultOptions.md new file mode 100644 index 0000000000..772e7ee00d --- /dev/null +++ b/docs/reference/type-aliases/ColumnSizingDefaultOptions.md @@ -0,0 +1,12 @@ +--- +id: ColumnSizingDefaultOptions +title: ColumnSizingDefaultOptions +--- + +# Type Alias: ColumnSizingDefaultOptions + +```ts +type ColumnSizingDefaultOptions = Pick; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L17) diff --git a/docs/reference/type-aliases/ColumnSizingState.md b/docs/reference/type-aliases/ColumnSizingState.md new file mode 100644 index 0000000000..b486a73a1f --- /dev/null +++ b/docs/reference/type-aliases/ColumnSizingState.md @@ -0,0 +1,12 @@ +--- +id: ColumnSizingState +title: ColumnSizingState +--- + +# Type Alias: ColumnSizingState + +```ts +type ColumnSizingState = Record; +``` + +Defined in: [features/column-sizing/columnSizingFeature.types.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.types.ts#L8) diff --git a/docs/reference/type-aliases/ColumnVisibilityState.md b/docs/reference/type-aliases/ColumnVisibilityState.md new file mode 100644 index 0000000000..9ee20f8915 --- /dev/null +++ b/docs/reference/type-aliases/ColumnVisibilityState.md @@ -0,0 +1,12 @@ +--- +id: ColumnVisibilityState +title: ColumnVisibilityState +--- + +# Type Alias: ColumnVisibilityState + +```ts +type ColumnVisibilityState = Record; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:6](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L6) diff --git a/docs/reference/type-aliases/Column_Internal.md b/docs/reference/type-aliases/Column_Internal.md new file mode 100644 index 0000000000..84c8bab815 --- /dev/null +++ b/docs/reference/type-aliases/Column_Internal.md @@ -0,0 +1,34 @@ +--- +id: Column_Internal +title: Column_Internal +--- + +# Type Alias: Column\_Internal\ + +```ts +type Column_Internal = Column & object; +``` + +Defined in: [types/Column.ts:80](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Column.ts#L80) + +## Type Declaration + +### columnDef + +```ts +columnDef: ColumnDefBase_All; +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` = `unknown` diff --git a/docs/reference/type-aliases/ConstructTableAPIs.md b/docs/reference/type-aliases/ConstructTableAPIs.md new file mode 100644 index 0000000000..87ad451357 --- /dev/null +++ b/docs/reference/type-aliases/ConstructTableAPIs.md @@ -0,0 +1,38 @@ +--- +id: ConstructTableAPIs +title: ConstructTableAPIs +--- + +# Type Alias: ConstructTableAPIs()\ + +```ts +type ConstructTableAPIs = (table) => void; +``` + +Defined in: [types/TableFeatures.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L45) + +## Type Parameters + +### TConstructors + +`TConstructors` *extends* `FeatureConstructors` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +## Parameters + +### table + +[`Table_Internal`](Table_Internal.md)\<`TFeatures`, `TData`\> & `Partial`\<`TConstructors`\[`"Table"`\]\> & `object` + +## Returns + +`void` diff --git a/docs/reference/type-aliases/CreateRowModels.md b/docs/reference/type-aliases/CreateRowModels.md new file mode 100644 index 0000000000..d2bcc1f32f --- /dev/null +++ b/docs/reference/type-aliases/CreateRowModels.md @@ -0,0 +1,28 @@ +--- +id: CreateRowModels +title: CreateRowModels +--- + +# Type Alias: CreateRowModels\ + +```ts +type CreateRowModels = CreateRowModel_Core & UnionToIntersection< + | "columnFacetingFeature" extends keyof TFeatures ? CreateRowModel_Faceted : never + | "columnFilteringFeature" extends keyof TFeatures ? CreateRowModel_Filtered : never + | "rowExpandingFeature" extends keyof TFeatures ? CreateRowModel_Expanded : never + | "columnGroupingFeature" extends keyof TFeatures ? CreateRowModel_Grouped : never + | "rowPaginationFeature" extends keyof TFeatures ? CreateRowModel_Paginated : never +| "rowSortingFeature" extends keyof TFeatures ? CreateRowModel_Sorted : never> & ExtractFeatureTypes<"CreateRowModels", TFeatures> & CreateRowModels_Plugins; +``` + +Defined in: [types/RowModel.ts:42](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/RowModel.ts#L42) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/CreateRowModels_All.md b/docs/reference/type-aliases/CreateRowModels_All.md new file mode 100644 index 0000000000..8ae438283e --- /dev/null +++ b/docs/reference/type-aliases/CreateRowModels_All.md @@ -0,0 +1,22 @@ +--- +id: CreateRowModels_All +title: CreateRowModels_All +--- + +# Type Alias: CreateRowModels\_All\ + +```ts +type CreateRowModels_All = CreateRowModel_Core & CreateRowModel_Expanded & CreateRowModel_Faceted & CreateRowModel_Filtered & CreateRowModel_Grouped & CreateRowModel_Paginated & CreateRowModel_Sorted; +``` + +Defined in: [types/RowModel.ts:76](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/RowModel.ts#L76) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/CustomAggregationFns.md b/docs/reference/type-aliases/CustomAggregationFns.md new file mode 100644 index 0000000000..e5ffaa6bb5 --- /dev/null +++ b/docs/reference/type-aliases/CustomAggregationFns.md @@ -0,0 +1,22 @@ +--- +id: CustomAggregationFns +title: CustomAggregationFns +--- + +# Type Alias: CustomAggregationFns\ + +```ts +type CustomAggregationFns = Record>; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:39](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L39) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/CustomFilterFns.md b/docs/reference/type-aliases/CustomFilterFns.md new file mode 100644 index 0000000000..e6d01a4713 --- /dev/null +++ b/docs/reference/type-aliases/CustomFilterFns.md @@ -0,0 +1,22 @@ +--- +id: CustomFilterFns +title: CustomFilterFns +--- + +# Type Alias: CustomFilterFns\ + +```ts +type CustomFilterFns = Record>; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:71](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L71) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/CustomSortFns.md b/docs/reference/type-aliases/CustomSortFns.md new file mode 100644 index 0000000000..9543336bdf --- /dev/null +++ b/docs/reference/type-aliases/CustomSortFns.md @@ -0,0 +1,22 @@ +--- +id: CustomSortFns +title: CustomSortFns +--- + +# Type Alias: CustomSortFns\ + +```ts +type CustomSortFns = Record>; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:41](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L41) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/DebugOptions.md b/docs/reference/type-aliases/DebugOptions.md new file mode 100644 index 0000000000..24f4b37697 --- /dev/null +++ b/docs/reference/type-aliases/DebugOptions.md @@ -0,0 +1,62 @@ +--- +id: DebugOptions +title: DebugOptions +--- + +# Type Alias: DebugOptions\ + +```ts +type DebugOptions = object & DebugKeysFor; +``` + +Defined in: [types/TableOptions.ts:41](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableOptions.ts#L41) + +## Type Declaration + +### debugAll? + +```ts +optional debugAll: boolean; +``` + +### debugCache? + +```ts +optional debugCache: boolean; +``` + +### debugCells? + +```ts +optional debugCells: boolean; +``` + +### debugColumns? + +```ts +optional debugColumns: boolean; +``` + +### debugHeaders? + +```ts +optional debugHeaders: boolean; +``` + +### debugRows? + +```ts +optional debugRows: boolean; +``` + +### debugTable? + +```ts +optional debugTable: boolean; +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) diff --git a/docs/reference/type-aliases/DeepKeys.md b/docs/reference/type-aliases/DeepKeys.md new file mode 100644 index 0000000000..492a70f0ca --- /dev/null +++ b/docs/reference/type-aliases/DeepKeys.md @@ -0,0 +1,24 @@ +--- +id: DeepKeys +title: DeepKeys +--- + +# Type Alias: DeepKeys\ + +```ts +type DeepKeys = TDepth["length"] extends 5 ? never : unknown extends T ? string : T extends ReadonlyArray & IsTuple ? + | AllowedIndexes + | DeepKeysPrefix, TDepth> : T extends any[] ? DeepKeys : T extends Date ? never : T extends object ? keyof T & string | DeepKeysPrefix : never; +``` + +Defined in: [types/type-utils.ts:46](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/type-utils.ts#L46) + +## Type Parameters + +### T + +`T` + +### TDepth + +`TDepth` *extends* `any`[] = \[\] diff --git a/docs/reference/type-aliases/DeepValue.md b/docs/reference/type-aliases/DeepValue.md new file mode 100644 index 0000000000..a218d29cef --- /dev/null +++ b/docs/reference/type-aliases/DeepValue.md @@ -0,0 +1,22 @@ +--- +id: DeepValue +title: DeepValue +--- + +# Type Alias: DeepValue\ + +```ts +type DeepValue = T extends Record ? TProp extends `${infer TBranch}.${infer TDeepProp}` ? DeepValue : T[TProp & string] : never; +``` + +Defined in: [types/type-utils.ts:71](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/type-utils.ts#L71) + +## Type Parameters + +### T + +`T` + +### TProp + +`TProp` diff --git a/docs/reference/type-aliases/DisplayColumnDef.md b/docs/reference/type-aliases/DisplayColumnDef.md new file mode 100644 index 0000000000..ace9c7ea70 --- /dev/null +++ b/docs/reference/type-aliases/DisplayColumnDef.md @@ -0,0 +1,26 @@ +--- +id: DisplayColumnDef +title: DisplayColumnDef +--- + +# Type Alias: DisplayColumnDef\ + +```ts +type DisplayColumnDef = ColumnDefBase & ColumnIdentifiers; +``` + +Defined in: [types/ColumnDef.ts:142](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L142) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/ExpandedState.md b/docs/reference/type-aliases/ExpandedState.md new file mode 100644 index 0000000000..3f083c0be2 --- /dev/null +++ b/docs/reference/type-aliases/ExpandedState.md @@ -0,0 +1,12 @@ +--- +id: ExpandedState +title: ExpandedState +--- + +# Type Alias: ExpandedState + +```ts +type ExpandedState = true | Record; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L8) diff --git a/docs/reference/type-aliases/ExpandedStateList.md b/docs/reference/type-aliases/ExpandedStateList.md new file mode 100644 index 0000000000..f61d5b51f1 --- /dev/null +++ b/docs/reference/type-aliases/ExpandedStateList.md @@ -0,0 +1,12 @@ +--- +id: ExpandedStateList +title: ExpandedStateList +--- + +# Type Alias: ExpandedStateList + +```ts +type ExpandedStateList = Record; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.types.ts:7](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.types.ts#L7) diff --git a/docs/reference/type-aliases/ExtractFeatureTypes.md b/docs/reference/type-aliases/ExtractFeatureTypes.md new file mode 100644 index 0000000000..e52d49b7ca --- /dev/null +++ b/docs/reference/type-aliases/ExtractFeatureTypes.md @@ -0,0 +1,22 @@ +--- +id: ExtractFeatureTypes +title: ExtractFeatureTypes +--- + +# Type Alias: ExtractFeatureTypes\ + +```ts +type ExtractFeatureTypes = UnionToIntersection<{ [K in keyof TFeatures]: TFeatures[K] extends TableFeature ? TKey extends keyof FeatureConstructorOptions ? FeatureConstructorOptions[TKey] : never : any }[keyof TFeatures]>; +``` + +Defined in: [types/TableFeatures.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L10) + +## Type Parameters + +### TKey + +`TKey` *extends* keyof `FeatureConstructors` + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) diff --git a/docs/reference/type-aliases/FilterFnOption.md b/docs/reference/type-aliases/FilterFnOption.md new file mode 100644 index 0000000000..3cb48c19c4 --- /dev/null +++ b/docs/reference/type-aliases/FilterFnOption.md @@ -0,0 +1,26 @@ +--- +id: FilterFnOption +title: FilterFnOption +--- + +# Type Alias: FilterFnOption\ + +```ts +type FilterFnOption = + | "auto" + | BuiltInFilterFn + | keyof FilterFns +| FilterFn; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:76](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L76) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/GetDefaultColumnDef.md b/docs/reference/type-aliases/GetDefaultColumnDef.md new file mode 100644 index 0000000000..bc83c5d5bf --- /dev/null +++ b/docs/reference/type-aliases/GetDefaultColumnDef.md @@ -0,0 +1,36 @@ +--- +id: GetDefaultColumnDef +title: GetDefaultColumnDef +--- + +# Type Alias: GetDefaultColumnDef()\ + +```ts +type GetDefaultColumnDef = () => ColumnDefBase_All & Partial; +``` + +Defined in: [types/TableFeatures.ts:55](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L55) + +## Type Parameters + +### TConstructors + +`TConstructors` *extends* `FeatureConstructors` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) + +## Returns + +[`ColumnDefBase_All`](ColumnDefBase_All.md)\<`TFeatures`, `TData`, `TValue`\> & `Partial`\<`TConstructors`\[`"ColumnDef"`\]\> diff --git a/docs/reference/type-aliases/GetDefaultStateSelector.md b/docs/reference/type-aliases/GetDefaultStateSelector.md new file mode 100644 index 0000000000..486d6f0b51 --- /dev/null +++ b/docs/reference/type-aliases/GetDefaultStateSelector.md @@ -0,0 +1,28 @@ +--- +id: GetDefaultStateSelector +title: GetDefaultStateSelector +--- + +# Type Alias: GetDefaultStateSelector()\ + +```ts +type GetDefaultStateSelector = (state) => Partial & Partial; +``` + +Defined in: [types/TableFeatures.ts:72](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L72) + +## Type Parameters + +### TConstructors + +`TConstructors` *extends* `FeatureConstructors` + +## Parameters + +### state + +[`TableState_All`](TableState_All.md) + +## Returns + +`Partial`\<[`TableState_All`](TableState_All.md)\> & `Partial`\<`TConstructors`\[`"TableState"`\]\> diff --git a/docs/reference/type-aliases/GetDefaultTableOptions.md b/docs/reference/type-aliases/GetDefaultTableOptions.md new file mode 100644 index 0000000000..867abc8fdd --- /dev/null +++ b/docs/reference/type-aliases/GetDefaultTableOptions.md @@ -0,0 +1,38 @@ +--- +id: GetDefaultTableOptions +title: GetDefaultTableOptions +--- + +# Type Alias: GetDefaultTableOptions()\ + +```ts +type GetDefaultTableOptions = (table) => Partial> & Partial; +``` + +Defined in: [types/TableFeatures.ts:62](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L62) + +## Type Parameters + +### TConstructors + +`TConstructors` *extends* `FeatureConstructors` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +## Parameters + +### table + +[`Table_Internal`](Table_Internal.md)\<`TFeatures`, `TData`\> & `Partial`\<`TConstructors`\[`"Table"`\]\> + +## Returns + +`Partial`\<[`TableOptions_All`](TableOptions_All.md)\<`TFeatures`, `TData`\>\> & `Partial`\<`TConstructors`\[`"TableOptions"`\]\> diff --git a/docs/reference/type-aliases/GetInitialState.md b/docs/reference/type-aliases/GetInitialState.md new file mode 100644 index 0000000000..1ebf5fb99b --- /dev/null +++ b/docs/reference/type-aliases/GetInitialState.md @@ -0,0 +1,28 @@ +--- +id: GetInitialState +title: GetInitialState +--- + +# Type Alias: GetInitialState()\ + +```ts +type GetInitialState = (initialState) => TableState_All & Partial; +``` + +Defined in: [types/TableFeatures.ts:68](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L68) + +## Type Parameters + +### TConstructors + +`TConstructors` *extends* `FeatureConstructors` + +## Parameters + +### initialState + +`Partial`\<[`TableState_All`](TableState_All.md)\> & `Partial`\<`TConstructors`\[`"TableState"`\]\> + +## Returns + +[`TableState_All`](TableState_All.md) & `Partial`\<`TConstructors`\[`"TableState"`\]\> diff --git a/docs/reference/type-aliases/Getter.md b/docs/reference/type-aliases/Getter.md new file mode 100644 index 0000000000..3f894da629 --- /dev/null +++ b/docs/reference/type-aliases/Getter.md @@ -0,0 +1,28 @@ +--- +id: Getter +title: Getter +--- + +# Type Alias: Getter()\ + +```ts +type Getter = () => NoInfer; +``` + +Defined in: [types/type-utils.ts:80](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/type-utils.ts#L80) + +## Type Parameters + +### TValue + +`TValue` + +## Type Parameters + +### TTValue + +`TTValue` = `TValue` + +## Returns + +[`NoInfer`](NoInfer.md)\<`TTValue`\> diff --git a/docs/reference/type-aliases/GroupColumnDef.md b/docs/reference/type-aliases/GroupColumnDef.md new file mode 100644 index 0000000000..2a6a72d73f --- /dev/null +++ b/docs/reference/type-aliases/GroupColumnDef.md @@ -0,0 +1,26 @@ +--- +id: GroupColumnDef +title: GroupColumnDef +--- + +# Type Alias: GroupColumnDef\ + +```ts +type GroupColumnDef = GroupColumnDefBase & ColumnIdentifiers; +``` + +Defined in: [types/ColumnDef.ts:156](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L156) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/GroupingColumnMode.md b/docs/reference/type-aliases/GroupingColumnMode.md new file mode 100644 index 0000000000..6034d551e8 --- /dev/null +++ b/docs/reference/type-aliases/GroupingColumnMode.md @@ -0,0 +1,12 @@ +--- +id: GroupingColumnMode +title: GroupingColumnMode +--- + +# Type Alias: GroupingColumnMode + +```ts +type GroupingColumnMode = false | "reorder" | "remove"; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:171](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L171) diff --git a/docs/reference/type-aliases/GroupingState.md b/docs/reference/type-aliases/GroupingState.md new file mode 100644 index 0000000000..40690ac7cf --- /dev/null +++ b/docs/reference/type-aliases/GroupingState.md @@ -0,0 +1,12 @@ +--- +id: GroupingState +title: GroupingState +--- + +# Type Alias: GroupingState + +```ts +type GroupingState = string[]; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.types.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.types.ts#L15) diff --git a/docs/reference/type-aliases/Header.md b/docs/reference/type-aliases/Header.md new file mode 100644 index 0000000000..0a7f21d453 --- /dev/null +++ b/docs/reference/type-aliases/Header.md @@ -0,0 +1,28 @@ +--- +id: Header +title: Header +--- + +# Type Alias: Header\ + +```ts +type Header = Header_Core & UnionToIntersection< + | "columnSizingFeature" extends keyof TFeatures ? Header_ColumnSizing : never +| "columnResizingFeature" extends keyof TFeatures ? Header_ColumnResizing : never> & ExtractFeatureTypes<"Header", TFeatures> & Header_Plugins; +``` + +Defined in: [types/Header.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Header.ts#L23) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/HeaderGroup.md b/docs/reference/type-aliases/HeaderGroup.md new file mode 100644 index 0000000000..10918eec2b --- /dev/null +++ b/docs/reference/type-aliases/HeaderGroup.md @@ -0,0 +1,22 @@ +--- +id: HeaderGroup +title: HeaderGroup +--- + +# Type Alias: HeaderGroup\ + +```ts +type HeaderGroup = HeaderGroup_Core & ExtractFeatureTypes<"HeaderGroup", TFeatures> & HeaderGroup_Plugins; +``` + +Defined in: [types/HeaderGroup.ts:19](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/HeaderGroup.ts#L19) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/IdentifiedColumnDef.md b/docs/reference/type-aliases/IdentifiedColumnDef.md new file mode 100644 index 0000000000..2dcfeafae5 --- /dev/null +++ b/docs/reference/type-aliases/IdentifiedColumnDef.md @@ -0,0 +1,40 @@ +--- +id: IdentifiedColumnDef +title: IdentifiedColumnDef +--- + +# Type Alias: IdentifiedColumnDef\ + +```ts +type IdentifiedColumnDef = ColumnDefBase & object; +``` + +Defined in: [types/ColumnDef.ts:133](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L133) + +## Type Declaration + +### header? + +```ts +optional header: StringOrTemplateHeader; +``` + +### id? + +```ts +optional id: string; +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/InitRowInstanceData.md b/docs/reference/type-aliases/InitRowInstanceData.md new file mode 100644 index 0000000000..53db1bcfa6 --- /dev/null +++ b/docs/reference/type-aliases/InitRowInstanceData.md @@ -0,0 +1,38 @@ +--- +id: InitRowInstanceData +title: InitRowInstanceData +--- + +# Type Alias: InitRowInstanceData()\ + +```ts +type InitRowInstanceData = (row) => void; +``` + +Defined in: [types/TableFeatures.ts:109](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableFeatures.ts#L109) + +## Type Parameters + +### TConstructors + +`TConstructors` *extends* `FeatureConstructors` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +## Parameters + +### row + +[`Row`](Row.md)\<`TFeatures`, `TData`\> & `Partial`\<`TConstructors`\[`"Row"`\]\> + +## Returns + +`void` diff --git a/docs/reference/type-aliases/MemoFnMeta.md b/docs/reference/type-aliases/MemoFnMeta.md new file mode 100644 index 0000000000..8bd1a0b73b --- /dev/null +++ b/docs/reference/type-aliases/MemoFnMeta.md @@ -0,0 +1,22 @@ +--- +id: MemoFnMeta +title: MemoFnMeta +--- + +# Type Alias: MemoFnMeta + +```ts +type MemoFnMeta = object; +``` + +Defined in: [utils.ts:62](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L62) + +## Properties + +### originalArgsLength? + +```ts +optional originalArgsLength: number; +``` + +Defined in: [utils.ts:62](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L62) diff --git a/docs/reference/type-aliases/NoInfer.md b/docs/reference/type-aliases/NoInfer.md new file mode 100644 index 0000000000..d114f1f8cc --- /dev/null +++ b/docs/reference/type-aliases/NoInfer.md @@ -0,0 +1,18 @@ +--- +id: NoInfer +title: NoInfer +--- + +# Type Alias: NoInfer\ + +```ts +type NoInfer = [T][T extends any ? 0 : never]; +``` + +Defined in: [types/type-utils.ts:78](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/type-utils.ts#L78) + +## Type Parameters + +### T + +`T` diff --git a/docs/reference/type-aliases/OnChangeFn.md b/docs/reference/type-aliases/OnChangeFn.md new file mode 100644 index 0000000000..6b84ff8b45 --- /dev/null +++ b/docs/reference/type-aliases/OnChangeFn.md @@ -0,0 +1,28 @@ +--- +id: OnChangeFn +title: OnChangeFn +--- + +# Type Alias: OnChangeFn()\ + +```ts +type OnChangeFn = (updaterOrValue) => void; +``` + +Defined in: [types/type-utils.ts:3](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/type-utils.ts#L3) + +## Type Parameters + +### T + +`T` + +## Parameters + +### updaterOrValue + +[`Updater`](Updater.md)\<`T`\> + +## Returns + +`void` diff --git a/docs/reference/type-aliases/PartialKeys.md b/docs/reference/type-aliases/PartialKeys.md new file mode 100644 index 0000000000..560bb4cfbf --- /dev/null +++ b/docs/reference/type-aliases/PartialKeys.md @@ -0,0 +1,22 @@ +--- +id: PartialKeys +title: PartialKeys +--- + +# Type Alias: PartialKeys\ + +```ts +type PartialKeys = Omit & Partial>; +``` + +Defined in: [types/type-utils.ts:9](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/type-utils.ts#L9) + +## Type Parameters + +### T + +`T` + +### K + +`K` *extends* keyof `T` diff --git a/docs/reference/type-aliases/Prettify.md b/docs/reference/type-aliases/Prettify.md new file mode 100644 index 0000000000..308b5177aa --- /dev/null +++ b/docs/reference/type-aliases/Prettify.md @@ -0,0 +1,18 @@ +--- +id: Prettify +title: Prettify +--- + +# Type Alias: Prettify\ + +```ts +type Prettify = { [K in keyof T]: T[K] } & unknown; +``` + +Defined in: [types/type-utils.ts:82](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/type-utils.ts#L82) + +## Type Parameters + +### T + +`T` diff --git a/docs/reference/type-aliases/PrototypeAPIObject.md b/docs/reference/type-aliases/PrototypeAPIObject.md new file mode 100644 index 0000000000..a49ea8560c --- /dev/null +++ b/docs/reference/type-aliases/PrototypeAPIObject.md @@ -0,0 +1,22 @@ +--- +id: PrototypeAPIObject +title: PrototypeAPIObject +--- + +# Type Alias: PrototypeAPIObject\ + +```ts +type PrototypeAPIObject = Record>; +``` + +Defined in: [utils.ts:327](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L327) + +## Type Parameters + +### TDeps + +`TDeps` *extends* `ReadonlyArray`\<`any`\> + +### TDepArgs + +`TDepArgs` diff --git a/docs/reference/type-aliases/RequiredKeys.md b/docs/reference/type-aliases/RequiredKeys.md new file mode 100644 index 0000000000..bbf82b7740 --- /dev/null +++ b/docs/reference/type-aliases/RequiredKeys.md @@ -0,0 +1,22 @@ +--- +id: RequiredKeys +title: RequiredKeys +--- + +# Type Alias: RequiredKeys\ + +```ts +type RequiredKeys = Omit & Required>; +``` + +Defined in: [types/type-utils.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/type-utils.ts#L11) + +## Type Parameters + +### T + +`T` + +### K + +`K` *extends* keyof `T` diff --git a/docs/reference/type-aliases/Row.md b/docs/reference/type-aliases/Row.md new file mode 100644 index 0000000000..3952ae74ba --- /dev/null +++ b/docs/reference/type-aliases/Row.md @@ -0,0 +1,29 @@ +--- +id: Row +title: Row +--- + +# Type Alias: Row\ + +```ts +type Row = Row_Core & UnionToIntersection< + | "columnFilteringFeature" extends keyof TFeatures ? Row_ColumnFiltering : never + | "columnGroupingFeature" extends keyof TFeatures ? Row_ColumnGrouping : never + | "columnPinningFeature" extends keyof TFeatures ? Row_ColumnPinning : never + | "columnVisibilityFeature" extends keyof TFeatures ? Row_ColumnVisibility : never + | "rowExpandingFeature" extends keyof TFeatures ? Row_RowExpanding : never + | "rowPinningFeature" extends keyof TFeatures ? Row_RowPinning : never +| "rowSelectionFeature" extends keyof TFeatures ? Row_RowSelection : never> & ExtractFeatureTypes<"Row", TFeatures> & Row_Plugins; +``` + +Defined in: [types/Row.ts:26](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Row.ts#L26) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/RowData.md b/docs/reference/type-aliases/RowData.md new file mode 100644 index 0000000000..752ab32417 --- /dev/null +++ b/docs/reference/type-aliases/RowData.md @@ -0,0 +1,12 @@ +--- +id: RowData +title: RowData +--- + +# Type Alias: RowData + +```ts +type RowData = Record | any[]; +``` + +Defined in: [types/type-utils.ts:5](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/type-utils.ts#L5) diff --git a/docs/reference/type-aliases/RowModelFns.md b/docs/reference/type-aliases/RowModelFns.md new file mode 100644 index 0000000000..35fb67dbbc --- /dev/null +++ b/docs/reference/type-aliases/RowModelFns.md @@ -0,0 +1,25 @@ +--- +id: RowModelFns +title: RowModelFns +--- + +# Type Alias: RowModelFns\ + +```ts +type RowModelFns = Partial : never + | "columnGroupingFeature" extends keyof TFeatures ? RowModelFns_ColumnGrouping : never +| "rowSortingFeature" extends keyof TFeatures ? RowModelFns_RowSorting : never> & ExtractFeatureTypes<"RowModelFns", TFeatures> & RowModelFns_Plugins>; +``` + +Defined in: [types/RowModelFns.ts:18](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/RowModelFns.ts#L18) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/RowModelFns_All.md b/docs/reference/type-aliases/RowModelFns_All.md new file mode 100644 index 0000000000..fcef1570c3 --- /dev/null +++ b/docs/reference/type-aliases/RowModelFns_All.md @@ -0,0 +1,22 @@ +--- +id: RowModelFns_All +title: RowModelFns_All +--- + +# Type Alias: RowModelFns\_All\ + +```ts +type RowModelFns_All = Partial & RowModelFns_ColumnGrouping & RowModelFns_RowSorting>; +``` + +Defined in: [types/RowModelFns.ts:44](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/RowModelFns.ts#L44) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/RowPinningPosition.md b/docs/reference/type-aliases/RowPinningPosition.md new file mode 100644 index 0000000000..4aeb8352ab --- /dev/null +++ b/docs/reference/type-aliases/RowPinningPosition.md @@ -0,0 +1,12 @@ +--- +id: RowPinningPosition +title: RowPinningPosition +--- + +# Type Alias: RowPinningPosition + +```ts +type RowPinningPosition = false | "top" | "bottom"; +``` + +Defined in: [features/row-pinning/rowPinningFeature.types.ts:5](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.types.ts#L5) diff --git a/docs/reference/type-aliases/RowSelectionState.md b/docs/reference/type-aliases/RowSelectionState.md new file mode 100644 index 0000000000..6c89907474 --- /dev/null +++ b/docs/reference/type-aliases/RowSelectionState.md @@ -0,0 +1,12 @@ +--- +id: RowSelectionState +title: RowSelectionState +--- + +# Type Alias: RowSelectionState + +```ts +type RowSelectionState = Record; +``` + +Defined in: [features/row-selection/rowSelectionFeature.types.ts:6](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.types.ts#L6) diff --git a/docs/reference/type-aliases/SortDirection.md b/docs/reference/type-aliases/SortDirection.md new file mode 100644 index 0000000000..6f7c1078ab --- /dev/null +++ b/docs/reference/type-aliases/SortDirection.md @@ -0,0 +1,12 @@ +--- +id: SortDirection +title: SortDirection +--- + +# Type Alias: SortDirection + +```ts +type SortDirection = "asc" | "desc"; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L8) diff --git a/docs/reference/type-aliases/SortFnOption.md b/docs/reference/type-aliases/SortFnOption.md new file mode 100644 index 0000000000..bdca371be4 --- /dev/null +++ b/docs/reference/type-aliases/SortFnOption.md @@ -0,0 +1,26 @@ +--- +id: SortFnOption +title: SortFnOption +--- + +# Type Alias: SortFnOption\ + +```ts +type SortFnOption = + | "auto" + | keyof SortFns + | BuiltInSortFn +| SortFn; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:46](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L46) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/SortingState.md b/docs/reference/type-aliases/SortingState.md new file mode 100644 index 0000000000..954185c4d8 --- /dev/null +++ b/docs/reference/type-aliases/SortingState.md @@ -0,0 +1,12 @@ +--- +id: SortingState +title: SortingState +--- + +# Type Alias: SortingState + +```ts +type SortingState = ColumnSort[]; +``` + +Defined in: [features/row-sorting/rowSortingFeature.types.ts:15](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.types.ts#L15) diff --git a/docs/reference/type-aliases/StringOrTemplateHeader.md b/docs/reference/type-aliases/StringOrTemplateHeader.md new file mode 100644 index 0000000000..b63735544b --- /dev/null +++ b/docs/reference/type-aliases/StringOrTemplateHeader.md @@ -0,0 +1,28 @@ +--- +id: StringOrTemplateHeader +title: StringOrTemplateHeader +--- + +# Type Alias: StringOrTemplateHeader\ + +```ts +type StringOrTemplateHeader = + | string +| ColumnDefTemplate>; +``` + +Defined in: [types/ColumnDef.ts:39](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/ColumnDef.ts#L39) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) diff --git a/docs/reference/type-aliases/Table.md b/docs/reference/type-aliases/Table.md new file mode 100644 index 0000000000..a35164e648 --- /dev/null +++ b/docs/reference/type-aliases/Table.md @@ -0,0 +1,38 @@ +--- +id: Table +title: Table +--- + +# Type Alias: Table\ + +```ts +type Table = Table_Core & UnionToIntersection< + | "columnFilteringFeature" extends keyof TFeatures ? Table_ColumnFiltering : never + | "columnGroupingFeature" extends keyof TFeatures ? Table_ColumnGrouping : never + | "columnOrderingFeature" extends keyof TFeatures ? Table_ColumnOrdering : never + | "columnPinningFeature" extends keyof TFeatures ? Table_ColumnPinning : never + | "columnResizingFeature" extends keyof TFeatures ? Table_ColumnResizing : never + | "columnSizingFeature" extends keyof TFeatures ? Table_ColumnSizing : never + | "columnVisibilityFeature" extends keyof TFeatures ? Table_ColumnVisibility : never + | "columnFacetingFeature" extends keyof TFeatures ? Table_ColumnFaceting : never + | "globalFilteringFeature" extends keyof TFeatures ? Table_GlobalFiltering : never + | "rowExpandingFeature" extends keyof TFeatures ? Table_RowExpanding : never + | "rowPaginationFeature" extends keyof TFeatures ? Table_RowPagination : never + | "rowPinningFeature" extends keyof TFeatures ? Table_RowPinning : never + | "rowSelectionFeature" extends keyof TFeatures ? Table_RowSelection : never +| "rowSortingFeature" extends keyof TFeatures ? Table_RowSorting : never> & ExtractFeatureTypes<"Table", TFeatures> & Table_Plugins; +``` + +Defined in: [types/Table.ts:53](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Table.ts#L53) + +The table object that includes both the core table functionality and the features that are enabled via the `_features` table option. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/TableHelperOptions.md b/docs/reference/type-aliases/TableHelperOptions.md new file mode 100644 index 0000000000..c76017cc56 --- /dev/null +++ b/docs/reference/type-aliases/TableHelperOptions.md @@ -0,0 +1,29 @@ +--- +id: TableHelperOptions +title: TableHelperOptions +--- + +# Type Alias: TableHelperOptions\ + +```ts +type TableHelperOptions = Omit, "columns" | "data" | "store" | "state" | "initialState"> & object; +``` + +Defined in: [helpers/tableHelper.ts:12](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableHelper.ts#L12) + +Options for creating a table helper to share common options across multiple tables +coreColumnsFeature, data, and state are excluded from this type and reserved for only the `useTable`/`createTable` functions + +## Type Declaration + +### \_features + +```ts +_features: TFeatures; +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) diff --git a/docs/reference/type-aliases/TableHelper_Core.md b/docs/reference/type-aliases/TableHelper_Core.md new file mode 100644 index 0000000000..4e2fd47068 --- /dev/null +++ b/docs/reference/type-aliases/TableHelper_Core.md @@ -0,0 +1,90 @@ +--- +id: TableHelper_Core +title: TableHelper_Core +--- + +# Type Alias: TableHelper\_Core\ + +```ts +type TableHelper_Core = object; +``` + +Defined in: [helpers/tableHelper.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableHelper.ts#L22) + +Internal type that each adapter package will build off of to create a table helper + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +## Properties + +### createColumnHelper() + +```ts +createColumnHelper: () => ColumnHelper; +``` + +Defined in: [helpers/tableHelper.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableHelper.ts#L23) + +#### Type Parameters + +##### TData + +`TData` *extends* [`RowData`](RowData.md) + +#### Returns + +[`ColumnHelper`](ColumnHelper.md)\<`TFeatures`, `TData`\> + +*** + +### features + +```ts +features: TFeatures; +``` + +Defined in: [helpers/tableHelper.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableHelper.ts#L27) + +*** + +### options + +```ts +options: Omit, "columns" | "data" | "store" | "state" | "initialState">; +``` + +Defined in: [helpers/tableHelper.ts:28](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableHelper.ts#L28) + +*** + +### tableCreator() + +```ts +tableCreator: (tableOptions, selector?) => Table; +``` + +Defined in: [helpers/tableHelper.ts:32](https://github.com/TanStack/table/blob/main/packages/table-core/src/helpers/tableHelper.ts#L32) + +#### Type Parameters + +##### TData + +`TData` *extends* [`RowData`](RowData.md) + +#### Parameters + +##### tableOptions + +`Omit`\<[`TableOptions`](TableOptions.md)\<`TFeatures`, `TData`\>, `"_features"` \| `"_rowModels"`\> + +##### selector? + +`any` + +#### Returns + +[`Table`](Table.md)\<`TFeatures`, `TData`\> diff --git a/docs/reference/type-aliases/TableOptions.md b/docs/reference/type-aliases/TableOptions.md new file mode 100644 index 0000000000..fc7f03a758 --- /dev/null +++ b/docs/reference/type-aliases/TableOptions.md @@ -0,0 +1,35 @@ +--- +id: TableOptions +title: TableOptions +--- + +# Type Alias: TableOptions\ + +```ts +type TableOptions = TableOptions_Core & UnionToIntersection< + | "columnFilteringFeature" extends keyof TFeatures ? TableOptions_ColumnFiltering : never + | "columnGroupingFeature" extends keyof TFeatures ? TableOptions_ColumnGrouping : never + | "columnOrderingFeature" extends keyof TFeatures ? TableOptions_ColumnOrdering : never + | "columnPinningFeature" extends keyof TFeatures ? TableOptions_ColumnPinning : never + | "columnResizingFeature" extends keyof TFeatures ? TableOptions_ColumnResizing : never + | "columnSizingFeature" extends keyof TFeatures ? TableOptions_ColumnSizing : never + | "columnVisibilityFeature" extends keyof TFeatures ? TableOptions_ColumnVisibility : never + | "globalFilteringFeature" extends keyof TFeatures ? TableOptions_GlobalFiltering : never + | "rowExpandingFeature" extends keyof TFeatures ? TableOptions_RowExpanding : never + | "rowPaginationFeature" extends keyof TFeatures ? TableOptions_RowPagination : never + | "rowPinningFeature" extends keyof TFeatures ? TableOptions_RowPinning : never + | "rowSelectionFeature" extends keyof TFeatures ? TableOptions_RowSelection : never +| "rowSortingFeature" extends keyof TFeatures ? TableOptions_RowSorting : never> & ExtractFeatureTypes<"TableOptions", TFeatures> & TableOptions_Plugins & DebugOptions; +``` + +Defined in: [types/TableOptions.ts:51](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableOptions.ts#L51) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/TableOptions_All.md b/docs/reference/type-aliases/TableOptions_All.md new file mode 100644 index 0000000000..e05e46d917 --- /dev/null +++ b/docs/reference/type-aliases/TableOptions_All.md @@ -0,0 +1,22 @@ +--- +id: TableOptions_All +title: TableOptions_All +--- + +# Type Alias: TableOptions\_All\ + +```ts +type TableOptions_All = TableOptions_Core & Partial & TableOptions_ColumnGrouping & TableOptions_ColumnOrdering & TableOptions_ColumnPinning & TableOptions_ColumnResizing & TableOptions_ColumnSizing & TableOptions_ColumnVisibility & TableOptions_GlobalFiltering & TableOptions_RowExpanding & TableOptions_RowPagination & TableOptions_RowPinning & TableOptions_RowSelection & TableOptions_RowSorting>; +``` + +Defined in: [types/TableOptions.ts:107](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableOptions.ts#L107) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/TableState.md b/docs/reference/type-aliases/TableState.md new file mode 100644 index 0000000000..c8b8d8fdc2 --- /dev/null +++ b/docs/reference/type-aliases/TableState.md @@ -0,0 +1,31 @@ +--- +id: TableState +title: TableState +--- + +# Type Alias: TableState\ + +```ts +type TableState = UnionToIntersection< + | "columnFilteringFeature" extends keyof TFeatures ? TableState_ColumnFiltering : never + | "columnGroupingFeature" extends keyof TFeatures ? TableState_ColumnGrouping : never + | "columnOrderingFeature" extends keyof TFeatures ? TableState_ColumnOrdering : never + | "columnPinningFeature" extends keyof TFeatures ? TableState_ColumnPinning : never + | "columnResizingFeature" extends keyof TFeatures ? TableState_ColumnResizing : never + | "columnSizingFeature" extends keyof TFeatures ? TableState_ColumnSizing : never + | "columnVisibilityFeature" extends keyof TFeatures ? TableState_ColumnVisibility : never + | "globalFilteringFeature" extends keyof TFeatures ? TableState_GlobalFiltering : never + | "rowExpandingFeature" extends keyof TFeatures ? TableState_RowExpanding : never + | "rowPaginationFeature" extends keyof TFeatures ? TableState_RowPagination : never + | "rowPinningFeature" extends keyof TFeatures ? TableState_RowPinning : never + | "rowSelectionFeature" extends keyof TFeatures ? TableState_RowSelection : never +| "rowSortingFeature" extends keyof TFeatures ? TableState_RowSorting : never> & ExtractFeatureTypes<"TableState", TFeatures> & TableState_Plugins; +``` + +Defined in: [types/TableState.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableState.ts#L23) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) diff --git a/docs/reference/type-aliases/TableState_All.md b/docs/reference/type-aliases/TableState_All.md new file mode 100644 index 0000000000..4062716898 --- /dev/null +++ b/docs/reference/type-aliases/TableState_All.md @@ -0,0 +1,12 @@ +--- +id: TableState_All +title: TableState_All +--- + +# Type Alias: TableState\_All + +```ts +type TableState_All = Partial; +``` + +Defined in: [types/TableState.ts:74](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/TableState.ts#L74) diff --git a/docs/reference/type-aliases/Table_Core.md b/docs/reference/type-aliases/Table_Core.md new file mode 100644 index 0000000000..905d32b0ae --- /dev/null +++ b/docs/reference/type-aliases/Table_Core.md @@ -0,0 +1,25 @@ +--- +id: Table_Core +title: Table_Core +--- + +# Type Alias: Table\_Core\ + +```ts +type Table_Core = Table_Table & Table_Columns & Table_Rows & Table_RowModels & Table_Headers; +``` + +Defined in: [types/Table.ts:41](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Table.ts#L41) + +The core table object that only includes the core table functionality such as column, header, row, and table APIS. +No features are included. + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/Table_Internal.md b/docs/reference/type-aliases/Table_Internal.md new file mode 100644 index 0000000000..36aa9f7d31 --- /dev/null +++ b/docs/reference/type-aliases/Table_Internal.md @@ -0,0 +1,80 @@ +--- +id: Table_Internal +title: Table_Internal +--- + +# Type Alias: Table\_Internal\ + +```ts +type Table_Internal = Table & object; +``` + +Defined in: [types/Table.ts:111](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/Table.ts#L111) + +## Type Declaration + +### \_rowModelFns + +```ts +_rowModelFns: RowModelFns_All; +``` + +### \_rowModels + +```ts +_rowModels: CachedRowModel_All; +``` + +### baseStore + +```ts +baseStore: Store; +``` + +### initialState + +```ts +initialState: TableState_All; +``` + +### options + +```ts +options: TableOptions_All & object; +``` + +#### Type Declaration + +##### \_rowModels? + +```ts +optional _rowModels: CreateRowModels_All; +``` + +##### initialState? + +```ts +optional initialState: TableState_All; +``` + +##### state? + +```ts +optional state: TableState_All; +``` + +### store + +```ts +store: ReadonlyStore; +``` + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) = `any` diff --git a/docs/reference/type-aliases/Table_RowModels.md b/docs/reference/type-aliases/Table_RowModels.md new file mode 100644 index 0000000000..e57b41133e --- /dev/null +++ b/docs/reference/type-aliases/Table_RowModels.md @@ -0,0 +1,22 @@ +--- +id: Table_RowModels +title: Table_RowModels +--- + +# Type Alias: Table\_RowModels\ + +```ts +type Table_RowModels = Table_RowModels_Core & Table_RowModels_Faceted & Table_RowModels_Filtered & Table_RowModels_Grouped & Table_RowModels_Expanded & Table_RowModels_Paginated & Table_RowModels_Sorted; +``` + +Defined in: [core/row-models/coreRowModelsFeature.types.ts:58](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.types.ts#L58) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) diff --git a/docs/reference/type-aliases/TransformFilterValueFn.md b/docs/reference/type-aliases/TransformFilterValueFn.md new file mode 100644 index 0000000000..c51818af50 --- /dev/null +++ b/docs/reference/type-aliases/TransformFilterValueFn.md @@ -0,0 +1,40 @@ +--- +id: TransformFilterValueFn +title: TransformFilterValueFn +--- + +# Type Alias: TransformFilterValueFn()\ + +```ts +type TransformFilterValueFn = (value, column?) => TValue; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.types.ts:59](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.types.ts#L59) + +## Type Parameters + +### TFeatures + +`TFeatures` *extends* [`TableFeatures`](../interfaces/TableFeatures.md) + +### TData + +`TData` *extends* [`RowData`](RowData.md) + +### TValue + +`TValue` *extends* [`CellData`](CellData.md) = [`CellData`](CellData.md) + +## Parameters + +### value + +`any` + +### column? + +[`Column`](Column.md)\<`TFeatures`, `TData`, `TValue`\> + +## Returns + +`TValue` diff --git a/docs/reference/type-aliases/UnionToIntersection.md b/docs/reference/type-aliases/UnionToIntersection.md new file mode 100644 index 0000000000..f320f56a9f --- /dev/null +++ b/docs/reference/type-aliases/UnionToIntersection.md @@ -0,0 +1,18 @@ +--- +id: UnionToIntersection +title: UnionToIntersection +--- + +# Type Alias: UnionToIntersection\ + +```ts +type UnionToIntersection = T extends any ? (x) => any : never extends (x) => any ? R : never; +``` + +Defined in: [types/type-utils.ts:14](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/type-utils.ts#L14) + +## Type Parameters + +### T + +`T` diff --git a/docs/reference/type-aliases/Updater.md b/docs/reference/type-aliases/Updater.md new file mode 100644 index 0000000000..f0be9f6aeb --- /dev/null +++ b/docs/reference/type-aliases/Updater.md @@ -0,0 +1,18 @@ +--- +id: Updater +title: Updater +--- + +# Type Alias: Updater\ + +```ts +type Updater = T | (old) => T; +``` + +Defined in: [types/type-utils.ts:1](https://github.com/TanStack/table/blob/main/packages/table-core/src/types/type-utils.ts#L1) + +## Type Parameters + +### T + +`T` diff --git a/docs/reference/type-aliases/VisibilityDefaultOptions.md b/docs/reference/type-aliases/VisibilityDefaultOptions.md new file mode 100644 index 0000000000..60b7f43e9b --- /dev/null +++ b/docs/reference/type-aliases/VisibilityDefaultOptions.md @@ -0,0 +1,12 @@ +--- +id: VisibilityDefaultOptions +title: VisibilityDefaultOptions +--- + +# Type Alias: VisibilityDefaultOptions + +```ts +type VisibilityDefaultOptions = Pick; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.types.ts:23](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.types.ts#L23) diff --git a/docs/reference/variables/$internalMemoFnMeta.md b/docs/reference/variables/$internalMemoFnMeta.md new file mode 100644 index 0000000000..c83d60f5ed --- /dev/null +++ b/docs/reference/variables/$internalMemoFnMeta.md @@ -0,0 +1,12 @@ +--- +id: $internalMemoFnMeta +title: $internalMemoFnMeta +--- + +# Variable: $internalMemoFnMeta + +```ts +const $internalMemoFnMeta: typeof $internalMemoFnMeta; +``` + +Defined in: [utils.ts:61](https://github.com/TanStack/table/blob/main/packages/table-core/src/utils.ts#L61) diff --git a/docs/reference/variables/aggregationFn_count.md b/docs/reference/variables/aggregationFn_count.md new file mode 100644 index 0000000000..0e0cda2e76 --- /dev/null +++ b/docs/reference/variables/aggregationFn_count.md @@ -0,0 +1,14 @@ +--- +id: aggregationFn_count +title: aggregationFn_count +--- + +# Variable: aggregationFn\_count + +```ts +const aggregationFn_count: AggregationFn; +``` + +Defined in: [fns/aggregationFns.ts:198](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/aggregationFns.ts#L198) + +Aggregation function for counting the number of rows in a column. diff --git a/docs/reference/variables/aggregationFn_extent.md b/docs/reference/variables/aggregationFn_extent.md new file mode 100644 index 0000000000..0bb994ef84 --- /dev/null +++ b/docs/reference/variables/aggregationFn_extent.md @@ -0,0 +1,14 @@ +--- +id: aggregationFn_extent +title: aggregationFn_extent +--- + +# Variable: aggregationFn\_extent + +```ts +const aggregationFn_extent: AggregationFn; +``` + +Defined in: [fns/aggregationFns.ts:84](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/aggregationFns.ts#L84) + +Aggregation function for finding the extent (min and max) of a column. diff --git a/docs/reference/variables/aggregationFn_max.md b/docs/reference/variables/aggregationFn_max.md new file mode 100644 index 0000000000..443b999581 --- /dev/null +++ b/docs/reference/variables/aggregationFn_max.md @@ -0,0 +1,14 @@ +--- +id: aggregationFn_max +title: aggregationFn_max +--- + +# Variable: aggregationFn\_max + +```ts +const aggregationFn_max: AggregationFn; +``` + +Defined in: [fns/aggregationFns.ts:57](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/aggregationFns.ts#L57) + +Aggregation function for finding the maximum value of a column. diff --git a/docs/reference/variables/aggregationFn_mean.md b/docs/reference/variables/aggregationFn_mean.md new file mode 100644 index 0000000000..321b066014 --- /dev/null +++ b/docs/reference/variables/aggregationFn_mean.md @@ -0,0 +1,14 @@ +--- +id: aggregationFn_mean +title: aggregationFn_mean +--- + +# Variable: aggregationFn\_mean + +```ts +const aggregationFn_mean: AggregationFn; +``` + +Defined in: [fns/aggregationFns.ts:113](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/aggregationFns.ts#L113) + +Aggregation function for finding the mean (average) of a column. diff --git a/docs/reference/variables/aggregationFn_median.md b/docs/reference/variables/aggregationFn_median.md new file mode 100644 index 0000000000..38a7925adb --- /dev/null +++ b/docs/reference/variables/aggregationFn_median.md @@ -0,0 +1,14 @@ +--- +id: aggregationFn_median +title: aggregationFn_median +--- + +# Variable: aggregationFn\_median + +```ts +const aggregationFn_median: AggregationFn; +``` + +Defined in: [fns/aggregationFns.ts:145](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/aggregationFns.ts#L145) + +Aggregation function for finding the median value of a column. diff --git a/docs/reference/variables/aggregationFn_min.md b/docs/reference/variables/aggregationFn_min.md new file mode 100644 index 0000000000..b5ceab3d37 --- /dev/null +++ b/docs/reference/variables/aggregationFn_min.md @@ -0,0 +1,14 @@ +--- +id: aggregationFn_min +title: aggregationFn_min +--- + +# Variable: aggregationFn\_min + +```ts +const aggregationFn_min: AggregationFn; +``` + +Defined in: [fns/aggregationFns.ts:29](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/aggregationFns.ts#L29) + +Aggregation function for finding the minimum value of a column. diff --git a/docs/reference/variables/aggregationFn_sum.md b/docs/reference/variables/aggregationFn_sum.md new file mode 100644 index 0000000000..aeece8ec0a --- /dev/null +++ b/docs/reference/variables/aggregationFn_sum.md @@ -0,0 +1,14 @@ +--- +id: aggregationFn_sum +title: aggregationFn_sum +--- + +# Variable: aggregationFn\_sum + +```ts +const aggregationFn_sum: AggregationFn; +``` + +Defined in: [fns/aggregationFns.ts:10](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/aggregationFns.ts#L10) + +Aggregation function for summing up the values of a column. diff --git a/docs/reference/variables/aggregationFn_unique.md b/docs/reference/variables/aggregationFn_unique.md new file mode 100644 index 0000000000..d04181e153 --- /dev/null +++ b/docs/reference/variables/aggregationFn_unique.md @@ -0,0 +1,14 @@ +--- +id: aggregationFn_unique +title: aggregationFn_unique +--- + +# Variable: aggregationFn\_unique + +```ts +const aggregationFn_unique: AggregationFn; +``` + +Defined in: [fns/aggregationFns.ts:172](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/aggregationFns.ts#L172) + +Aggregation function for finding the unique values of a column. diff --git a/docs/reference/variables/aggregationFn_uniqueCount.md b/docs/reference/variables/aggregationFn_uniqueCount.md new file mode 100644 index 0000000000..f45e125c82 --- /dev/null +++ b/docs/reference/variables/aggregationFn_uniqueCount.md @@ -0,0 +1,14 @@ +--- +id: aggregationFn_uniqueCount +title: aggregationFn_uniqueCount +--- + +# Variable: aggregationFn\_uniqueCount + +```ts +const aggregationFn_uniqueCount: AggregationFn; +``` + +Defined in: [fns/aggregationFns.ts:185](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/aggregationFns.ts#L185) + +Aggregation function for finding the count of unique values of a column. diff --git a/docs/reference/variables/aggregationFns.md b/docs/reference/variables/aggregationFns.md new file mode 100644 index 0000000000..392a7fbc83 --- /dev/null +++ b/docs/reference/variables/aggregationFns.md @@ -0,0 +1,68 @@ +--- +id: aggregationFns +title: aggregationFns +--- + +# Variable: aggregationFns + +```ts +const aggregationFns: object; +``` + +Defined in: [fns/aggregationFns.ts:208](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/aggregationFns.ts#L208) + +## Type Declaration + +### count + +```ts +count: AggregationFn = aggregationFn_count; +``` + +### extent + +```ts +extent: AggregationFn = aggregationFn_extent; +``` + +### max + +```ts +max: AggregationFn = aggregationFn_max; +``` + +### mean + +```ts +mean: AggregationFn = aggregationFn_mean; +``` + +### median + +```ts +median: AggregationFn = aggregationFn_median; +``` + +### min + +```ts +min: AggregationFn = aggregationFn_min; +``` + +### sum + +```ts +sum: AggregationFn = aggregationFn_sum; +``` + +### unique + +```ts +unique: AggregationFn = aggregationFn_unique; +``` + +### uniqueCount + +```ts +uniqueCount: AggregationFn = aggregationFn_uniqueCount; +``` diff --git a/docs/reference/variables/columnFacetingFeature.md b/docs/reference/variables/columnFacetingFeature.md new file mode 100644 index 0000000000..762d001aff --- /dev/null +++ b/docs/reference/variables/columnFacetingFeature.md @@ -0,0 +1,14 @@ +--- +id: columnFacetingFeature +title: columnFacetingFeature +--- + +# Variable: columnFacetingFeature + +```ts +const columnFacetingFeature: TableFeature>; +``` + +Defined in: [features/column-faceting/columnFacetingFeature.ts:112](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-faceting/columnFacetingFeature.ts#L112) + +The Column Faceting feature adds column faceting APIs to the column objects. diff --git a/docs/reference/variables/columnFilteringFeature.md b/docs/reference/variables/columnFilteringFeature.md new file mode 100644 index 0000000000..31cd19216c --- /dev/null +++ b/docs/reference/variables/columnFilteringFeature.md @@ -0,0 +1,15 @@ +--- +id: columnFilteringFeature +title: columnFilteringFeature +--- + +# Variable: columnFilteringFeature + +```ts +const columnFilteringFeature: TableFeature>; +``` + +Defined in: [features/column-filtering/columnFilteringFeature.ts:121](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-filtering/columnFilteringFeature.ts#L121) + +The Column Filtering feature adds column filtering state and APIs to the table, row, and column objects. +**Note:** This does not include Global Filtering. The globalFilteringFeature feature has been split out into its own standalone feature. diff --git a/docs/reference/variables/columnGroupingFeature.md b/docs/reference/variables/columnGroupingFeature.md new file mode 100644 index 0000000000..976efc4a12 --- /dev/null +++ b/docs/reference/variables/columnGroupingFeature.md @@ -0,0 +1,14 @@ +--- +id: columnGroupingFeature +title: columnGroupingFeature +--- + +# Variable: columnGroupingFeature + +```ts +const columnGroupingFeature: TableFeature>; +``` + +Defined in: [features/column-grouping/columnGroupingFeature.ts:151](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-grouping/columnGroupingFeature.ts#L151) + +The (Column) Grouping feature adds column grouping state and APIs to the table, row, column, and cell objects. diff --git a/docs/reference/variables/columnOrderingFeature.md b/docs/reference/variables/columnOrderingFeature.md new file mode 100644 index 0000000000..d55cd22c99 --- /dev/null +++ b/docs/reference/variables/columnOrderingFeature.md @@ -0,0 +1,14 @@ +--- +id: columnOrderingFeature +title: columnOrderingFeature +--- + +# Variable: columnOrderingFeature + +```ts +const columnOrderingFeature: TableFeature>; +``` + +Defined in: [features/column-ordering/columnOrderingFeature.ts:96](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-ordering/columnOrderingFeature.ts#L96) + +The Column Ordering feature adds column ordering state and APIs to the table and column objects. diff --git a/docs/reference/variables/columnPinningFeature.md b/docs/reference/variables/columnPinningFeature.md new file mode 100644 index 0000000000..3cebea02a9 --- /dev/null +++ b/docs/reference/variables/columnPinningFeature.md @@ -0,0 +1,14 @@ +--- +id: columnPinningFeature +title: columnPinningFeature +--- + +# Variable: columnPinningFeature + +```ts +const columnPinningFeature: TableFeature>; +``` + +Defined in: [features/column-pinning/columnPinningFeature.ts:324](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-pinning/columnPinningFeature.ts#L324) + +The Column Pinning feature adds column pinning state and APIs to the table, row, and column objects. diff --git a/docs/reference/variables/columnResizingFeature.md b/docs/reference/variables/columnResizingFeature.md new file mode 100644 index 0000000000..f847f2fdb3 --- /dev/null +++ b/docs/reference/variables/columnResizingFeature.md @@ -0,0 +1,15 @@ +--- +id: columnResizingFeature +title: columnResizingFeature +--- + +# Variable: columnResizingFeature + +```ts +const columnResizingFeature: TableFeature>; +``` + +Defined in: [features/column-resizing/columnResizingFeature.ts:92](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-resizing/columnResizingFeature.ts#L92) + +The Column Resizing feature adds column resizing state and APIs to the table and column objects. +**Note:** This is dependent on the Column Sizing feature. diff --git a/docs/reference/variables/columnSizingFeature.md b/docs/reference/variables/columnSizingFeature.md new file mode 100644 index 0000000000..88fd49ca3d --- /dev/null +++ b/docs/reference/variables/columnSizingFeature.md @@ -0,0 +1,15 @@ +--- +id: columnSizingFeature +title: columnSizingFeature +--- + +# Variable: columnSizingFeature + +```ts +const columnSizingFeature: TableFeature>; +``` + +Defined in: [features/column-sizing/columnSizingFeature.ts:146](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-sizing/columnSizingFeature.ts#L146) + +The Column Sizing feature adds column sizing state and APIs to the table, header, and column objects. +**Note:** This does not include column resizing. The columnResizingFeature feature has been split out into its own standalone feature. diff --git a/docs/reference/variables/columnVisibilityFeature.md b/docs/reference/variables/columnVisibilityFeature.md new file mode 100644 index 0000000000..765e55cfb2 --- /dev/null +++ b/docs/reference/variables/columnVisibilityFeature.md @@ -0,0 +1,14 @@ +--- +id: columnVisibilityFeature +title: columnVisibilityFeature +--- + +# Variable: columnVisibilityFeature + +```ts +const columnVisibilityFeature: TableFeature>; +``` + +Defined in: [features/column-visibility/columnVisibilityFeature.ts:155](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/column-visibility/columnVisibilityFeature.ts#L155) + +The Column Visibility feature adds column visibility state and APIs to the table, row, and column objects. diff --git a/docs/reference/variables/coreCellsFeature.md b/docs/reference/variables/coreCellsFeature.md new file mode 100644 index 0000000000..6b3d4f07fc --- /dev/null +++ b/docs/reference/variables/coreCellsFeature.md @@ -0,0 +1,14 @@ +--- +id: coreCellsFeature +title: coreCellsFeature +--- + +# Variable: coreCellsFeature + +```ts +const coreCellsFeature: TableFeature>; +``` + +Defined in: [core/cells/coreCellsFeature.ts:44](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/cells/coreCellsFeature.ts#L44) + +The Core Cells feature provides the core cell functionality. diff --git a/docs/reference/variables/coreColumnsFeature.md b/docs/reference/variables/coreColumnsFeature.md new file mode 100644 index 0000000000..469959cf1e --- /dev/null +++ b/docs/reference/variables/coreColumnsFeature.md @@ -0,0 +1,14 @@ +--- +id: coreColumnsFeature +title: coreColumnsFeature +--- + +# Variable: coreColumnsFeature + +```ts +const coreColumnsFeature: TableFeature>; +``` + +Defined in: [core/columns/coreColumnsFeature.ts:90](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/columns/coreColumnsFeature.ts#L90) + +The Core Columns feature provides the core column functionality. diff --git a/docs/reference/variables/coreFeatures.md b/docs/reference/variables/coreFeatures.md new file mode 100644 index 0000000000..281500dbe2 --- /dev/null +++ b/docs/reference/variables/coreFeatures.md @@ -0,0 +1,12 @@ +--- +id: coreFeatures +title: coreFeatures +--- + +# Variable: coreFeatures + +```ts +const coreFeatures: CoreFeatures; +``` + +Defined in: [core/coreFeatures.ts:17](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/coreFeatures.ts#L17) diff --git a/docs/reference/variables/coreHeadersFeature.md b/docs/reference/variables/coreHeadersFeature.md new file mode 100644 index 0000000000..95f38f5015 --- /dev/null +++ b/docs/reference/variables/coreHeadersFeature.md @@ -0,0 +1,14 @@ +--- +id: coreHeadersFeature +title: coreHeadersFeature +--- + +# Variable: coreHeadersFeature + +```ts +const coreHeadersFeature: TableFeature>; +``` + +Defined in: [core/headers/coreHeadersFeature.ts:98](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/headers/coreHeadersFeature.ts#L98) + +The Core Headers feature provides the core header functionality. diff --git a/docs/reference/variables/coreRowModelsFeature.md b/docs/reference/variables/coreRowModelsFeature.md new file mode 100644 index 0000000000..6a897fb13e --- /dev/null +++ b/docs/reference/variables/coreRowModelsFeature.md @@ -0,0 +1,14 @@ +--- +id: coreRowModelsFeature +title: coreRowModelsFeature +--- + +# Variable: coreRowModelsFeature + +```ts +const coreRowModelsFeature: TableFeature>; +``` + +Defined in: [core/row-models/coreRowModelsFeature.ts:78](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/row-models/coreRowModelsFeature.ts#L78) + +The Core Row Models feature provides the core row model functionality. diff --git a/docs/reference/variables/coreRowsFeature.md b/docs/reference/variables/coreRowsFeature.md new file mode 100644 index 0000000000..119f8eae33 --- /dev/null +++ b/docs/reference/variables/coreRowsFeature.md @@ -0,0 +1,14 @@ +--- +id: coreRowsFeature +title: coreRowsFeature +--- + +# Variable: coreRowsFeature + +```ts +const coreRowsFeature: TableFeature>; +``` + +Defined in: [core/rows/coreRowsFeature.ts:84](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/rows/coreRowsFeature.ts#L84) + +The Core Rows feature provides the core row functionality. diff --git a/docs/reference/variables/coreTablesFeature.md b/docs/reference/variables/coreTablesFeature.md new file mode 100644 index 0000000000..6fbe70b188 --- /dev/null +++ b/docs/reference/variables/coreTablesFeature.md @@ -0,0 +1,14 @@ +--- +id: coreTablesFeature +title: coreTablesFeature +--- + +# Variable: coreTablesFeature + +```ts +const coreTablesFeature: TableFeature>; +``` + +Defined in: [core/table/coreTablesFeature.ts:36](https://github.com/TanStack/table/blob/main/packages/table-core/src/core/table/coreTablesFeature.ts#L36) + +The Core Tables feature provides the core table functionality for handling state and options. diff --git a/docs/reference/variables/filterFn_arrHas.md b/docs/reference/variables/filterFn_arrHas.md new file mode 100644 index 0000000000..09c7f6330e --- /dev/null +++ b/docs/reference/variables/filterFn_arrHas.md @@ -0,0 +1,14 @@ +--- +id: filterFn_arrHas +title: filterFn_arrHas +--- + +# Variable: filterFn\_arrHas + +```ts +const filterFn_arrHas: FilterFn; +``` + +Defined in: [fns/filterFns.ts:287](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L287) + +Filter function for checking if an array has a given value. diff --git a/docs/reference/variables/filterFn_arrIncludes.md b/docs/reference/variables/filterFn_arrIncludes.md new file mode 100644 index 0000000000..7ef63136e6 --- /dev/null +++ b/docs/reference/variables/filterFn_arrIncludes.md @@ -0,0 +1,14 @@ +--- +id: filterFn_arrIncludes +title: filterFn_arrIncludes +--- + +# Variable: filterFn\_arrIncludes + +```ts +const filterFn_arrIncludes: FilterFn; +``` + +Defined in: [fns/filterFns.ts:301](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L301) + +Filter function for checking if an array includes a given value. diff --git a/docs/reference/variables/filterFn_arrIncludesAll.md b/docs/reference/variables/filterFn_arrIncludesAll.md new file mode 100644 index 0000000000..ba14ab386c --- /dev/null +++ b/docs/reference/variables/filterFn_arrIncludesAll.md @@ -0,0 +1,14 @@ +--- +id: filterFn_arrIncludesAll +title: filterFn_arrIncludesAll +--- + +# Variable: filterFn\_arrIncludesAll + +```ts +const filterFn_arrIncludesAll: FilterFn; +``` + +Defined in: [fns/filterFns.ts:321](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L321) + +Filter function for checking if an array includes all of the given values. diff --git a/docs/reference/variables/filterFn_arrIncludesSome.md b/docs/reference/variables/filterFn_arrIncludesSome.md new file mode 100644 index 0000000000..3f583c3da2 --- /dev/null +++ b/docs/reference/variables/filterFn_arrIncludesSome.md @@ -0,0 +1,14 @@ +--- +id: filterFn_arrIncludesSome +title: filterFn_arrIncludesSome +--- + +# Variable: filterFn\_arrIncludesSome + +```ts +const filterFn_arrIncludesSome: FilterFn; +``` + +Defined in: [fns/filterFns.ts:340](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L340) + +Filter function for checking if an array includes any of the given values. diff --git a/docs/reference/variables/filterFn_equals.md b/docs/reference/variables/filterFn_equals.md new file mode 100644 index 0000000000..ff3f1adaf8 --- /dev/null +++ b/docs/reference/variables/filterFn_equals.md @@ -0,0 +1,14 @@ +--- +id: filterFn_equals +title: filterFn_equals +--- + +# Variable: filterFn\_equals + +```ts +const filterFn_equals: FilterFn; +``` + +Defined in: [fns/filterFns.ts:11](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L11) + +Filter function for checking if a value is exactly equal to a given value. (JS === comparison) diff --git a/docs/reference/variables/filterFn_equalsString.md b/docs/reference/variables/filterFn_equalsString.md new file mode 100644 index 0000000000..f7feb8f0ce --- /dev/null +++ b/docs/reference/variables/filterFn_equalsString.md @@ -0,0 +1,14 @@ +--- +id: filterFn_equalsString +title: filterFn_equalsString +--- + +# Variable: filterFn\_equalsString + +```ts +const filterFn_equalsString: FilterFn; +``` + +Defined in: [fns/filterFns.ts:85](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L85) + +Filter function for checking if a string is exactly equal to a given string. (Non-case-sensitive) diff --git a/docs/reference/variables/filterFn_equalsStringSensitive.md b/docs/reference/variables/filterFn_equalsStringSensitive.md new file mode 100644 index 0000000000..2dd960758c --- /dev/null +++ b/docs/reference/variables/filterFn_equalsStringSensitive.md @@ -0,0 +1,14 @@ +--- +id: filterFn_equalsStringSensitive +title: filterFn_equalsStringSensitive +--- + +# Variable: filterFn\_equalsStringSensitive + +```ts +const filterFn_equalsStringSensitive: FilterFn; +``` + +Defined in: [fns/filterFns.ts:104](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L104) + +Filter function for checking if a string is exactly equal to a given string. (Case-sensitive) diff --git a/docs/reference/variables/filterFn_greaterThan.md b/docs/reference/variables/filterFn_greaterThan.md new file mode 100644 index 0000000000..c1a86a2c1d --- /dev/null +++ b/docs/reference/variables/filterFn_greaterThan.md @@ -0,0 +1,14 @@ +--- +id: filterFn_greaterThan +title: filterFn_greaterThan +--- + +# Variable: filterFn\_greaterThan + +```ts +const filterFn_greaterThan: FilterFn; +``` + +Defined in: [fns/filterFns.ts:122](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L122) + +Filter function for checking if a number is greater than a given number. diff --git a/docs/reference/variables/filterFn_greaterThanOrEqualTo.md b/docs/reference/variables/filterFn_greaterThanOrEqualTo.md new file mode 100644 index 0000000000..513c1e07cc --- /dev/null +++ b/docs/reference/variables/filterFn_greaterThanOrEqualTo.md @@ -0,0 +1,14 @@ +--- +id: filterFn_greaterThanOrEqualTo +title: filterFn_greaterThanOrEqualTo +--- + +# Variable: filterFn\_greaterThanOrEqualTo + +```ts +const filterFn_greaterThanOrEqualTo: FilterFn; +``` + +Defined in: [fns/filterFns.ts:149](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L149) + +Filter function for checking if a number is greater than or equal to a given number. diff --git a/docs/reference/variables/filterFn_inNumberRange.md b/docs/reference/variables/filterFn_inNumberRange.md new file mode 100644 index 0000000000..363992954d --- /dev/null +++ b/docs/reference/variables/filterFn_inNumberRange.md @@ -0,0 +1,14 @@ +--- +id: filterFn_inNumberRange +title: filterFn_inNumberRange +--- + +# Variable: filterFn\_inNumberRange + +```ts +const filterFn_inNumberRange: FilterFn; +``` + +Defined in: [fns/filterFns.ts:244](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L244) + +Filter function for checking if a number is within a given range. diff --git a/docs/reference/variables/filterFn_includesString.md b/docs/reference/variables/filterFn_includesString.md new file mode 100644 index 0000000000..ac378ce25d --- /dev/null +++ b/docs/reference/variables/filterFn_includesString.md @@ -0,0 +1,14 @@ +--- +id: filterFn_includesString +title: filterFn_includesString +--- + +# Variable: filterFn\_includesString + +```ts +const filterFn_includesString: FilterFn; +``` + +Defined in: [fns/filterFns.ts:63](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L63) + +Filter function for checking if a string includes a given substring. (Non-case-sensitive) diff --git a/docs/reference/variables/filterFn_includesStringSensitive.md b/docs/reference/variables/filterFn_includesStringSensitive.md new file mode 100644 index 0000000000..244397153f --- /dev/null +++ b/docs/reference/variables/filterFn_includesStringSensitive.md @@ -0,0 +1,14 @@ +--- +id: filterFn_includesStringSensitive +title: filterFn_includesStringSensitive +--- + +# Variable: filterFn\_includesStringSensitive + +```ts +const filterFn_includesStringSensitive: FilterFn; +``` + +Defined in: [fns/filterFns.ts:45](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L45) + +Filter function for checking if a string includes a given substring. (Case-sensitive) diff --git a/docs/reference/variables/filterFn_lessThan.md b/docs/reference/variables/filterFn_lessThan.md new file mode 100644 index 0000000000..3917d74e60 --- /dev/null +++ b/docs/reference/variables/filterFn_lessThan.md @@ -0,0 +1,14 @@ +--- +id: filterFn_lessThan +title: filterFn_lessThan +--- + +# Variable: filterFn\_lessThan + +```ts +const filterFn_lessThan: FilterFn; +``` + +Defined in: [fns/filterFns.ts:168](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L168) + +Filter function for checking if a number is less than a given number. diff --git a/docs/reference/variables/filterFn_lessThanOrEqualTo.md b/docs/reference/variables/filterFn_lessThanOrEqualTo.md new file mode 100644 index 0000000000..7febfe8575 --- /dev/null +++ b/docs/reference/variables/filterFn_lessThanOrEqualTo.md @@ -0,0 +1,14 @@ +--- +id: filterFn_lessThanOrEqualTo +title: filterFn_lessThanOrEqualTo +--- + +# Variable: filterFn\_lessThanOrEqualTo + +```ts +const filterFn_lessThanOrEqualTo: FilterFn; +``` + +Defined in: [fns/filterFns.ts:184](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L184) + +Filter function for checking if a number is less than or equal to a given number. diff --git a/docs/reference/variables/filterFn_weakEquals.md b/docs/reference/variables/filterFn_weakEquals.md new file mode 100644 index 0000000000..44c176be0a --- /dev/null +++ b/docs/reference/variables/filterFn_weakEquals.md @@ -0,0 +1,14 @@ +--- +id: filterFn_weakEquals +title: filterFn_weakEquals +--- + +# Variable: filterFn\_weakEquals + +```ts +const filterFn_weakEquals: FilterFn; +``` + +Defined in: [fns/filterFns.ts:27](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L27) + +Filter function for checking if a value is weakly equal to a given value. (JS == comparison) diff --git a/docs/reference/variables/filterFns.md b/docs/reference/variables/filterFns.md new file mode 100644 index 0000000000..f2aed593e9 --- /dev/null +++ b/docs/reference/variables/filterFns.md @@ -0,0 +1,86 @@ +--- +id: filterFns +title: filterFns +--- + +# Variable: filterFns + +```ts +const filterFns: object; +``` + +Defined in: [fns/filterFns.ts:358](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/filterFns.ts#L358) + +## Type Declaration + +### arrHas + +```ts +arrHas: FilterFn = filterFn_arrHas; +``` + +### arrIncludes + +```ts +arrIncludes: FilterFn = filterFn_arrIncludes; +``` + +### arrIncludesAll + +```ts +arrIncludesAll: FilterFn = filterFn_arrIncludesAll; +``` + +### arrIncludesSome + +```ts +arrIncludesSome: FilterFn = filterFn_arrIncludesSome; +``` + +### between + +```ts +between: FilterFn = filterFn_between; +``` + +### betweenInclusive + +```ts +betweenInclusive: FilterFn = filterFn_betweenInclusive; +``` + +### equals + +```ts +equals: FilterFn = filterFn_equals; +``` + +### equalsString + +```ts +equalsString: FilterFn = filterFn_equalsString; +``` + +### includesString + +```ts +includesString: FilterFn = filterFn_includesString; +``` + +### includesStringSensitive + +```ts +includesStringSensitive: FilterFn = filterFn_includesStringSensitive; +``` + +### inNumberRange + +```ts +inNumberRange: FilterFn = filterFn_inNumberRange; +``` + +### weakEquals + +```ts +weakEquals: FilterFn = filterFn_weakEquals; +``` diff --git a/docs/reference/variables/globalFilteringFeature.md b/docs/reference/variables/globalFilteringFeature.md new file mode 100644 index 0000000000..e2932ee79b --- /dev/null +++ b/docs/reference/variables/globalFilteringFeature.md @@ -0,0 +1,15 @@ +--- +id: globalFilteringFeature +title: globalFilteringFeature +--- + +# Variable: globalFilteringFeature + +```ts +const globalFilteringFeature: TableFeature>; +``` + +Defined in: [features/global-filtering/globalFilteringFeature.ts:92](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/global-filtering/globalFilteringFeature.ts#L92) + +The Global Filtering feature adds global filtering state and APIs to the table and column objects. +**Note:** This is dependent on the columnFilteringFeature feature. diff --git a/docs/reference/variables/reSplitAlphaNumeric.md b/docs/reference/variables/reSplitAlphaNumeric.md new file mode 100644 index 0000000000..0eb55d9773 --- /dev/null +++ b/docs/reference/variables/reSplitAlphaNumeric.md @@ -0,0 +1,12 @@ +--- +id: reSplitAlphaNumeric +title: reSplitAlphaNumeric +--- + +# Variable: reSplitAlphaNumeric + +```ts +const reSplitAlphaNumeric: RegExp; +``` + +Defined in: [fns/sortFns.ts:6](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/sortFns.ts#L6) diff --git a/docs/reference/variables/rowExpandingFeature.md b/docs/reference/variables/rowExpandingFeature.md new file mode 100644 index 0000000000..622b01793c --- /dev/null +++ b/docs/reference/variables/rowExpandingFeature.md @@ -0,0 +1,14 @@ +--- +id: rowExpandingFeature +title: rowExpandingFeature +--- + +# Variable: rowExpandingFeature + +```ts +const rowExpandingFeature: TableFeature>; +``` + +Defined in: [features/row-expanding/rowExpandingFeature.ts:122](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-expanding/rowExpandingFeature.ts#L122) + +The Row Expanding feature adds row expanding state and APIs to the table and row objects. diff --git a/docs/reference/variables/rowPaginationFeature.md b/docs/reference/variables/rowPaginationFeature.md new file mode 100644 index 0000000000..4ef8e48c85 --- /dev/null +++ b/docs/reference/variables/rowPaginationFeature.md @@ -0,0 +1,14 @@ +--- +id: rowPaginationFeature +title: rowPaginationFeature +--- + +# Variable: rowPaginationFeature + +```ts +const rowPaginationFeature: TableFeature>; +``` + +Defined in: [features/row-pagination/rowPaginationFeature.ts:121](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pagination/rowPaginationFeature.ts#L121) + +The (Row) Pagination feature adds pagination state and APIs to the table object. diff --git a/docs/reference/variables/rowPinningFeature.md b/docs/reference/variables/rowPinningFeature.md new file mode 100644 index 0000000000..29549d5254 --- /dev/null +++ b/docs/reference/variables/rowPinningFeature.md @@ -0,0 +1,14 @@ +--- +id: rowPinningFeature +title: rowPinningFeature +--- + +# Variable: rowPinningFeature + +```ts +const rowPinningFeature: TableFeature>; +``` + +Defined in: [features/row-pinning/rowPinningFeature.ts:121](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-pinning/rowPinningFeature.ts#L121) + +The Row Pinning feature adds row pinning state and APIs to the table and row objects. diff --git a/docs/reference/variables/rowSelectionFeature.md b/docs/reference/variables/rowSelectionFeature.md new file mode 100644 index 0000000000..7e19f680a0 --- /dev/null +++ b/docs/reference/variables/rowSelectionFeature.md @@ -0,0 +1,14 @@ +--- +id: rowSelectionFeature +title: rowSelectionFeature +--- + +# Variable: rowSelectionFeature + +```ts +const rowSelectionFeature: TableFeature>; +``` + +Defined in: [features/row-selection/rowSelectionFeature.ts:164](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-selection/rowSelectionFeature.ts#L164) + +The Row Selection feature adds row selection state and APIs to the table and row objects. diff --git a/docs/reference/variables/rowSortingFeature.md b/docs/reference/variables/rowSortingFeature.md new file mode 100644 index 0000000000..a929094ad3 --- /dev/null +++ b/docs/reference/variables/rowSortingFeature.md @@ -0,0 +1,14 @@ +--- +id: rowSortingFeature +title: rowSortingFeature +--- + +# Variable: rowSortingFeature + +```ts +const rowSortingFeature: TableFeature>; +``` + +Defined in: [features/row-sorting/rowSortingFeature.ts:136](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/row-sorting/rowSortingFeature.ts#L136) + +The (Row) Sorting feature adds sorting state and APIs to the table and column objects. diff --git a/docs/reference/variables/sortFn_alphanumeric.md b/docs/reference/variables/sortFn_alphanumeric.md new file mode 100644 index 0000000000..f08578160f --- /dev/null +++ b/docs/reference/variables/sortFn_alphanumeric.md @@ -0,0 +1,12 @@ +--- +id: sortFn_alphanumeric +title: sortFn_alphanumeric +--- + +# Variable: sortFn\_alphanumeric + +```ts +const sortFn_alphanumeric: SortFn; +``` + +Defined in: [fns/sortFns.ts:8](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/sortFns.ts#L8) diff --git a/docs/reference/variables/sortFn_alphanumericCaseSensitive.md b/docs/reference/variables/sortFn_alphanumericCaseSensitive.md new file mode 100644 index 0000000000..fca198b9c8 --- /dev/null +++ b/docs/reference/variables/sortFn_alphanumericCaseSensitive.md @@ -0,0 +1,12 @@ +--- +id: sortFn_alphanumericCaseSensitive +title: sortFn_alphanumericCaseSensitive +--- + +# Variable: sortFn\_alphanumericCaseSensitive + +```ts +const sortFn_alphanumericCaseSensitive: SortFn; +``` + +Defined in: [fns/sortFns.ts:22](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/sortFns.ts#L22) diff --git a/docs/reference/variables/sortFn_basic.md b/docs/reference/variables/sortFn_basic.md new file mode 100644 index 0000000000..23254748e1 --- /dev/null +++ b/docs/reference/variables/sortFn_basic.md @@ -0,0 +1,12 @@ +--- +id: sortFn_basic +title: sortFn_basic +--- + +# Variable: sortFn\_basic + +```ts +const sortFn_basic: SortFn; +``` + +Defined in: [fns/sortFns.ts:85](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/sortFns.ts#L85) diff --git a/docs/reference/variables/sortFn_datetime.md b/docs/reference/variables/sortFn_datetime.md new file mode 100644 index 0000000000..bc6db999c2 --- /dev/null +++ b/docs/reference/variables/sortFn_datetime.md @@ -0,0 +1,12 @@ +--- +id: sortFn_datetime +title: sortFn_datetime +--- + +# Variable: sortFn\_datetime + +```ts +const sortFn_datetime: SortFn; +``` + +Defined in: [fns/sortFns.ts:68](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/sortFns.ts#L68) diff --git a/docs/reference/variables/sortFn_text.md b/docs/reference/variables/sortFn_text.md new file mode 100644 index 0000000000..c8489ca808 --- /dev/null +++ b/docs/reference/variables/sortFn_text.md @@ -0,0 +1,12 @@ +--- +id: sortFn_text +title: sortFn_text +--- + +# Variable: sortFn\_text + +```ts +const sortFn_text: SortFn; +``` + +Defined in: [fns/sortFns.ts:38](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/sortFns.ts#L38) diff --git a/docs/reference/variables/sortFn_textCaseSensitive.md b/docs/reference/variables/sortFn_textCaseSensitive.md new file mode 100644 index 0000000000..9ae4279f4d --- /dev/null +++ b/docs/reference/variables/sortFn_textCaseSensitive.md @@ -0,0 +1,12 @@ +--- +id: sortFn_textCaseSensitive +title: sortFn_textCaseSensitive +--- + +# Variable: sortFn\_textCaseSensitive + +```ts +const sortFn_textCaseSensitive: SortFn; +``` + +Defined in: [fns/sortFns.ts:54](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/sortFns.ts#L54) diff --git a/docs/reference/variables/sortFns.md b/docs/reference/variables/sortFns.md new file mode 100644 index 0000000000..7a8413794e --- /dev/null +++ b/docs/reference/variables/sortFns.md @@ -0,0 +1,50 @@ +--- +id: sortFns +title: sortFns +--- + +# Variable: sortFns + +```ts +const sortFns: object; +``` + +Defined in: [fns/sortFns.ts:164](https://github.com/TanStack/table/blob/main/packages/table-core/src/fns/sortFns.ts#L164) + +## Type Declaration + +### alphanumeric + +```ts +alphanumeric: SortFn = sortFn_alphanumeric; +``` + +### alphanumericCaseSensitive + +```ts +alphanumericCaseSensitive: SortFn = sortFn_alphanumericCaseSensitive; +``` + +### basic + +```ts +basic: SortFn = sortFn_basic; +``` + +### datetime + +```ts +datetime: SortFn = sortFn_datetime; +``` + +### text + +```ts +text: SortFn = sortFn_text; +``` + +### textCaseSensitive + +```ts +textCaseSensitive: SortFn = sortFn_textCaseSensitive; +``` diff --git a/docs/reference/variables/stockFeatures.md b/docs/reference/variables/stockFeatures.md new file mode 100644 index 0000000000..5e4b24bffd --- /dev/null +++ b/docs/reference/variables/stockFeatures.md @@ -0,0 +1,12 @@ +--- +id: stockFeatures +title: stockFeatures +--- + +# Variable: stockFeatures + +```ts +const stockFeatures: StockFeatures; +``` + +Defined in: [features/stockFeatures.ts:33](https://github.com/TanStack/table/blob/main/packages/table-core/src/features/stockFeatures.ts#L33) diff --git a/docs/src/App.js b/docs/src/App.js deleted file mode 100644 index 55afe166a5..0000000000 --- a/docs/src/App.js +++ /dev/null @@ -1,116 +0,0 @@ -/* eslint-disable */ - -import React from 'react' -// -import ReactStory, { defaultProps } from 'react-story' -import CodeSandbox from './CodeSandbox.js' -import './stories/utils/prism.css' -import '../../react-table.css' - -import Readme from './stories/Readme.js' -import HOCReadme from './stories/HOCReadme.js' - -// import Test from './stories/test.js' - -// import Tester from './examples/expander'; - -const stories = [ - { name: 'Readme', component: Readme }, - { name: 'HOC Readme', component: HOCReadme }, - - // { name: 'Tester', component: Test }, - { name: 'Simple Table', component: CodeSandbox('X6npLXPRW') }, - { - name: 'Cell Renderers & Custom Components', - component: CodeSandbox('OyRL04Z4Y'), - }, - { name: 'Default Sorting', component: CodeSandbox('gLwmmjzA3') }, - { - name: 'Custom Sorting', - component: CodeSandbox('VGx67J35'), - }, - { name: 'Custom Column Widths', component: CodeSandbox('o2OORXNXN') }, - { name: 'Custom Component Props', component: CodeSandbox('nZW3L0wp4') }, - { name: 'Server-side Data', component: CodeSandbox('wjrn8wy3R') }, - { name: 'Sub Components', component: CodeSandbox('n2gqAxl7') }, - { name: 'Pivoting & Aggregation', component: CodeSandbox('oNY9z8xN') }, - { - name: 'Pivoting & Aggregation w/ Sub Components', - component: CodeSandbox('p0kEVBgQ'), - }, - { - name: '100k Rows w/ Pivoting & Sub Components', - component: CodeSandbox('DRmKj0XyK'), - }, - { name: 'Pivoting Options', component: CodeSandbox('kZKmNBK6r') }, - { name: 'Functional Rendering', component: CodeSandbox('VPZ0Bzv8X') }, - { - name: 'Custom Expander Position', - component: CodeSandbox('1jj2XrPEV'), - }, - { name: 'Custom "No Data" Text', component: CodeSandbox('RgRpRDv80') }, - { name: 'Footers', component: CodeSandbox('KOqQXn3p8') }, - { name: 'Custom Filtering', component: CodeSandbox('5Eyxxxyx') }, - { name: 'Controlled Component', component: CodeSandbox('r7XEZRK2') }, - { name: 'Editable Table', component: CodeSandbox('n5r19gzQP') }, - { - name: 'Fixed Header w/ Vertical Scroll', - component: CodeSandbox('7LY0gjA8O'), - }, - { - name: 'Multiple Pagers (Top and Bottom)', - component: CodeSandbox('VEZ8OgvX'), - }, - { name: 'Tree Table (HOC)', component: CodeSandbox('lxmr4wynzq') }, - { name: 'Select Table (HOC)', component: CodeSandbox('7yq5ylw09j') }, - { name: 'Select Tree Table (HOC)', component: CodeSandbox('2p7jp4klwp') }, -] - -export default class App extends React.Component { - render () { - return ( - - - - React Table Logo - -
- } - stories={stories} - /> - ) - } -} diff --git a/docs/src/CodeSandbox.js b/docs/src/CodeSandbox.js deleted file mode 100644 index d540eae7cc..0000000000 --- a/docs/src/CodeSandbox.js +++ /dev/null @@ -1,22 +0,0 @@ -import React from 'react' - -export default id => () => { - return ( -