0.0.15-aaa • Published 2 years ago

@visualbi/ibcs-charts v0.0.15-aaa

Weekly downloads
-
License
ISC
Repository
-
Last release
2 years ago

Inforiver Charts

Things to do first:

  • Update to Node LTS (You will need to use node > 12.x.x, npm >= 7.x.)
  • Delete node_modules, package.lock.json and dist folder
  1. Installation and Setup

    • # Hint: After installation if build failed somehow, try removing package.json and node_modules and do fresh install.
      
      npm install
    • # For Local Developement with host (powerbi/ibcscharts) we need to link the this library with the host for that following command should be used
      
      # Open CLI in the host folder, and apply the following command
      
      # Caution: Don't forget to 'npm i' on host folder before doing the below step.
      
      # Note: <library-folder's-absolute-path> is the absolute path of this library. (It could be relative path, but be careful).
      
      npm link <library-folder's-absolute-path> # from host folder
      
      # It adds the symbolic link to the host's library to this library without using linklocal package.
      
      # In this way we could avoid using linklocal command which sets the scar (file:../ibcsharts) like thing in package.json, which is annoying while taking production build on CI

  2. Development

    • # Suggested - Speeder Compilation for development
      
      # it gives the development bulld with hot reload support **It is super fast**
      
      # Caution: typedefs will be genrated only once on initial build, further bullds on watch will only updates src files any hard actions like delete / modify on structure may fail (in that case delete the dist and rerun the following command freshly).
      
      npm run dev

  3. Linting

    • # It only shows lint errors (will not fix the fixable lint errors)
      
      npm run lint
    • # It fixes the fixable lint errors (and throws the hardly damaged lint errors)
      
      npm run lint:fix

  4. Production

    • # It Generates the Optimized production build with default compression provided by the webpack.
      
      npm run build

  5. Playground

    • # For the first time, install the playground using the following command before running the playground in the next step
      
      npm run playground:install
    • # To run the playground use the following command
      
      npm run playground
      # note: update the data.ts in the playground folder to update the moduleProps data

⚡️⚡️ Faster Compilation with SWC

The package also supports faster compilation using swc (rust based typescript/javascript compiler). Use the below commands for faster build times. Below are the reference commands for development and production usage.

For development, run the below commands

npm run build:next
npm run dev:next  # watches for changes in ts(x) and less files

Note - typedefs are only built on build:next.

For building the package, just run the below command.

npm run build:next
npm publish     # to publish to npm