---
updatedAt: 2026-10-19T12:21:15.000Z
agentTools:
  projectIndex: https://apidocs.worklio.com/llms.txt
---

# Front-End Library

The Worklio Embedded Payroll Front-End library (WEP FE) is for front-end developers. It simplifies working with the WEP API and lets you integrate a native U.S. payroll solution into your codebase. For how the component library compares with the API and iFrame paths, see [What is embedded payroll](https://apidocs.worklio.com/docs/what-is-embedded-payroll). For the access token the WEP API requires, see [How to get API access](https://apidocs.worklio.com/docs/getting-an-api-access).

## Prerequisites

| Requirement                 | Description                                                                                               |
| --------------------------- | --------------------------------------------------------------------------------------------------------- |
| Repository access           | Access to Worklio's private GitHub repository. Request it in [Step 1](#step-1-request-repository-access). |
| Node.js                     | Version 22.x. Download it from [nodejs.org](https://nodejs.org/en).                                       |
| Vue                         | Version 3.5 or later. Required for `@worklio/wep-vue`.                                                    |
| React                       | Version 18.3 or later. Required for `@worklio/wep-react`.                                                 |
| `@googlemaps/js-api-loader` | Required only if you use address autocomplete.                                                            |
| Bundler                     | Must be able to resolve CSS imports from `node_modules`.                                                  |

## Packages

The repository contains library packages, which you integrate into your app, and playground packages, which are example apps for exploring the components in a working flow.

**Library packages**

| Directory            | Package              | Description                                           |
| -------------------- | -------------------- | ----------------------------------------------------- |
| `packages/wep`       | `@worklio/wep`       | Core types, enums, API utilities, and shared helpers. |
| `packages/wep-vue`   | `@worklio/wep-vue`   | Vue components and forms.                             |
| `packages/wep-react` | `@worklio/wep-react` | React components and forms.                           |

**Playground packages**

| Directory                   | Description                               |
| --------------------------- | ----------------------------------------- |
| `packages/playground`       | Functionality shared by both playgrounds. |
| `packages/playground-vue`   | Vue example app.                          |
| `packages/playground-react` | React example app.                        |

## Set up the repository

### Step 1: Request repository access

Contact Worklio support to request access to the private GitHub repository: [worklio.com/contact-us](https://www.worklio.com/contact-us/).

### Step 2: Clone the repository

Clone the repository to your machine. Make sure Node.js 22.x is installed first (see [Prerequisites](#prerequisites)).

### Step 3: Install dependencies

Run `npm ci` from the repository root. It installs the exact versions in the lockfile, so every install is clean and repeatable.

```sh
npm ci
```

### Step 4: Build the library and run a playground

Build the library packages for your framework, then start the matching playground.

```sh Vue
npm run build -w @worklio/wep -w @worklio/wep-vue
npm run dev -w playground-vue
```

```sh React
npm run build -w @worklio/wep -w @worklio/wep-react
npm run dev -w playground-react
```

### Step 5: Render your first component

Start with a single form field to confirm that components render and bind to your state in your framework. The field renders with the label `Display name`.

```vue Vue
<script setup lang="ts">
import { ref } from 'vue';
import { WepFormField, WepTextBox } from '@worklio/wep-vue';

const value = ref('');
</script>

<template>
  <WepFormField label="Display name">
    <WepTextBox v-model="value" />
  </WepFormField>
</template>
```

```tsx React
import { WepFormField, WepTextBox } from '@worklio/wep-react';

export function Example() {
  return (
    <WepFormField label="Display name">
      <WepTextBox value="" onValueUpdate={() => {}} />
    </WepFormField>
  );
}
```

## Component documentation

Component documentation is written as stories that live next to the components. View the published stories, or run them locally.

| Framework | Published stories                                                       | Run locally                           |
| --------- | ----------------------------------------------------------------------- | ------------------------------------- |
| Vue       | [apidemo.worklio.com/wep/vue](https://apidemo.worklio.com/wep/vue/)     | `npm run story -w @worklio/wep-vue`   |
| React     | [apidemo.worklio.com/wep/react](https://apidemo.worklio.com/wep/react/) | `npm run story -w @worklio/wep-react` |

## Recommended IDE setup

[Visual Studio Code](https://code.visualstudio.com/) gives the best editing and TypeScript experience for this repository. If you work on Vue components, also install the [Vue - Official](https://marketplace.visualstudio.com/items?itemName=Vue.volar) extension.