Skip to content

Please update nivo and add the new charts! #36

@TheUkrainian1991

Description

@TheUkrainian1991

I'm wanting to use nivo boxplot for my app but I get the error:

Element BoxPlot does not exist in module chartNivo

I did some digging in the repo and to frontend/components/modules/charts/Nivo.tsx added the line:

BoxPlot: dynamic(() => import("@nivo/boxplot").then(m => m.ResponsiveBoxPlot), { loading: ElementsLoading, ssr: false })

Same error. So I thought it must be the react dependencies.
So I added the key '@nivo/boxplot' and value='^0.87.0' to both the frontend/package.json and frontend/package-locked.json under the appropriate dependency key.

Same error. So I then added the key "node_modules/@nivo/boxplot" and the value:

{
      "version": "0.82.1",
      "resolved": "registry.npmjs.org/@nivo/boxplot/-/boxplot-0.82.1.tgz",
      "integrity": "sha512-swJ2FtFeRPWJK9O6aZiqTDi2J6GrU2Z6kIHBBCXBlFmq6+vfd5AqOHytdXPTaN80JsKDBBdtY7tqRjpRPlDZwQ==",
      "dependencies": {
        "@nivo/annotations": "0.79.1",
        "@nivo/axes": "0.79.0",
        "@nivo/colors": "0.79.1",
        "@nivo/legends": "0.79.1",
        "@nivo/scales": "0.79.0",
        "@nivo/tooltip": "0.79.0",
        "@react-spring/web": "9.3.1",
        "d3-scale": "^3.2.3",
        "d3-shape": "^1.2.2",
        "lodash": "^4.17.21"
      },
      "peerDependencies": {
        "@nivo/core": "0.79.0",
        "react": ">= 16.14.0 < 18.0.0"
      }
    }

to the package-locked.json

Also the same error.

I know this is a hacky way but I have no knowledge of typescript and can't fork the repo myself. Is the install of the nivo charts happening when you install the actual repo? If so what is the best method to get the new charts in?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions