Skip to content

Commit 7c5bac6

Browse files
committed
Replace monaco
1 parent 30b7d24 commit 7c5bac6

File tree

103 files changed

+1938
-1979
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

103 files changed

+1938
-1979
lines changed

.github/workflows/build.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -287,6 +287,8 @@ jobs:
287287
uses: actions-rs/toolchain@v1
288288
with:
289289
toolchain: nightly
290+
target: wasm32-unknown-unknown
291+
default: true
290292
override: true
291293
components: rustfmt, clippy, rust-src
292294

@@ -620,6 +622,17 @@ jobs:
620622
- name: Install python dependencies
621623
run: yarn _requires_python
622624

625+
626+
################
627+
# Rust
628+
- name: Install latest nightly rust
629+
uses: actions-rs/toolchain@v1
630+
with:
631+
toolchain: nightly
632+
target: wasm32-unknown-unknown
633+
default: true
634+
override: true
635+
623636
################
624637
# Wasm
625638
- name: Install wasm-pack (Linux and Macos)

cpp/perspective/src/cpp/computed_expression.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -346,8 +346,8 @@ t_computed_expression_parser::get_dtype(const std::string& expression_alias,
346346
std::string error_message(parser_error.diagnostic.c_str());
347347

348348
// strip the Exprtk error codes such as "ERR001 -"
349-
error.m_error_message = "Parser Error "
350-
+ error_message.substr(error_message.find("- "));
349+
error.m_error_message
350+
= error_message.substr(error_message.find("- ") + 2);
351351

352352
error.m_line = parser_error.line_no;
353353
error.m_column = parser_error.column_no;

docs/docs/js.md

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,6 @@ performance, as the plugin-assisted bundle version of Perspective:
5757
- Downloads `.wasm` and `.js` assets in parallel.
5858
- Compiles `.wasm` incrementally via
5959
[streaming instantiation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WebAssembly/instantiateStreaming).
60-
- Lazily downloads large features only when used such as `monaco-editor`.
6160
- overall bundle size is ~20% smaller (due to bas64 encoding overhead).
6261

6362
Perspective comes with bundler plugins for:
@@ -83,28 +82,6 @@ module.exports = {
8382
};
8483
```
8584

86-
`@finos/perspective-viewer` has a dependence on
87-
[`monaco-editor`](https://microsoft.github.io/monaco-editor/), which itself
88-
depends on several CSS assets. If your webpack config uses a loader for
89-
`"*.css"` or similar, you may need to exclude `monaco-editor` from this loader
90-
to prevent double-encoding:
91-
92-
```javascript
93-
module.exports = {
94-
// ...
95-
96-
module: {
97-
rules: [
98-
{
99-
test: /\.css$/,
100-
exclude: [/monaco-editor/], // <- Exclude `monaco-editor`
101-
use: [{loader: "style-loader"}, {loader: "css-loader"}],
102-
},
103-
],
104-
},
105-
};
106-
```
107-
10885
##### `esbuild`
10986

11087
Applications bundled with `esbuild` can make use of the

docs/plugins/perspective-loader/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ module.exports = function (context, options) {
66
configureWebpack(config, isServer) {
77
config.module.rules.map((x) => {
88
if (x.test.toString() === "/\\.css$/i") {
9-
x.exclude = [/\.module\.css$/i, /@finos/i, /monaco/i];
9+
x.exclude = [/\.module\.css$/i, /@finos/i];
1010
}
1111
});
1212

examples/blocks/src/editable/index.html

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@
2323
<link rel="preload" href="/node_modules/@finos/perspective-viewer/dist/cdn/perspective_bg.wasm" as="fetch" type="application/wasm" crossorigin="anonymous" />
2424
<link rel="preload" href="/node_modules/superstore-arrow/superstore.arrow" as="fetch" type="arraybuffer" crossorigin="anonymous" />
2525
<link rel="preload" href="/node_modules/@finos/perspective/dist/cdn/perspective.worker.js" as="fetch" type="application/javascript" crossorigin="anonymous" />
26-
<link rel="preload" href="/node_modules/@finos/perspective-viewer/dist/cdn/editor.worker.js" as="fetch" type="application/javascript" crossorigin="anonymous" />
2726

2827
<script type="module">
2928
import {worker} from "/node_modules/@finos/perspective/dist/cdn/perspective.js";

examples/react-monaco/README.md

Lines changed: 0 additions & 8 deletions
This file was deleted.

examples/react-monaco/package.json

Lines changed: 0 additions & 28 deletions
This file was deleted.

examples/react-monaco/src/index.css

Lines changed: 0 additions & 18 deletions
This file was deleted.

examples/react-monaco/src/index.html

Lines changed: 0 additions & 18 deletions
This file was deleted.

examples/react-monaco/src/index.tsx

Lines changed: 0 additions & 144 deletions
This file was deleted.

0 commit comments

Comments
 (0)