upcharts v1.2.3
UPCHARTS📈
UPCHARTS is a “wheel”(yeah, u konw what i mean!👀),it can help you with React Visualization Library rather than spending lots of time on how to configure these charts, and what you need to to is just input the data!
Getting Started
npm install upchart --save or yarn upchart, than you can import these instance in the React projects!
Development
Local
ADD LOCAL DEPENDENCY
cd examplegoto example directorynpm iadd lots of npm's packages🙉
LOCAL DEVELOPMENT
npm run exTo start the example developmentnpm run devTo listen anything changes in ./src and move the wholesrcdirectory to./example/srcnpm run hbuildTo listen anything changes in ./src and rebuild the npm
Attention, i have created the npm directory, so you can publish the npm package in this folder, so you can config the control.sh to do something, in this case to avoid some unless dependencies!
How to build?
- do
npm installto import some dependences - develop under
src/directory(or you can modifyrollup.config.js->inputto change the rule) - do
npm run buildto generateindex.json root,the publish it to the NPM platform
About
Support Typescript
Firstly, you need to npm install --save typescript @types/node @types/react @types/react-dom @types/jest and npm install --save-dev @rollup/plugin-typescript to support Typescript compile and package!
Then, we need to add some configs:
- remove
outDirintsconfig.json, or you will caught some errors when packing - config
typesinpackage.json, which will take the type define file into the bundle - config
filesto open whitelist, used to publish the target files to npm
Attention: dependencies is required to support the .d.ts file, see publish for more details
React
In most case, you will not want to include some packages(like React, lodash etc) when bundle up.
You can config external: ["react", "react-dom"] in rollup.config.js to avoid this case, it will not the bundle up the whole react, and will replace with var React = require('react');, so you must ensure that you have included the react in your project!
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago