1.2.0 • Published 5 years ago

just-publish-it v1.2.0

Weekly downloads
3
License
SEE LICENSE IN LI...
Repository
-
Last release
5 years ago

DevEx Tangram

This is a web component library conferred by NTUC Design System.

Documentation can be found at ntuc.design.

Getting Started

Include NPM Token

Since @ntuctech is a private repository, your project (both locally and in CI pipeline) needs to be authenticated with NPM to fetch packages.

To get more details please read the instructions at Using private packages in a CI/CD workflow

# Do this on your local machine and commit the `.npmrc` to git
cd path/to/your/app
echo -e '//registry.npmjs.org/:_authToken=${NPM_TOKEN}' >> .npmrc

# Add this environment variable both locally and on your CI/CD
export NPM_TOKEN=GET_A_READ_ONLY_TOKEN_FROM_NTUC_DESIGN_TEAM

# Now whenever you `npm install`, NPM will know you have access
# to the private packages.

Installation

npm install @ntuctech/devex-scream@latest

# Please note there are peer dependencies so you need to install them on your own.

npm install react react-dom

Import Components In Your Project

import Button from "@ntuctech/devex-tangram/Button";

...

<Button />

...

For detailed API documentation please follow docs at ntuc.design

Reduce Bundle Size

To reduce production bundle size, prefer importing all required components from the file path rather than index file.

e.g.

Instead of

import { Button } from '@ntuctech/devex-tangram';

Use following to stop including whole library through @ntuctech/devex-tangram/index.js

import Button from '@ntuctech/devex-tangram/Button';

For further information please refer how to reduce bundle size using ES6 modules.