Various tests with Plot
authorMathieu Baudier <mbaudier@argeo.org>
Thu, 14 Sep 2023 08:08:25 +0000 (10:08 +0200)
committerMathieu Baudier <mbaudier@argeo.org>
Thu, 14 Sep 2023 08:08:25 +0000 (10:08 +0200)
js/src/graph/TestGraph.js
js/src/graph/export-package.js

index 850bef96b2fb6126f9b5dcd3ea025fdac15d29fc..5236657db397be82f38686b2e44e12d41021e70e 100644 (file)
@@ -1,6 +1,6 @@
 import * as Plot from "@observablehq/plot";
 
-export class TestGraph {
+export default class TestGraph {
 
        init() {
 
index f36008460b0fbab43ff73986cad3c2df020784e0..ec8b4ee1291765a4fd837a48ac9da4dcdc9eb6cf 100644 (file)
@@ -1,5 +1,5 @@
 import TestGraph from './TestGraph.js';
-import * as Plot from "@observablehq/plot";
+//import { rectY, binX } from "@observablehq/plot";
 
 // PSEUDO PACKAGE
 if (typeof globalThis.argeo === 'undefined')
@@ -12,8 +12,8 @@ if (typeof globalThis.argeo.app.graph === 'undefined')
 // PUBLIC CLASSES
 globalThis.argeo.app.graph.TestGraph = TestGraph;
 
-const plot = Plot.rectY({ length: 10000 }, Plot.binX({ y: "count" }, { x: Math.random })).plot();
-const div = document.querySelector("#myplot");
-div.append(plot);
+//const plot = rectY({ length: 10000 }, binX({ y: "count" }, { x: Math.random })).plot();
+//const div = document.querySelector("#myplot");
+//div.append(plot);
 
 "use strict";