Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
Signed-off-by: Andrew Stein <[email protected]>
  • Loading branch information
texodus committed Jan 14, 2025
1 parent 7c134b3 commit f67c111
Show file tree
Hide file tree
Showing 170 changed files with 7,907 additions and 3,894 deletions.
1 change: 0 additions & 1 deletion .cargo/config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ rustflags = ["-C", "target-feature=+crt-static", "--cfg=web_sys_unstable_apis"]
[target.x86_64-pc-windows-msvc]
rustflags = ["-C", "target-feature=+crt-static", "--cfg=web_sys_unstable_apis"]


[future-incompat-report]
frequency = 'never'

Expand Down
8 changes: 0 additions & 8 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -168,8 +168,6 @@ jobs:
packages/perspective-viewer-d3fc/dist
packages/perspective-viewer-datagrid/dist
packages/perspective-viewer-openlayers/dist
packages/perspective-esbuild-plugin/dist
packages/perspective-webpack-plugin/dist
packages/perspective-cli/dist
packages/perspective-workspace/dist
Expand Down Expand Up @@ -947,12 +945,6 @@ jobs:
- run: pnpm pack --pack-destination=../..
working-directory: ./packages/perspective-cli

- run: pnpm pack --pack-destination=../..
working-directory: ./packages/perspective-webpack-plugin

- run: pnpm pack --pack-destination=../..
working-directory: ./packages/perspective-esbuild-plugin

- run: pnpm pack --pack-destination=../..
working-directory: ./packages/perspective-jupyterlab

Expand Down
20 changes: 18 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -48,3 +48,9 @@ strip = true

[patch.crates-io]
simd-adler32 = { git = "https://github.com/mcountryman/simd-adler32.git", rev = "140cde033e8b9a12d4de840648c65ccd5320bcc5" }
perspective-client = { path = "rust/perspective-client" }
perspective-server = { path = "rust/perspective-server" }
perspective-js = { path = "rust/perspective-js" }
perspective = { path = "rust/perspective" }
perspective-viewer = { path = "rust/perspective-viewer" }
perspective-python = { path = "rust/perspective-python" }
40 changes: 14 additions & 26 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
<br />
<a href="https://github.com/finos/perspective/blob/master/docs/static/svg/perspective-logo-light.svg?raw=true#gh-light-mode-only"><img src="https://github.com/finos/perspective/raw/master/docs/static/svg/perspective-logo-light.svg?raw=true#gh-light-mode-only" alt="Perspective" width="260"></a>
<a href="https://github.com/finos/perspective/blob/master/docs/static/svg/perspective-logo-dark.svg?raw=true#gh-dark-mode-only"><img src="https://github.com/finos/perspective/raw/master/docs/static/svg/perspective-logo-dark.svg?raw=true#gh-dark-mode-only" alt="Perspective" width="260"></a>
<a href="https://perspective.finos.org">
<picture>
<source media="(prefers-color-scheme: dark)" srcset="https://github.com/finos/perspective/raw/master/docs/static/svg/perspective-logo-dark.svg?raw=true">
<img width="260" src="https://github.com/finos/perspective/raw/master/docs/static/svg/perspective-logo-light.svg?raw=true">
</picture>
</a>
<br/><br/>

[![Build Status](https://img.shields.io/github/actions/workflow/status/finos/perspective/build.yaml?event=push&style=for-the-badge)](https://github.com/finos/perspective/actions/workflows/build.yaml)
Expand All @@ -13,8 +17,7 @@
Perspective is an <i>interactive</i> analytics and data visualization component,
which is especially well-suited for <i>large</i> and/or <i>streaming</i>
datasets. Use it to create user-configurable reports, dashboards, notebooks and
applications, then deploy stand-alone in the browser, or in concert with Python
and/or [Jupyterlab](https://jupyterlab.readthedocs.io/en/stable/).
applications.

### Features

Expand All @@ -28,35 +31,20 @@ and/or [Jupyterlab](https://jupyterlab.readthedocs.io/en/stable/).
- A framework-agnostic User Interface packaged as a
[Custom Element](https://developer.mozilla.org/en-US/docs/Web/Web_Components/Using_custom_elements),
powered either in-browser via WebAssembly or virtually via WebSocket server
(Python/Node).
(Python/Node/Rust).

- A [JupyterLab](https://jupyter.org/) widget and Python client library, for
interactive data analysis in a notebook, as well as _scalable_ production
[Voila](https://github.com/voila-dashboards/voila) applications.
applications.

### Documentation

- [Project Site](https://perspective.finos.org/)
- JavaScript (NPM)
- [`@finos/perspective-viewer`, JavaScript UI API](https://docs.rs/perspective-viewer/latest/perspective_viewer/)
- [`@finos/perspective`, JavaScript Client/Server API](https://docs.rs/perspective-js/latest/perspective_js/)
- [`Table` API](https://docs.rs/perspective-js/latest/perspective_js/struct.Table.html)
- [`View` API](https://docs.rs/perspective-js/latest/perspective_js/struct.View.html)
- [Installation Guide](https://docs.rs/perspective-js/latest/perspective_js/#installation)
- Python (PyPI)
- [`perspective-python`, Python Client/Server API](https://docs.rs/perspective-python/latest/perspective_python/)
- [`PerspectiveWidget` Jupyter Plugin](https://docs.rs/perspective-python/latest/perspective_python/#perspectivewidget)
- [`Table` API](https://docs.rs/perspective-python/latest/perspective_python/struct.Table.html)
- [`View` API](https://docs.rs/perspective-python/latest/perspective_python/struct.View.html)
- Rust (Crates.io)
- [`perspective`, Rust API](https://docs.rs/perspective-rs/latest/perspective_rs/)
- [`perspective-client`, Rust Client API](https://docs.rs/perspective-client/latest/perspective_client/)
- [`perspective-server`, Rust Server API](https://docs.rs/perspective-server/latest/perspective_server/)
- [`Table` API](https://docs.rs/perspective-client/latest/perspective_client/struct.Table.html)
- [`View` API](https://docs.rs/perspective-client/latest/perspective_client/struct.View.html)
- Appendix
- [Data Binding](https://docs.rs/perspective-server/latest/perspective_server/)
- [Expression Columns](https://docs.rs/perspective-client/latest/perspective_client/config/expressions/)
- [User Guide](https://perspective.finos.org/guide/)
- [`@finos/perspective`, JavaScript Client API](https://docs.rs/perspective-js/latest/perspective_js/)
- [`@finos/perspective-viewer`, JavaScript UI API](https://docs.rs/perspective-viewer/latest/perspective_viewer/)
- [`perspective-python`, Python API](https://docs.rs/perspective-python/latest/perspective_python/)
- [`perspective`, Rust API](https://docs.rs/perspective-rs/latest/perspective_rs/)

### Examples

Expand Down
5 changes: 2 additions & 3 deletions cpp/perspective/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -231,9 +231,9 @@ if(PSP_WASM_BUILD)
")
endif()
else()
set(OPT_FLAGS " -O3 -g0 -flto --emit-tsd=perspective-server.d.ts ")
set(OPT_FLAGS " -O3 -g0 ")
if (PSP_WASM_EXCEPTIONS)
set(OPT_FLAGS "${OPT_FLAGS} -fwasm-exceptions ")
set(OPT_FLAGS "${OPT_FLAGS} -fwasm-exceptions -flto --emit-tsd=perspective-server.d.ts ")
endif()
endif()
elseif(PSP_CPP_BUILD OR PSP_PYTHON_BUILD)
Expand Down Expand Up @@ -523,7 +523,6 @@ else()
-s DYNAMIC_EXECUTION=0 \
-s POLYFILL=0 \
-s EXPORT_NAME=\"load_perspective\" \
-s MAXIMUM_MEMORY=16gb \
-s ERROR_ON_UNDEFINED_SYMBOLS=0 \
-s NODEJS_CATCH_EXIT=0 \
-s NODEJS_CATCH_REJECTION=0 \
Expand Down
26 changes: 13 additions & 13 deletions cpp/perspective/src/cpp/table.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -905,7 +905,7 @@ Table::update_cols(const std::string_view& data, std::uint32_t port_id) {
}

t_uindex nrows = 0;
for (const auto& it : document.GetObject()) {
for (const auto& it : document.GetObj()) {
if (!it.value.IsArray()) {
PSP_COMPLAIN_AND_ABORT("Malformed column")
}
Expand Down Expand Up @@ -940,14 +940,14 @@ Table::update_cols(const std::string_view& data, std::uint32_t port_id) {

auto schema = data_table.get_schema();

if (is_implicit && !document.GetObject().HasMember("__INDEX__")) {
if (is_implicit && !document.GetObj().HasMember("__INDEX__")) {
for (std::uint32_t ii = 0; ii < nrows; ii++) {
psp_pkey_col->set_nth<std::uint32_t>(ii, (m_offset + ii) % m_limit);
}
}

// 3.) Fill table
for (const auto& column : document.GetObject()) {
for (const auto& column : document.GetObj()) {
t_uindex ii = 0;
std::string_view col_name = column.name.GetString();
if (std::string_view{column.name.GetString()} == "__INDEX__") {
Expand Down Expand Up @@ -1001,7 +1001,7 @@ Table::from_cols(
t_uindex nrows = 0;

// https://github.com/Tencent/rapidjson/issues/1994
for (const auto& it : document.GetObject()) {
for (const auto& it : document.GetObj()) {
if (!it.value.IsArray()) {
PSP_COMPLAIN_AND_ABORT("Malformed column")
}
Expand Down Expand Up @@ -1052,7 +1052,7 @@ Table::from_cols(
const auto& psp_okey_col = data_table.get_column("psp_okey");

// 3.) Fill table
for (const auto& col : document.GetObject()) {
for (const auto& col : document.GetObj()) {
t_uindex ii = 0;
const auto& col_name = col.name.GetString();
LOG_DEBUG(
Expand Down Expand Up @@ -1153,7 +1153,7 @@ Table::update_rows(const std::string_view& data, std::uint32_t port_id) {
}

// col_count = m_column_names.size();
for (const auto& it : row.GetObject()) {
for (const auto& it : row.GetObj()) {
std::shared_ptr<t_column> col;
std::string_view col_name = it.name.GetString();
if (std::string_view{it.name.GetString()} == "__INDEX__") {
Expand Down Expand Up @@ -1246,12 +1246,12 @@ Table::from_rows(

[&]() {
for (const auto& row : document.GetArray()) {
for (const auto& col : row.GetObject()) {
for (const auto& col : row.GetObj()) {
columns_seen.insert(col.name.GetString());
}

// https://github.com/Tencent/rapidjson/issues/1994
for (const auto& col : row.GetObject()) {
for (const auto& col : row.GetObj()) {
if (col.name.GetString() == index) {
is_implicit = false;
}
Expand Down Expand Up @@ -1307,7 +1307,7 @@ Table::from_rows(

// 3.) Fill table
for (const auto& row : document.GetArray()) {
for (const auto& it : row.GetObject()) {
for (const auto& it : row.GetObj()) {
auto col = data_table.get_column(it.name.GetString());
const auto* col_name = it.name.GetString();
const auto& cell = it.value;
Expand Down Expand Up @@ -1399,7 +1399,7 @@ Table::update_ndjson(const std::string_view& data, std::uint32_t port_id) {
psp_pkey_col->set_nth<std::uint32_t>(ii, (ii + m_offset) % m_limit);
}

for (const auto& it : document.GetObject()) {
for (const auto& it : document.GetObj()) {
std::shared_ptr<t_column> col;
std::string_view col_name = it.name.GetString();
if (std::string_view{it.name.GetString()} == "__INDEX__") {
Expand Down Expand Up @@ -1486,12 +1486,12 @@ Table::from_ndjson(
// enhancement we do for regular JSON. For now this only checks the first
// row.
[&]() {
for (const auto& col : document.GetObject()) {
for (const auto& col : document.GetObj()) {
columns_seen.insert(col.name.GetString());
}

// https://github.com/Tencent/rapidjson/issues/1994
for (const auto& col : document.GetObject()) {
for (const auto& col : document.GetObj()) {
if (col.name.GetString() == index) {
is_implicit = false;
}
Expand Down Expand Up @@ -1555,7 +1555,7 @@ Table::from_ndjson(
// 3.) Fill table
bool is_finished = false;
while (!is_finished) {
for (const auto& it : document.GetObject()) {
for (const auto& it : document.GetObj()) {
auto col = data_table.get_column(it.name.GetString());
const auto* col_name = it.name.GetString();
const auto& cell = it.value;
Expand Down
42 changes: 42 additions & 0 deletions docs/book.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# ┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
# ┃ ██████ ██████ ██████ █ █ █ █ █ █▄ ▀███ █ ┃
# ┃ ▄▄▄▄▄█ █▄▄▄▄▄ ▄▄▄▄▄█ ▀▀▀▀▀█▀▀▀▀▀ █ ▀▀▀▀▀█ ████████▌▐███ ███▄ ▀█ █ ▀▀▀▀▀ ┃
# ┃ █▀▀▀▀▀ █▀▀▀▀▀ █▀██▀▀ ▄▄▄▄▄ █ ▄▄▄▄▄█ ▄▄▄▄▄█ ████████▌▐███ █████▄ █ ▄▄▄▄▄ ┃
# ┃ █ ██████ █ ▀█▄ █ ██████ █ ███▌▐███ ███████▄ █ ┃
# ┣━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┫
# ┃ Copyright (c) 2017, the Perspective Authors. ┃
# ┃ ╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌ ┃
# ┃ This file is part of the Perspective library, distributed under the terms ┃
# ┃ of the [Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0). ┃
# ┗━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┛

[book]
authors = ["Andrew Stein"]
language = "en"
multilingual = false
src = "md"
title = "Perspective"

[build]
build-dir = "static/guide"

[output.html]
# theme = "my-theme"
# default-theme = "light"
# preferred-dark-theme = "navy"
# smart-punctuation = true
# mathjax-support = false
copy-fonts = true
git-repository-url = "https://github.com/finos/perspective"
git-repository-icon = "fa-github"
site-url = "https://perspective.finos.org/guide/"
additional-css = [
"md/perspective.css",
"node_modules/@finos/perspective-viewer/dist/css/themes.css",
]
# additional-js = []
# no-section-label = false
# edit-url-template = "https://github.com/rust-lang/mdBook/edit/master/guide/{path}"
# site-url = "/guide/"
# cname = "myproject.rs"
# input-404 = "not-found.md"
Loading

0 comments on commit f67c111

Please sign in to comment.