# H8K Components

A set of web components to be used while creating Front End Questions in Hackerrank.

## Getting Started

These web components come with no styles attached with them and should be used in conjuction with the H8K Design library.

### CDN
Include the following tags in your index.html.

```html
<link href="https://cdn.jsdelivr.net/npm/h8k-design/dist/index.css" rel="stylesheet">
<script type="module" src="https://cdn.jsdelivr.net/npm/h8k-components/dist/h8k-components/h8k-components.esm.js"></script>
<script nomodule src="https://cdn.jsdelivr.net/npm/h8k-components/dist/h8k-components/h8k-components.js"></script>
```

### Node Modules
- Run `npm install h8k-components --save` to install the components
- Run `npm install h8k-design --save` to install the design library


# Built with Stencil

Stencil is a compiler for building fast web apps using Web Components.

Stencil combines the best concepts of the most popular frontend frameworks into a compile-time rather than run-time tool.  Stencil takes TypeScript, JSX, a tiny virtual DOM layer, efficient one-way data binding, an asynchronous rendering pipeline (similar to React Fiber), and lazy-loading out of the box, and generates 100% standards-based Web Components that run in any browser supporting the Custom Elements v1 spec.

Stencil components are just Web Components, so they work in any major framework or with no framework at all.


## Development

To start building a new web component using Stencil, clone this repo to a new directory:

```bash
git clone git@github.com:ProblemSetters/h8k-components.git
```

and run:

```bash
npm install
npm start
```

To build the component for production, run:

```bash
npm run build
```

To run the unit tests for the components, run:

```bash
npm test
```

Need help? Check out the stencil docs [here](https://stenciljs.com/docs/my-first-component).



